-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[YSQL][ASH] Test failures when ASH is enabled by default #23272
Labels
Comments
yugabyte-ci
added
kind/bug
This issue is a bug
priority/medium
Medium priority issue
labels
Jul 24, 2024
abhinab-yb
added a commit
that referenced
this issue
Jul 25, 2024
…ry ids stack Summary: When ASH was enabled by default to run the tests, some tests failed with this assertion ``` TRAP: FailedAssertion("!(query_id_stack.top_index >= 0)", File: "../../../../../../../src/postgres/src/backend/utils/misc/yb_ash.c", Line: 248) @ 0x102aa1960 YbAshNestedQueryIdStackPop @ 0x102aa16e4 YbAshResetQueryId @ 0x102aa0e28 yb_ash_ExecutorEnd @ 0x10251770c ExecutorEnd @ 0x1024526b8 PortalCleanup @ 0x102ab7b6c PortalDrop @ 0x102ab89f8 PreCommit_Portals @ 0x10226d2d8 CommitTransaction @ 0x10226caa4 CommitTransactionCommand @ 0x102802d44 finish_xact_command @ 0x102807b2c exec_simple_query @ 0x102804fa8 yb_exec_simple_query_impl @ 0x10280510c yb_exec_query_wrapper_one_attempt @ 0x102804f70 yb_exec_query_wrapper @ 0x1027ffb04 yb_exec_simple_query @ 0x1027fe42c PostgresMain @ 0x1026fd7b0 BackendRun @ 0x1026fc6bc BackendStartup @ 0x1026fad30 ServerLoop @ 0x1026f6cac PostmasterMain @ 0x1025cb848 PostgresServerProcessMain @ 0x1025cbd28 main @ 0x1a389bf28 start ``` `finish_xact_command` is called, which calls `yb_ash_ExecutorEnd`. In `yb_ash_ExecutorEnd`, we assumed that `yb_ash_ExecutorStart` must have pushed a query id into the nested query id stack. But in this case, it was a `COMMIT` statement, so it goes through the `yb_ash_ProcessUtility` path, which pushes and pops a query id from the stack. `yb_ash_ExecutorStart` is never called in this case. So we try to pop from an empty stack. This diff fixes the assertion failure by checking that the stack is non-empty before popping. And in case of nested queries, where the stack size can be greater than 1, we check for the query id before popping so that only the correct query id is popped. Jira: DB-12200 Test Plan: Jenkins The assertion failure was fixed here after diff id 213903 with the same change from this diff Jenkins results: https://detective.dev.yugabyte.com/D36430?show_all_diffs=1#tests-failing-in-213903 Not triggering jenkins with ASH enabled by default because there are different kinds of tests which fails. Reviewers: jason Reviewed By: jason Subscribers: amitanand, hbhanawat, yql Differential Revision: https://phorge.dev.yugabyte.com/D36801
jasonyb
pushed a commit
that referenced
this issue
Jul 25, 2024
Summary: 5aa0c0a [PLAT-14078] Add local provider test for update databases cdd97f8 remove ea badge (#23276) 2813d78 [PLAT-14156][PLAT-14323]: Move all UI Driven flags to INTERNAL and remove YBM key as its not used 49523f5 [PLAT-14733]: Add support for OIDC attributes jwt_jwks_path and jwt_jwks_url b039d1a [PLAT-14366] Basic local provider test for master auto failover 700fd49 [#23275] docdb: Fix missing home icon on master UI 89e434e [#13254] YSQL: import pgtap v1.3.3 1b3585f [doc][cdc] Updated diagrams (#23262) 399f165 [#23266] YSQL: Only require YB Admin privileges to run pg_locks 5a4bbd4 [#19954] docdb: Register both tablet split children atomically b4c4294 [PLAT-14617] Add support for numerical search and enable extra search fields forxCluster 84fb7ad [#22449] YSQL: wal2json YB specific changes afe84d4 [#13254] YSQL: add pgtap to build adf3c54 [#23272] YSQL, ASH: Fix incorrect popping of query id from nested query ids stack 3b42c2e [docs] Add syntax documentation for logical replication (#23270) Test Plan: Jenkins: rebase: pg15-cherrypicks Reviewers: jason, tfoucher Tags: #jenkins-ready Differential Revision: https://phorge.dev.yugabyte.com/D36841
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Jira Link: DB-12200
Description
Many tests fail with this assertion failure because
ExecutorEnd
is called duringPortalCleanup
after a utility statementIssue Type
kind/bug
Warning: Please confirm that this issue does not contain any sensitive information
The text was updated successfully, but these errors were encountered: