Repository navigation
Support explicit primary keys for YDB table creation - #266
Merged
Merged
Conversation
KirillKurdyukov
marked this pull request as ready for review
September 20, 2026 19:34
KirillKurdyukov
enabled auto-merge (squash)
September 20, 2026 19:35
KirillKurdyukov
disabled auto-merge
September 20, 2026 19:41
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.
YDB requires a primary key when creating a table. Add the ordered
primary_keytable property for production CREATE TABLE and CREATE TABLE AS, using the standard JDBC table-properties provider. No hidden key column is added.Reject missing, empty, duplicate, null-element, and unknown key definitions with INVALID_TABLE_PROPERTY. Read the key order from JDBC metadata for SHOW CREATE TABLE. Add production-client tests for composite keys, CTAS, invalid properties, and cleanup after failed CTAS, while preserving the inherited test fixtures.
Validation: head 65ba286 passed independent source review, JDK 25 clean compile/testCompile, and the ordinary full CI run 35532456276.
mvn --batch-mode --update-snapshots -Dstyle.color=always clean testcompleted with 311 tests: 226 passed, 85 skipped, 0 failures, 0 errors. The new production class passed all 4 checks (3 feature tests plus a framework check); inherited smoke/connector results remain 222 passed and 85 skipped. The workflow is unchanged. Local Docker/Colima remains unavailable.The complete diff against main is 197 additions and 2 deletions across 8 files.
CTAS tests use
insert.non-transactional-insert.enabled=true; transactional staging support is not established by these tests. The three added production tests are separate from inherited connector coverage.