-
Notifications
You must be signed in to change notification settings - Fork 602
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin' into tab/drop-table-connector
- Loading branch information
Showing
74 changed files
with
2,615 additions
and
2,011 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
statement ok | ||
CREATE TABLE t1 (i1 int, i2 varchar, i3 varchar); | ||
|
||
statement ok | ||
INSERT INTO t1 select key, 'some long string of text', 'another long string of text' from generate_series(1, 1000000) as key; | ||
|
||
statement ok | ||
CREATE SINK sink1 AS select * from t1 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 = 's3a://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 = 1, | ||
create_table_if_not_exists = 'true' | ||
); | ||
|
||
statement ok | ||
CREATE SOURCE iceberg_t1_source | ||
WITH ( | ||
connector = 'iceberg', | ||
s3.endpoint = 'http://127.0.0.1:9301', | ||
s3.region = 'us-east-1', | ||
s3.access.key = 'hummockadmin', | ||
s3.secret.key = 'hummockadmin', | ||
s3.path.style.access = 'true', | ||
catalog.type = 'storage', | ||
warehouse.path = 's3a://icebergdata/demo', | ||
database.name = 'demo_db', | ||
table.name = 't1', | ||
); | ||
|
||
statement ok | ||
flush; | ||
|
||
query I | ||
select count(*) from iceberg_t1_source; | ||
---- | ||
1000000 | ||
|
||
# warmup | ||
include ./predicate_pushdown/point_get.slt.part | ||
# bench | ||
include ./predicate_pushdown/point_get.slt.part | ||
|
||
# warmup | ||
include ./predicate_pushdown/filter.slt.part | ||
# bench | ||
include ./predicate_pushdown/filter.slt.part | ||
|
||
statement ok | ||
DROP SINK sink1; | ||
|
||
statement ok | ||
DROP SOURCE iceberg_t1_source; | ||
|
||
statement ok | ||
DROP TABLE t1 cascade; |
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,11 @@ | ||
init_sqls = [ | ||
'CREATE SCHEMA IF NOT EXISTS demo_db', | ||
'DROP TABLE IF EXISTS demo_db.t1', | ||
] | ||
|
||
slt = 'benches/predicate_pushdown.slt' | ||
|
||
drop_sqls = [ | ||
'DROP TABLE IF EXISTS demo_db.t1', | ||
'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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
query I | ||
select count(*) from iceberg_t1_source where i1 > 1001 and i1 < 1110; | ||
---- | ||
108 |
4 changes: 4 additions & 0 deletions
4
e2e_test/iceberg/benches/predicate_pushdown/point_get.slt.part
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,4 @@ | ||
query I | ||
select * from iceberg_t1_source where i1 = 100000; | ||
---- | ||
100000 some long string of text another long string of text |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
# https://github.com/risingwavelabs/risingwave/issues/17263 | ||
|
||
statement ok | ||
create table t (a int, b int); | ||
|
||
statement ok | ||
create function add(a int, b int) returns int language python as $$ | ||
def add(a, b): | ||
return a+b | ||
$$; | ||
|
||
statement error function with name add\(integer,integer\) exists | ||
create function add(int, int) returns int language sql as $$select $1 + $2$$; | ||
|
||
statement ok | ||
create function if not exists add(int, int) returns int language sql as $$select $1 + $2$$; | ||
|
||
statement ok | ||
create function add_v2(int, int) returns int language sql as $$select $1 + $2$$; | ||
|
||
statement ok | ||
create aggregate mysum(value int) returns int language python as $$ | ||
def create_state(): | ||
return 0 | ||
def accumulate(state, value): | ||
return state + value | ||
def finish(state): | ||
return state | ||
$$; | ||
|
||
statement error function with name mysum\(integer\) exists | ||
create aggregate mysum(value int) returns int language python as $$ | ||
def create_state(): | ||
return 0 | ||
def accumulate(state, value): | ||
return state + value | ||
def finish(state): | ||
return state | ||
$$; | ||
|
||
statement ok | ||
create aggregate if not exists mysum(value int) returns int language python as $$ | ||
def create_state(): | ||
return 0 | ||
def accumulate(state, value): | ||
return state + value | ||
def finish(state): | ||
return state | ||
$$; | ||
|
||
statement ok | ||
create materialized view mv as select add(a, b) + add_v2(a, b) as c from t; | ||
|
||
statement ok | ||
create materialized view mv2 as select mysum(a) as s from t; | ||
|
||
statement error function used by 1 other objects | ||
drop function add; | ||
|
||
statement error function used by 1 other objects | ||
drop function if exists add; | ||
|
||
statement error function used by 1 other objects | ||
drop function add_v2; | ||
|
||
statement error function used by 1 other objects | ||
drop aggregate mysum; | ||
|
||
statement ok | ||
drop materialized view mv; | ||
|
||
statement ok | ||
drop materialized view mv2; | ||
|
||
statement ok | ||
drop function add; | ||
|
||
statement error function not found | ||
drop function add; | ||
|
||
statement ok | ||
drop function if exists add; | ||
|
||
statement ok | ||
drop function add_v2; | ||
|
||
statement ok | ||
drop function if exists add_v2; | ||
|
||
statement ok | ||
drop aggregate mysum; | ||
|
||
statement ok | ||
drop aggregate if exists mysum; | ||
|
||
statement ok | ||
create function add(a int, b int) returns int language python as $$ | ||
def add(a, b): | ||
return a+b | ||
$$; | ||
|
||
statement ok | ||
create sink s as select add(a, b) as c from t with (connector = 'blackhole'); | ||
|
||
statement error function used by 1 other objects | ||
drop function add; | ||
|
||
statement ok | ||
drop sink s; | ||
|
||
statement ok | ||
drop function add; | ||
|
||
statement ok | ||
drop table t; |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.