Fix Delta writes when schema location ends with two slashes#17964
Closed
findepi wants to merge 9 commits intotrinodb:masterfrom
Closed
Fix Delta writes when schema location ends with two slashes#17964findepi wants to merge 9 commits intotrinodb:masterfrom
findepi wants to merge 9 commits intotrinodb:masterfrom
Conversation
fc4b1e1 to
5abf6f1
Compare
findepi
commented
Jun 20, 2023
Hive connector does not support table locations containing double slashes. On S3 this leads to correctness issues (e.g. INSERT works, but SELECT does not find any data). This commit - restores normalization of implicit table location during CREATE TABLE. There used to be such normalization until 8bd9f75. - rejects explicit table locations containing double slash during `CREATE TABLE .. WITH (external_location = ...)`. Before 8bd9f75 there used to be normalization also during this flow, but rejecting such unsupported locations is deemed more correct.
Configure bucket used in `TestIcebergS3AndGlueMetastoreTest` same way as in other `BaseS3AndGlueMetastoreTest` subclasses. Makes it easier to run tests locally. This also changes `TestIcebergGlueCatalogConnectorSmokeTest` for consistency.
This may be needed when working with MinIO containers where bucket names can be reused. This is not needed when working with real S3 where bucket names are unique. Also, it's unclear whether this is a safe operation when tests execute in parallel.
The `String.contains`-based inclusions/exclusions doesn't allow distinguishing between hypothetical cases like "trailing_slash" and "two_trailing_slashes". This also simplifies generated test locations for schemas. Previously the schema name was formatted twice into the location string.
Remove constructor which doesn't construct the table. Since it was randomizing the name, it couldn't even be used for dropping existing table.
Use try with resources to ensure that test tables are dropped even if an assertion fails.
5abf6f1 to
dcf5783
Compare
Member
Author
|
resubmitted as #17980 |
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.
Extracted from #17958
Fixes #17966