Skip to content

Conversation

@petersomogyi
Copy link
Contributor

No description provided.

@petersomogyi petersomogyi requested a review from ndimiduk July 13, 2020 12:35
@Apache-HBase

This comment has been minimized.

@Apache-HBase

This comment has been minimized.

@Apache-HBase

This comment has been minimized.

@petersomogyi petersomogyi requested a review from busbey July 14, 2020 09:30
Copy link
Member

@ndimiduk ndimiduk left a comment

Choose a reason for hiding this comment

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

Thanks for the general cleanup.

if ! [ -x "$(command -v gpg)" ]; then
srcChecksum="Unknown"
else
srcChecksum=`find hbase-*/src/main/ | grep -e "\.java" -e "\.proto" | LC_ALL=C sort | xargs gpg --print-md sha512 | gpg --print-md sha512 | cut -d ' ' -f 1`
Copy link
Member

Choose a reason for hiding this comment

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

Previous use of cut here at the end is surprising. It took only the first block...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Based on history it was used for md5 and md5sum commands but it wasn't removed when SHA512 was introduced in saveVersion.sh.

root@8224f4c69e6f:/# echo "foo" | md5sum
d3b07384d113edec49eaa6238ad5ff00  -

Copy link
Member

Choose a reason for hiding this comment

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

Does tr -d '[:space:]' work? It's simpler and shorter than tr '\n' ' ' | sed 's/[[:space:]]*//g'

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I get a different output from your command, an extra %.

find hbase-*/src/main/ | grep -e "\.java" -e "\.proto" | LC_ALL=C sort | xargs gpg --print-md sha512 | gpg --print-md sha512 | tr -d '[:space:]'
3BF4CCC275112769C7AB0EDC302793FB81005BDC9681E1604BD965918363FC93311FC60B24000563DD4D3EFDA10685F549721A28428F23487813A7397FBC9BD0%
ind hbase-*/src/main/ | grep -e "\.java" -e "\.proto" | LC_ALL=C sort | xargs gpg --print-md sha512 | gpg --print-md sha512 | tr '\n' ' ' | sed 's/[[:space:]]*//g'
3BF4CCC275112769C7AB0EDC302793FB81005BDC9681E1604BD965918363FC93311FC60B24000563DD4D3EFDA10685F549721A28428F23487813A7397FBC9BD0

Copy link
Member

@liuml07 liuml07 Jul 20, 2020

Choose a reason for hiding this comment

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

That's weird. I did not see in my macOS and Ubuntu Linux. But since this is not reliable, I guess we can stay with your script tr and sed - which works for me on both macOS and Ubuntu.

fi
else
srcChecksum=`find hbase-*/src/main/ | grep -e "\.java" -e "\.proto" | LC_ALL=C sort | xargs openssl dgst -sha512 | openssl dgst -sha512 | cut -d ' ' -f 1`
srcChecksum=$(find hbase-*/src/main/ | grep -e "\.java" -e "\.proto" | LC_ALL=C sort xargs openssl dgst -sha512 | openssl dgst -sha512 | sed 's/^.* //')
Copy link
Member

Choose a reason for hiding this comment

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

what is the purpose of the final sed? I see no difference.

$ echo "foo" | openssl dgst -sha512 | sed 's/^.* //'
0cf9180a764aba863a67b6d72f0918bc131c6772642cb2dce5a34f0a702f9470ddc2bf125c12198b1995c233c34b4afd346c54a2334c350a948a51b6e8b4e6b6
$ echo "foo" | openssl dgst -sha512
0cf9180a764aba863a67b6d72f0918bc131c6772642cb2dce5a34f0a702f9470ddc2bf125c12198b1995c233c34b4afd346c54a2334c350a948a51b6e8b4e6b6

Copy link
Member

Choose a reason for hiding this comment

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

Oh, this is the example from your comment on JIRA, a difference between the mac and linux versions of openssl dgst. Disregard.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 35s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
_ Patch Compile Tests _
_ Other Tests _
1m 30s
Subsystem Report/Notes
Docker Client=19.03.12 Server=19.03.12 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-2056/2/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR #2056
Optional Tests
uname Linux d8d04fa9a000 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 2505c77
Max. process+thread count 47 (vs. ulimit of 12500)
modules C: hbase-common U: hbase-common
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-2056/2/console
versions git=2.17.1 maven=(cecedd343002696d0abb50b32b541b8a6ba2883f)
Powered by Apache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 35s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
_ Patch Compile Tests _
_ Other Tests _
1m 28s
Subsystem Report/Notes
Docker Client=19.03.12 Server=19.03.12 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-2056/2/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR #2056
Optional Tests
uname Linux a40603fd2e90 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 2505c77
Max. process+thread count 43 (vs. ulimit of 12500)
modules C: hbase-common U: hbase-common
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-2056/2/console
versions git=2.17.1 maven=(cecedd343002696d0abb50b32b541b8a6ba2883f)
Powered by Apache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 34s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 shelldocs 0m 0s Shelldocs was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
_ Patch Compile Tests _
+1 💚 shellcheck 0m 0s The patch generated 0 new + 0 unchanged - 10 fixed = 0 total (was 10)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
_ Other Tests _
+1 💚 asflicense 0m 12s The patch does not generate ASF License warnings.
1m 46s
Subsystem Report/Notes
Docker Client=19.03.12 Server=19.03.12 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-2056/2/artifact/yetus-general-check/output/Dockerfile
GITHUB PR #2056
Optional Tests dupname asflicense shellcheck shelldocs
uname Linux 2b002e7bec9d 4.15.0-101-generic #102-Ubuntu SMP Mon May 11 10:07:26 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 2505c77
Max. process+thread count 42 (vs. ulimit of 12500)
modules C: hbase-common U: hbase-common
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-2056/2/console
versions git=2.17.1 maven=(cecedd343002696d0abb50b32b541b8a6ba2883f) shellcheck=0.4.6
Powered by Apache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@liuml07
Copy link
Member

liuml07 commented Jul 17, 2020

LGTM

@petersomogyi petersomogyi merged commit ea96743 into apache:master Jul 21, 2020
petersomogyi added a commit that referenced this pull request Jul 21, 2020
petersomogyi added a commit that referenced this pull request Jul 21, 2020
clarax pushed a commit to clarax/hbase that referenced this pull request Nov 15, 2020
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.

4 participants