-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use the storage location name as the key in the clade schema #556
Conversation
@@ -11,16 +11,18 @@ message TableObject { | |||
string name = 1; | |||
// Path within the provided storage location, if any | |||
string path = 2; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know we don't care about backwards compatibility here, but should we try to follow Protobuf guidelines on field number assignment?: https://protobuf.dev/programming-guides/proto3/#assigning . This could help make errors clearer in case of a server/client protocol mismatch.
Specifically:
- NewProtocol.TableObject.store seems like a distinct field from OldProtocol.TableObject.location, so should use a new field number
- NewProtocol.StorageLocation.location seems like the same field as OldProtocol.StorageLocation.location, so should stay as field number 1
- NewProtocol.StorageLocation.options seems like the same field as OldProtocol.StorageLocation.options, so should stay as field number 2
src/catalog/metastore.rs
Outdated
@@ -140,21 +140,21 @@ impl Metastore { | |||
async fn build_table( | |||
&self, | |||
table: TableObject, | |||
store_options: &HashMap<String, HashMap<String, String>>, | |||
store_options: &HashMap<String, (String, HashMap<String, String>)>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's 4 Strings in this type and it wasn't clear on first reading what each of them is. Maybe add a comment about this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, will do.
As opposed to keying them via their root URL.