Skip to content
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

HDDS-2605. Use LongSupplier to avoid boxing #256

Merged
merged 1 commit into from
Nov 22, 2019

Conversation

adoroszlai
Copy link
Contributor

What changes were proposed in this pull request?

Freon's ProgressBar uses Supplier<Long>, which could be replaced with LongSupplier to avoid boxing.

Additional cleanup:

  • re-interrupt after InterruptedException
  • avoid concatenation in append() call
  • avoid the name progressBar for a member in ProgressBar (per Sonar)

https://issues.apache.org/jira/browse/HDDS-2605

How was this patch tested?

ozone freon rk and TestProgressBar.

Copy link
Contributor

@swagle swagle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 LGTM.

QQ: Is this purely readability related?

Copy link
Contributor

@dineshchitlangia dineshchitlangia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 LGTM. Thanks @swagle for reviews & @adoroszlai for contribution.

@dineshchitlangia dineshchitlangia merged commit 571d4a3 into apache:master Nov 22, 2019
@adoroszlai adoroszlai deleted the HDDS-2605 branch November 22, 2019 06:51
@adoroszlai
Copy link
Contributor Author

Thanks @swagle and @dineshchitlangia for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants