[oceanbase][test] Use memory mode of obcdc and double startup timeout duration (#1474)

This closes #1473.
pull/1478/head
He Wang 3 years ago committed by GitHub
parent cfbd00fa34
commit d0d40d05c7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -85,7 +85,9 @@ Flink SQL> CREATE TABLE orders (
'port' = '2881',
'rootserver-list' = '127.0.0.1:2882:2881',
'logproxy.host' = '127.0.0.1',
'logproxy.port' = '2983');
'logproxy.port' = '2983',
'working-mode' = 'memory'
);
-- read snapshot and binlogs from orders table
Flink SQL> SELECT * FROM orders;
@ -316,7 +318,9 @@ CREATE TABLE products (
'port' = '2881',
'rootserver-list' = '127.0.0.1:2882:2881',
'logproxy.host' = '127.0.0.1',
'logproxy.port' = '2983');
'logproxy.port' = '2983',
'working-mode' = 'memory'
);
```
Features

@ -139,7 +139,9 @@ Flink SQL> CREATE TABLE orders (
'port' = '2881',
'rootserver-list' = '127.0.0.1:2882:2881',
'logproxy.host' = 'localhost',
'logproxy.port' = '2983');
'logproxy.port' = '2983',
'working-mode' = 'memory'
);
-- create products table
Flink SQL> CREATE TABLE products (
@ -159,7 +161,9 @@ Flink SQL> CREATE TABLE products (
'port' = '2881',
'rootserver-list' = '127.0.0.1:2882:2881',
'logproxy.host' = 'localhost',
'logproxy.port' = '2983');
'logproxy.port' = '2983',
'working-mode' = 'memory'
);
-- create flat table enriched_orders
Flink SQL> CREATE TABLE enriched_orders (

@ -137,7 +137,9 @@ Flink SQL> CREATE TABLE orders (
'port' = '2881',
'rootserver-list' = '127.0.0.1:2882:2881',
'logproxy.host' = 'localhost',
'logproxy.port' = '2983');
'logproxy.port' = '2983',
'working-mode' = 'memory'
);
-- 创建商品表
Flink SQL> CREATE TABLE products (
@ -157,7 +159,9 @@ Flink SQL> CREATE TABLE products (
'port' = '2881',
'rootserver-list' = '127.0.0.1:2882:2881',
'logproxy.host' = 'localhost',
'logproxy.port' = '2983');
'logproxy.port' = '2983',
'working-mode' = 'memory'
);
-- 创建关联后的订单数据表
Flink SQL> CREATE TABLE enriched_orders (

@ -54,6 +54,7 @@ public class OceanBaseTestBase extends TestLogger {
private static final Logger LOG = LoggerFactory.getLogger(OceanBaseTestBase.class);
private static final Pattern COMMENT_PATTERN = Pattern.compile("^(.*)--.*$");
private static final Duration CONTAINER_STARTUP_TIMEOUT = Duration.ofMinutes(4);
public static final int OB_SERVER_SQL_PORT = 2881;
public static final int OB_SERVER_RPC_PORT = 2882;
@ -112,7 +113,7 @@ public class OceanBaseTestBase extends TestLogger {
.withExposedPorts(OB_SERVER_SQL_PORT, OB_SERVER_RPC_PORT)
.withEnv("OB_ROOT_PASSWORD", OB_SYS_PASSWORD)
.waitingFor(Wait.forLogMessage(".*boot success!.*", 1))
.withStartupTimeout(Duration.ofSeconds(120))
.withStartupTimeout(CONTAINER_STARTUP_TIMEOUT)
.withLogConsumer(new Slf4jLogConsumer(LOG));
@ClassRule
@ -123,7 +124,7 @@ public class OceanBaseTestBase extends TestLogger {
.withEnv("OB_SYS_USERNAME", OB_SYS_USERNAME)
.withEnv("OB_SYS_PASSWORD", OB_SYS_PASSWORD)
.waitingFor(Wait.forLogMessage(".*boot success!.*", 1))
.withStartupTimeout(Duration.ofSeconds(120))
.withStartupTimeout(CONTAINER_STARTUP_TIMEOUT)
.withLogConsumer(new Slf4jLogConsumer(LOG));
@BeforeClass

@ -97,7 +97,8 @@ public class OceanBaseConnectorITCase extends OceanBaseTestBase {
+ " 'port' = '%s',"
+ " 'logproxy.host' = '%s',"
+ " 'logproxy.port' = '%s',"
+ " 'rootserver-list' = '%s'"
+ " 'rootserver-list' = '%s',"
+ " 'working-mode' = 'memory'"
+ ")",
getUsername(),
getPassword(),
@ -220,7 +221,8 @@ public class OceanBaseConnectorITCase extends OceanBaseTestBase {
+ " 'port' = '%s',"
+ " 'logproxy.host' = '%s',"
+ " 'logproxy.port' = '%s',"
+ " 'rootserver-list' = '%s'"
+ " 'rootserver-list' = '%s',"
+ " 'working-mode' = 'memory'"
+ ")",
getUsername(),
getPassword(),
@ -342,7 +344,8 @@ public class OceanBaseConnectorITCase extends OceanBaseTestBase {
+ " 'port' = '%s',"
+ " 'logproxy.host' = '%s',"
+ " 'logproxy.port' = '%s',"
+ " 'rootserver-list' = '%s'"
+ " 'rootserver-list' = '%s',"
+ " 'working-mode' = 'memory'"
+ ")",
getUsername(),
getPassword(),

Loading…
Cancel
Save