Skip to content

Conversation

@adoroszlai
Copy link
Contributor

What changes were proposed in this pull request?

Checkout project to its regular location (inside GITHUB_WORKSPACE) before attempting to restore cache. This allows calculation of hash of cache key files (pom.xml, pnpm-lock.yaml)

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

How was this patch tested?

Verified that cache key now includes hash of files:

Cache not found for input keys: maven-repo-78a78691596adf599a9afd1481471aa13fb05402873415b8199d404fd937eae2
...
Cache not found for input keys: Linux-pnpm-17a93e576bec6596513e8336af475af9b856a1ba83ab27dd39d06fe763dac835, Linux-pnpm-

https://github.com/adoroszlai/hadoop-ozone/runs/1042731167#step:3:5
https://github.com/adoroszlai/hadoop-ozone/runs/1042730953#step:4:9

and subsequent build on same branch reuses cache:

Cache restored from key: maven-repo-78a78691596adf599a9afd1481471aa13fb05402873415b8199d404fd937eae2
...
Cache restored from key: Linux-pnpm-17a93e576bec6596513e8336af475af9b856a1ba83ab27dd39d06fe763dac835

https://github.com/adoroszlai/hadoop-ozone/runs/1042919167#step:3:10
https://github.com/adoroszlai/hadoop-ozone/runs/1042919016#step:4:13

@adoroszlai adoroszlai self-assigned this Aug 28, 2020
@vivekratnavel
Copy link
Contributor

@adoroszlai Thanks for fixing this! +1 LGTM

Copy link
Member

@elek elek 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 to fix (and thanks the review @vivekratnavel)

I have a strange feeling that we do an additional checkout just to hash pom.xml but I have no better idea ;-)

@elek elek merged commit 77d56e6 into apache:master Sep 2, 2020
@adoroszlai adoroszlai deleted the HDDS-4165 branch September 2, 2020 17:01
@adoroszlai
Copy link
Contributor Author

Thanks @vivekratnavel for the review, and @elek for reviewing and committing it.

rakeshadr pushed a commit to rakeshadr/hadoop-ozone that referenced this pull request Sep 3, 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.

3 participants