-
Notifications
You must be signed in to change notification settings - Fork 435
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
GH-465: Clarify backward-compatibility rules on LIST type #466
Conversation
abc3d1d
to
d9579bc
Compare
BTW, can you also point out the Java code in this pr? |
Other LGTM but I think it worths issue a disscussion... |
4551c79
to
f200d34
Compare
I have sent a discussion thread to the dev ML. It would be good if you can take a look. Thanks! @emkornfield @pitrou @gszadovszky @rdblue @etseidl @clairemcginty |
f200d34
to
fc8aca3
Compare
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.
Seems like a nice clarification to me. One little (ignorable) nit.
I'm also wondering if we should add an example above for the non-LIST annotated repeating fields, or should that be a new PR?
This comment was marked as resolved.
This comment was marked as resolved.
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.
Thanks for clarifying! This is so tricky especially rule 3 and rule 4 in 2-level lists...
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.
Thanks for being patient with me Gang 😄. And thanks for taking on this needed clarification.
Ah, ok. Now I understand. That's why the 2-level list needs the ability to be |
@gszadovszky @etseidl @rdblue @pitrou @emkornfield Do you have any concern about this PR? I think we need to move forward now. |
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.
All my concerns have been addressed. Thanks!
Co-authored-by: emkornfield <[email protected]>
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.
Rest LGTM
repeated group my_list { | ||
required int32 num; | ||
optional binary str (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.
I think this example is counter-productive. We don't want anyone using un-annotated lists and maps. While the paragraph above explains how to interpret un-annotated repeated
fields, I don't want anyone to see an example here and think that it is something that should be copied. I think it is already clear enough and I would simply move on rather than drawing attention to this as a possibility.
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.
That make sense. Let me remove these examples first. I think a followup is to deprecate it by moving it to the backward compatibility section and adding strong words to discourage writers to emit it.
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.
The rules part is looking good, but I think that spending time documenting what people did incorrectly years ago makes the doc more confusing and increases chances that people will write invalid lists. I'd prefer to revert most of the changes that explain what people did incorrectly.
I agree. But I think those can be posted on the pull-request description |
@rdblue Thanks for your review! I have removed all unnecessary changes. Please take a look again. |
@rdblue @wgtmac I'm not sure I agree with removing the examples. They make it less likely that an implementation would interpret the written rules wrongly, IMO. Maybe we can instead strengthen the wording that these examples show existing legacy schemas, not anything to be written by modern writers. |
Concretely, if I have to review a PR implementing said compatibility rules, I'd rather have the spec spell out the examples because it makes it easier to check the PR's implementation (and unit tests!). |
Perhaps add them like this? @pitrou
|
Ok, please don't use UPPERCASE :) |
@pitrou @gszadovszky @rdblue Do you have any concern with the latest change? |
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 do not have any concerns. Looks good to me!
Will merge this by the end of this week if no objection. |
Rationale for this change
The C++ reader of parquet-cpp is having a hard time to read Parquet file written by parquet-java with
parquet.avro.write-old-list-structure=true
and schema below:See apache/arrow#43994 and apache/arrow#43995
What changes are included in this PR?
Clarify the rules for various list types.
Do these changes have PoC implementations?
Not required
Closes #465