-
Notifications
You must be signed in to change notification settings - Fork 595
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: decouple iceberg commit from risingwave commit (#15634)
Co-authored-by: ZENOTME <[email protected]>
- Loading branch information
Showing
8 changed files
with
397 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
70 changes: 70 additions & 0 deletions
70
e2e_test/iceberg/test_case/append_only_with_checkpoint_interval.slt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
statement ok | ||
set streaming_parallelism=4; | ||
|
||
statement ok | ||
CREATE TABLE s1 (i1 int, i2 varchar, i3 varchar) WITH ( | ||
connector = 'datagen', | ||
fields.i1.kind = 'sequence', | ||
fields.i2.kind = 'random', | ||
fields.i2.length = '32', | ||
fields.i2.seed = '4', | ||
fields.i3.kind = 'random', | ||
fields.i3.length = '64', | ||
fields.i3.seed = '5', | ||
datagen.rows.per.second = '30000' | ||
) FORMAT PLAIN ENCODE JSON; | ||
|
||
sleep 2s | ||
|
||
statement ok | ||
CREATE MATERIALIZED VIEW mv1 AS SELECT * FROM s1; | ||
|
||
statement ok | ||
CREATE SINK sink1 AS select * from mv1 WITH ( | ||
connector = 'iceberg', | ||
type = 'append-only', | ||
force_append_only = 'true', | ||
database.name = 'demo_db', | ||
table.name = 't1', | ||
catalog.name = 'demo', | ||
catalog.type = 'storage', | ||
warehouse.path = 's3://icebergdata/demo', | ||
s3.endpoint = 'http://127.0.0.1:9301', | ||
s3.region = 'us-east-1', | ||
s3.access.key = 'hummockadmin', | ||
s3.secret.key = 'hummockadmin' | ||
); | ||
|
||
statement ok | ||
CREATE SINK sink2 AS select * from mv1 WITH ( | ||
connector = 'iceberg', | ||
type = 'append-only', | ||
force_append_only = 'true', | ||
database.name = 'demo_db', | ||
table.name = 't2', | ||
catalog.name = 'demo', | ||
catalog.type = 'storage', | ||
warehouse.path = 's3://icebergdata/demo', | ||
s3.endpoint = 'http://127.0.0.1:9301', | ||
s3.region = 'us-east-1', | ||
s3.access.key = 'hummockadmin', | ||
s3.secret.key = 'hummockadmin', | ||
commit_checkpoint_interval = 5 | ||
); | ||
|
||
sleep 20s | ||
|
||
statement ok | ||
flush; | ||
|
||
statement ok | ||
DROP SINK sink1; | ||
|
||
statement ok | ||
DROP SINK sink2; | ||
|
||
statement ok | ||
DROP MATERIALIZED VIEW mv1; | ||
|
||
statement ok | ||
DROP TABLE s1; |
28 changes: 28 additions & 0 deletions
28
e2e_test/iceberg/test_case/append_only_with_checkpoint_interval.toml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
init_sqls = [ | ||
'CREATE SCHEMA IF NOT EXISTS demo_db', | ||
'DROP TABLE IF EXISTS demo_db.demo_table', | ||
''' | ||
CREATE TABLE demo_db.t1 ( | ||
i1 int, | ||
i2 string, | ||
i3 string | ||
) USING iceberg TBLPROPERTIES ('format-version'='2'); | ||
''', | ||
''' | ||
CREATE TABLE demo_db.t2 ( | ||
i1 int, | ||
i2 string, | ||
i3 string | ||
) USING iceberg TBLPROPERTIES ('format-version'='2'); | ||
''', | ||
] | ||
|
||
slt = 'test_case/append_only_with_checkpoint_interval.slt' | ||
|
||
cmp_sqls = ["SELECT * FROM demo_db.t1", "SELECT * FROM demo_db.t2"] | ||
|
||
drop_sqls = [ | ||
'DROP TABLE IF EXISTS demo_db.t1', | ||
'DROP TABLE IF EXISTS demo_db.t2', | ||
'DROP SCHEMA IF EXISTS demo_db', | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.