Conversation
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
from
September 30, 2026 23:41
d43958d to
a136fb4
Compare
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
from
October 1, 2026 19:13
a136fb4 to
703c080
Compare
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
2 times, most recently
from
October 1, 2026 21:22
10a0809 to
924d8e8
Compare
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
from
October 1, 2026 22:29
924d8e8 to
2706eca
Compare
praba2210
marked this pull request as ready for review
October 5, 2026 17:29
praba2210
requested review from
a team,
arnewouters,
krokoko and
laithalsaadoon
October 5, 2026 17:29
praba2210
requested review from
Benjscho,
amaksimo,
anwesham-lab,
gxjx-x,
jaichabria,
pkale and
spencercorwin
October 5, 2026 17:29
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
from
October 5, 2026 18:12
2706eca to
d482636
Compare
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
from
October 5, 2026 21:33
d482636 to
e62a465
Compare
Contributor
Author
|
Self-review against a live cluster. 17 issues found and fixed.
Two things no AWS page documents, both measured here:
|
troubleshooting.md covered only 40001 and 23503, and five of its quoted error messages did not match what DSQL emits. One matches nothing in the real text, so an agent looking it up finds nothing. Adds a Limits and Error Codes section: 22 limits, 20 rejections and 10 cluster quotas, each with its SQLSTATE and exact message. 54000 covers 15 limit rows and 0A000 covers 13 rejections, so within the section the message is the discriminator, not the code. Four corrections change the advice: - OC001 is 40001, already in the OCC retry loop. OC000 is the DML conflict. OC001 fires when a transaction's snapshot predates a catalog change, which includes GRANT and REVOKE as well as DDL, and whether or not the change is still in flight. A retry takes a fresh snapshot and clears a one-shot change; only a session that keeps changing the catalog needs serializing. - "unable to accept connection" is a prefix shared by five conditions. Only the Signature expired hint means the token is stale, and regenerating cannot fix a skewed host clock. HINT is a separate protocol field, so the guidance names it per driver. - An EOF at or after COMMIT leaves the commit outcome unknown, so a bare retry can double-write. Adds what to do when the outcome cannot be established at all. - dsql_lint strips index sort order rather than preserving it, and the severity depends on the direction: DESC is a warning, ASC is neither an error nor a warning, so gating on either counter misses the rewrite. Gate on the diagnostic list instead. Corrects key size to about 1,981 usable bytes, shared across all key columns and with any secondary index, and the 24-index limit to include the primary key, so a table with one accepts 23 secondary. Both confirmed against a cluster: a 500-byte primary key leaves 1,455 bytes for a secondary index key, and totals hold near 1,955 whatever the split. Key size, temp space and view-definition size all differ from the quotas page; each row now says so. Secondary indexes also count against the 10 MiB transaction limit, which is documented nowhere. Accounted size runs about 150 bytes per row above raw, plus about 430 per secondary index entry, measured linear across 0, 1, 2 and 4 indexes and predictive to within 1% from 200 to 2,900 rows. A 3,000-row batch on a four-index table loses roughly 5 MiB before any payload counts. The eval grader accepted "24 secondary indexes" and a fixture pinned it as passing, so the suite graded the error this commit fixes as a correct answer. It also failed correct answers laid out as a quoted table, bullet list or bolded number, which is what an eval requiring a documentation call tends to produce. The grader now matches the number and the index noun in either order, accepts bare "per table" and "can have" as bounds, and scopes the inclusive exemption to the statement that triggered the veto so one correct sentence no longer licenses a wrong claim elsewhere. Adds the excluding phrasings it missed: not including, doesn't count, plural primary keys, a fronted clause and an em dash. Six tests pin 20 phrasings. Adds five evals for the sort-order, transaction-size, EOF-at-COMMIT, catalog-change and key-size guidance, which had none. Also drops DESC from two index examples that return 0A000 today. A direction-free index serves a uniformly ordered ORDER BY by backward scan when the keys are a leading prefix and the projection is covered; mixed ordering adds a sort. Bumps the plugin version to 1.10.0.
praba2210
force-pushed
the
fix/dsql-limits-and-error-messages
branch
from
October 5, 2026 23:11
e62a465 to
ebbd8a2
Compare
Contributor
Author
|
Second review pass against a live cluster.
Also corrected the eval README's prompt and assertion counts and two stale wordings.
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
references/troubleshooting.mdis where an agent looks up a DSQL error before acting on it. Five of its quoted messages are not what DSQL emits — one matches nothing at all — so the lookup silently fails. Coverage also stopped at40001and23503, leaving common failures liketransaction row limit exceededwith no entry.Related
Follows #278, which touched
index-conversion.md. That PR saiddsql_lintpreserves index key sort order; this one reverses it — DSQL rejects sort direction outright. Read## Index Key Sort Orderas a correction to #278, not an addition.Changes
## Limits and Error Codesintroubleshooting.md— 22 limits, 20 rejections and 10 cluster quotas, each with its SQLSTATE and exact message.54000covers 15 of the rows and0A000covers 13, so the message is the discriminator, not the code.Token has expired,Transaction exceeds 3000 rows,Datatype array not supported,Please use CREATE INDEX ASYNC,OC001 - Concurrent DDL operation.OC001is40001and already inside the retry loop;unable to accept connectionis a prefix shared by five conditions and only theSignature expiredhint means a stale token;dsql_lintstrips sort order rather than preserving it, and silently forASC; an EOF at or afterCOMMITleaves the outcome unknown, so a bare retry can double-write.DESC, which returns0A000today.COMMIT, catalog change, key size). The grader accepted24 secondary indexesand a fixture pinned that as passing, so the suite graded this PR's bug as a correct answer. It now rejects that framing worded either way, and no longer fails correct answers laid out as a table, bullet list or bolded number.Two behaviours no AWS page documents, both measured here:
accounted ≈ raw + rows × (~150 B + ~430 B per secondary index). A 3,000-row batch on a four-index table loses ~5 MiB before any payload counts, so a statement that commits against a bare table fails against an indexed one. The docs scope the 3,000-row limit as applying "regardless of the number of secondary indexes"; that independence does not carry to the size limit.OC001is any catalog change.GRANTandREVOKEraise it, one change is enough, it need not be concurrent, and only transactions that write are affected.Verification
EXPLAIN. Cluster quotas are documented only, not exercised.mise run buildpasses — 133 unit tests, 27 functional evals, 118 assertions.Version
1.9.1→1.10.0across the three manifests — minor: new guidance plus an eval change.Acknowledgment
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the project license.