-
Notifications
You must be signed in to change notification settings - Fork 8.8k
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
HADOOP-16768. SnappyCompressor test cases wrongly assume that the compressed data is always smaller than the input data. #2003
Conversation
@aajisaka I observed the same issue on CentOS 8 as reported in HADOOP-17034. While the patch fixed the error of TestSnappyCompressorDecompressor, TestCompressorDecompressor still fails due to NullPointerException. There was no issue on CentOS 7 with and without the patch. |
💔 -1 overall
This message was automatically generated. |
Thanks @iwasakims for the testing. Sorry I missed TestCompressorDecompressor failure on Ubuntu 18.04. I fixed the test. |
In addition, I refactored the test to print the following error before fixing this failure:
|
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
...oject/hadoop-common/src/main/java/org/apache/hadoop/io/compress/snappy/SnappyCompressor.java
Outdated
Show resolved
Hide resolved
Added testSnappyCompressDecompressWithSmallBuffer. This test case throws IndexOutOfBoundsException if |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
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.
+1. The fix worked on CentOS 8 too. Thanks, @aajisaka.
Oops. You can address checkstyle warnings before merge. |
🎊 +1 overall
This message was automatically generated. |
Thank you @iwasakims! |
…pressed data is always smaller than the input data. (apache#2003) (cherry picked from commit 328eae9)
…pressed data is always smaller than the input data. (#3264) * HADOOP-16768. SnappyCompressor test cases wrongly assume that the compressed data is always smaller than the input data. (#2003) (cherry picked from commit 328eae9) * Add assertj-core dependency to hadoop-common for test * Bump assertj-core version to 3.12.2 to use assertThat.hasSizeGreaterThan
…pressed data is always smaller than the input data. (apache#2003) (cherry picked from commit 328eae9)
JIRA: https://issues.apache.org/jira/browse/HADOOP-16768
Note that perhaps there is the same issue in other compressors.
I ran the tests in both CentOS 7 and Ubuntu 18.04.