-
Notifications
You must be signed in to change notification settings - Fork 591
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug(stream): mv-on-mv: vnode 98 should not be accessed by this table
#8355
Comments
explain: dev=> explain (distsql, verbose) CREATE MATERIALIZED VIEW stream_query AS SELECT TIME '18:53:46' AS col_0 FROM m2 AS t_0 WHERE true GROUP BY t_0.col_1, t_0.col_2;
QUERY PLAN
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Fragment 0
StreamMaterialize { columns: [col_0, m2.col_1(hidden), m2.col_2(hidden)], pk_columns: [m2.col_1, m2.col_2], pk_conflict: "no check" }
materialized table: 4294967294
Output: ['18:53:46':Time, m2.col_1, m2.col_2]
Stream key: [m2.col_1, m2.col_2],
StreamProject { exprs: ['18:53:46':Time, m2.col_1, m2.col_2] }
Output: ['18:53:46':Time, m2.col_1, m2.col_2]
Stream key: [m2.col_1, m2.col_2],
StreamHashAgg { group_key: [m2.col_1, m2.col_2], aggs: [count] }
result table: 0, state tables: []
Output: [m2.col_1, m2.col_2, count]
Stream key: [m2.col_1, m2.col_2],
StreamExchange Hash([0, 1]) from 1
Output: [m2.col_1, m2.col_2]
Stream key: [],
Fragment 1
Chain { table: m2, columns: [m2.col_1, m2.col_2], pk: [], dist: Single }
Output: [m2.col_1, m2.col_2]
Stream key: [],
Upstream
Output: [col_0, col_1, col_2, col_3]
Stream key: [],
BatchPlanNode
Output: [m2.col_1, m2.col_2]
Stream key: [], AppendOnly
Table 0 { columns: [m2_col_1:interval, m2_col_2:time without time zone, count:bigint], primary key: [$0 ASC, $1 ASC], value indices: [2], distribution key: [0, 1] }
Table 4294967294 { columns: [col_0:time without time zone, m2.col_1:interval, m2.col_2:time without time zone], primary key: [$1 ASC, $2 ASC], value indices: [0, 1, 2], distribution key: [1, 2] } |
log;
|
very interesting, I found the bugs will happen even when no insert statements 😇
|
It's due to the risingwave/src/common/src/hash/key.rs Lines 359 to 380 in f752a11
So we get different hash (vnode) values for hash-data dispatcher and state table. |
vnode should not be accessed by this table
vnode 98 should not be accessed by this table
Hash of interval have been fixed. Note the |
Let's close as complete. If sqlsmith catch again we can take a look then. |
Describe the bug
To Reproduce
Expected behavior
No response
Additional context
Perhaps related to #8329 .
The text was updated successfully, but these errors were encountered: