Skip to content

Commit

Permalink
Gradle: Add v2 suffix on the gradle dependency cache key
Browse files Browse the repository at this point in the history
This is done in order to differentiate between the 'GRADLE_RO_DEP_CACHE'
and the 'GRADLE_DEP_CACHE' caches, and thus be able to test both caching
strategies in-parallel, without one overwriting the other during save,
or one reusing the other's cache during restore.

Test Only PRs:
- WCAndroid: https://github.com/woocommerce/woocommerce-android/
pull/13170
- JP/WPAndroid: https://github.com/wordpress-mobile/WordPress-Android/
pull/21550
  • Loading branch information
ParaskP7 committed Jan 10, 2025
1 parent 61b1d9d commit 94d9f7a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bin/restore_gradle_dependency_cache
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash -eu

# The key is shared with `bin/save_gradle_dependency_cache`
GRADLE_DEPENDENCY_CACHE_KEY="${BUILDKITE_PIPELINE_SLUG}_GRADLE_DEPENDENCY_CACHE"
GRADLE_DEPENDENCY_CACHE_KEY="${BUILDKITE_PIPELINE_SLUG}_GRADLE_DEPENDENCY_CACHE_V2"

echo "Restoring Gradle dependency cache..."

Expand Down
2 changes: 1 addition & 1 deletion bin/save_gradle_dependency_cache
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash -eu

# The key is shared with `bin/restore_gradle_dependency_cache`
GRADLE_DEPENDENCY_CACHE_KEY="${BUILDKITE_PIPELINE_SLUG}_GRADLE_DEPENDENCY_CACHE"
GRADLE_DEPENDENCY_CACHE_KEY="${BUILDKITE_PIPELINE_SLUG}_GRADLE_DEPENDENCY_CACHE_V2"

echo "Saving Gradle dependency cache..."

Expand Down

0 comments on commit 94d9f7a

Please sign in to comment.