Move already created check inside of metastore implementations#19969
Merged
Move already created check inside of metastore implementations#19969
Conversation
1eb723a to
fdcc554
Compare
eb572bc to
3db0132
Compare
3db0132 to
20496ef
Compare
electrum
approved these changes
Dec 2, 2023
plugin/trino-delta-lake/src/main/java/io/trino/plugin/deltalake/DeltaLakeMetadata.java
Outdated
Show resolved
Hide resolved
...ino-delta-lake/src/main/java/io/trino/plugin/deltalake/procedure/RegisterTableProcedure.java
Outdated
Show resolved
Hide resolved
plugin/trino-hive/src/main/java/io/trino/plugin/hive/metastore/file/FileHiveMetastore.java
Outdated
Show resolved
Hide resolved
plugin/trino-hive/src/main/java/io/trino/plugin/hive/metastore/file/FileHiveMetastore.java
Outdated
Show resolved
Hide resolved
...rino-hive/src/test/java/io/trino/plugin/hive/metastore/thrift/AbstractTestHiveMetastore.java
Outdated
Show resolved
Hide resolved
...rino-hive/src/test/java/io/trino/plugin/hive/metastore/thrift/AbstractTestHiveMetastore.java
Outdated
Show resolved
Hide resolved
...rino-hive/src/test/java/io/trino/plugin/hive/metastore/thrift/AbstractTestHiveMetastore.java
Outdated
Show resolved
Hide resolved
Member
There was a problem hiding this comment.
You need to add this to the POM in two places. Search for and duplicate TestHiveS3AndGlueMetastoreTest
Member
Author
There was a problem hiding this comment.
Turns out it is already there, because there is another test with the same name in a different package
20496ef to
4295ae8
Compare
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.
Move the logic to not throw SchemaAlreadyExistsException or TableAlreadyExistsException when the table/schema was already created by the qyery (e.g., retry after timeout), inside the HiveMetastore implementations. This consolidated the logic into code that is reused several connectors, and makes the logic easier to test.
Release notes
(x) This is not user-visible or is docs only, and no release notes are required.