[Android] Add --mnemonic_cache_salt flag for Bazel 8.1.1 - #31
Closed
azad-uber-2 wants to merge 3 commits into
Closed
azad-uber-2 wants to merge 3 commits into
azad-uber-2 wants to merge 3 commits into
Conversation
|
|
azad-uber-2
force-pushed
the
azad/mnemonic-cache-salt-8.1.1
branch
from
May 29, 2026 19:31
1735701 to
5d3ae4b
Compare
Remove two extra closing braces that cause a syntax error during the java_tools bootstrap build (unexpected token: void). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The desugar_jdk_libs.jar target no longer exists in the Bazel 8 tree, causing the android_tools bootstrap build to fail. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…validation Add a new `--mnemonic_cache_salt=<Mnemonic>=<value>` flag that allows selectively busting the local and remote action cache for specific action types (e.g. `--mnemonic_cache_salt=Javac=V2`). The salt is included in the action properties digest (local cache) and in the CacheSalt proto (remote cache), so changing or removing it forces a cache miss only for the targeted mnemonic. Salts for unrelated mnemonics have no effect on other actions. Changes: - ExecutionOptions: add `--mnemonic_cache_salt` flag + `getMnemonicCacheSalts()` helper - ActionCache.Entry: include optional mnemonic salt in `digestActionProperties()` - ActionCacheChecker: thread `mnemonicCacheSalts` through `getTokenIfNeedToExecute()` and `updateActionCache()`; add backward-compat overloads - SkyframeActionExecutor / SkyframeExecutor: accept and store `mnemonicCacheSalts` at configure time - SkyframeBuilder / ExecutionTool: read the flag and pass it down through the builder pipeline - RemoteExecutionService: include mnemonic salt in `CacheSalt` proto for remote cache - RemoteActionContextProvider: wire `mnemonicCacheSalts` into `RemoteExecutionService` via setter - cache_salt.proto: add `mnemonic_salt` field (field 4) - Tests: fix pre-existing 8-param `updateActionCache` call; add 7 new tests covering salt hit/miss semantics Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
azad-uber-2
force-pushed
the
azad/mnemonic-cache-salt-8.1.1
branch
from
May 31, 2026 22:35
5d3ae4b to
1bc9d55
Compare
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Cherry-pick of fae19c5 from
uber/android/7.6.1touber/android/8.1.1with adaptations for the Bazel 8 codebase:combineUnordered) but is needed by the mnemonic cache salt feature.staticin 8.1.1 (was non-static in 7.6.1), somnemonicCacheSaltsis passed as a parameter instead of accessed as an instance field.desugar_jdk_libs.jardependency (file doesn't exist in Bazel 8 tree).Test plan
🤖 Generated with Claude Code
Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com