Skip to content

Commit

Permalink
Merge branch 'main' into yiming/local-partial-graph-barrier-manager
Browse files Browse the repository at this point in the history
  • Loading branch information
wenym1 committed Jul 26, 2024
2 parents a1434cc + f389a77 commit 3c7b70f
Show file tree
Hide file tree
Showing 311 changed files with 9,947 additions and 4,941 deletions.
14 changes: 9 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,4 +150,4 @@ RisingWave is distributed under the Apache License (Version 2.0). Please refer t

## Contributing

Thanks for your interest in contributing to the project! Please refer to [RisingWave Developer Guide](https://risingwavelabs.github.io/risingwave/)for more information.
Thanks for your interest in contributing to the project! Please refer to [RisingWave Developer Guide](https://risingwavelabs.github.io/risingwave/) for more information.
2 changes: 1 addition & 1 deletion docker/dashboards/risingwave-dev-dashboard.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docker/dashboards/risingwave-user-dashboard.json

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions e2e_test/batch/aggregate/scalar_as_agg.slt.part
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
query T
select aggregate:array_sum(v) from (values (3), (2), (1)) as t(v);
----
6

query T
select aggregate:array_sort(v) from (values (3), (2), (1)) as t(v);
----
{1,2,3}
23 changes: 12 additions & 11 deletions e2e_test/source_inline/kafka/avro/alter_table.slt
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ Caused by these errors (recent errors listed first):
4: Item not found: Invalid column: bar


# TODO: Add support for dropping generated columns for table with schema registry
# Can't drop non-generated column
statement error
ALTER TABLE t DROP COLUMN gen_col;
ALTER TABLE t DROP COLUMN foo;
----
db error: ERROR: Failed to run the query

Expand All @@ -65,17 +65,18 @@ Caused by:
HINT: try `ALTER TABLE .. FORMAT .. ENCODE .. (...)` instead


# statement ok
# ALTER TABLE t DROP COLUMN gen_col;
# Drop generated column
statement ok
ALTER TABLE t DROP COLUMN gen_col;

# # Refresh table schema
# statement ok
# ALTER TABLE t REFRESH SCHEMA;
# Refresh table schema
statement ok
ALTER TABLE t REFRESH SCHEMA;

# query ?
# select * from t
# ----
# ABC
query ?
select * from t
----
ABC

statement ok
drop table t;
27 changes: 27 additions & 0 deletions e2e_test/source_inline/kafka/avro/glue.slt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,33 @@ rpk topic produce -f '%v{hex}\n' 'glue-sample-my-event' <<EOF
03005af405ef11b5444281a2e0563e5a734606666f6f80868dc8ebd98404
EOF

statement ok
ALTER SYSTEM SET license_key TO '';

statement error
create source t with (
connector = 'kafka',
properties.bootstrap.server='${RISEDEV_KAFKA_BOOTSTRAP_SERVERS}',
topic = 'glue-sample-my-event')
format plain encode avro (
aws.glue.schema_arn = 'arn:aws:glue:ap-southeast-1:123456123456:schema/default-registry/MyEvent',
aws.glue.mock_config = '{
"by_id": {},
"arn_to_latest_id: {}"
}');
----
db error: ERROR: Failed to run the query

Caused by these errors (recent errors listed first):
1: connector error
2: feature GlueSchemaRegistry is only available for tier Paid and above, while the current tier is Free

Hint: You may want to set a license key with `ALTER SYSTEM SET license_key = '...';` command.


statement ok
ALTER SYSTEM SET license_key TO DEFAULT;

statement ok
create source t with (
connector = 'kafka',
Expand Down
26 changes: 26 additions & 0 deletions e2e_test/udf/python_udf.slt
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,32 @@ statement ok
drop aggregate weighted_avg;


# UDF as aggregate function
statement ok
create function median(int[]) returns float language python as $$
def median(values):
values.sort()
n = len(values)
if n % 2 == 0:
return (values[n // 2 - 1] + values[n // 2]) / 2
else:
return values[n // 2]
$$;

query F
select aggregate:median(x) from (values (1), (2), (3), (4), (5)) as t(x);
----
3

query F
select aggregate:median(x) from (values (4), (3), (2), (1)) as t(x);
----
2.5

statement ok
drop function median;


statement ok
create function mismatched_arguments() returns int language python as $$
def mismatched_arguments(x):
Expand Down
Loading

0 comments on commit 3c7b70f

Please sign in to comment.