Repository navigation
feat(query): SHOW/TERMINATE SESSIONS - #1814
katarinasupe wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
andrejtonev
left a comment
There was a problem hiding this comment.
Thanks for writing this up! I checked every statement against current master (6e9c79da3), on a live instance as well as in the code. Most of it is accurate. The inline comments cover two statements that are wrong for 3.14 (SESSIONS isn't reserved, and the forced-DROP DATABASE example no longer applies after #4843), a few that overstate what happens (killed: true, "running query is aborted"), and some behaviour that's missing: open-transaction rollback, what the client sees and driver retries, auth disabled, Community vs Enterprise, impersonation, coordinators, LOGOFF and $id parameters. Every suggestion was re-run against master.
Three things outside this diff:
TERMINATE TRANSACTIONS $id(around line 340): "A parameterized id is treated exactly like a literal one, so runningTERMINATE TRANSACTIONS $idwith$id = "*"also terminates everything." This has never worked. The grammar only accepts a literal there (transactionId : literal, unchanged since the query was added), soTERMINATE TRANSACTIONS $idis a syntax error (extraneous input '$' expecting ...) whatever$idis. The sentence came in with v3.13 (#1689). Suggested replacement: "Transaction ids, including"*", must be string literals. Query parameters such as$idaren't supported and cause a syntax error."SHOW TRANSACTIONScolumns (line 95): since memgraph#4571 (3.14, listed under breaking changes in #1764),SHOW TRANSACTIONSreturns an 8th column,database, afterelapsed_ms. The page still says "contains seven columns", and the column table and example outputs don't include it. Suggested row:| database | String | The database the transaction is running on. |- PR description: it says the
SHOW TRANSACTIONSfix is internal and "the release note already covers it". It doesn't: onrelease/3.14the only #4577 entry is the feature line. I've suggested a bug-fix line on #1764.
Documents the session management queries from memgraph/memgraph#4577: listing open Bolt sessions and terminating them from another connection, who can see and terminate which sessions, the result columns, and the SESSIONS reserved keyword. Adds both queries to the query privileges table. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Also fix the TERMINATE TRANSACTIONS parameter claim and add the database column of SHOW TRANSACTIONS.
5f68665 to
54ce812
Compare
Description
Documents
SHOW SESSIONSandTERMINATE SESSIONSon the Transactions page and in the query privileges table. Also fixes two older statements on the same page:TERMINATE TRANSACTIONS $id(parameters were never accepted) and the newdatabasecolumn ofSHOW TRANSACTIONS(memgraph/memgraph#4571).Not done:
SHOW TRANSACTIONSexample outputs still show seven columns; I don't know whatdatabaseshows on snapshot and GC rows.SHOW ACTIVE USERSalso gained columns in #4571 (server-stats page).Product PR
memgraph/memgraph#4577
Checklist
featureorbugfixlabel added