-
Notifications
You must be signed in to change notification settings - Fork 13.8k
[FLINK-11140][streaming] Fix empty child path check in Buckets #7287
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
Conversation
yanghua
left a comment
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 your contribution @Matrix42 . I left one minor suggestion. In addition, It would be better to add a test for this fix. What's more, please follow the PR template and fill the section of Brief change log and Verifying this change out correctly.
| if ("".equals(child)) { | ||
| return basePath; | ||
| } | ||
| return new Path(basePath, bucketId.toString()); |
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.
Now that you have given bucketId.toString() to the variable child, you can change it to: return new Path(basePath, child);
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.
@yanghua thanks for your review, i will fix this
|
IMO an empty bucket Id doesn't make any sense as it effectively disables bucketing. |
|
Oh for heaven's sake this is one of our classes isn't it. god damn it. |
|
@Matrix42 I think this is a valid issue. I will have a look to the PR now and thanks for reporting it. |
|
@Matrix42 I have reviewed your PR and I have some comments. Given that the PR is closed and I cannot submit a review, I pushed my changes in my branch here: https://github.com/kl0u/flink/tree/buckets Feel free to integrate them and open a new PR and I can review it again. In a nutshell, the changes that I propose are:
All these are included in my branch. Feel free to ping me when you open the new PR. |
|
Thanks @Matrix42 ! Please ping me when you integrate the comments. |
|
Sorry, I just saw that you addressed the comments. I will review soon. |
kl0u
left a comment
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 reporting the issue and working on it @Matrix42! Changes look good. I will merge as soon as Travis gives the green light.
What is the purpose of the change
Fix empty child path check in Buckets
Brief change log
add check for empty child path in Buckets
Verifying this change
BucketsTest#testAssembleBucketPath()
Does this pull request potentially affect one of the following parts:
Documentation