Bazel 5.2.0 not support
When upgrade to the latest version of bazel. Bazel remote seems not to work. Bazel can only put but can not get. When use bazel 5.1.1 bazel remote works again. More strange, bazel 5.2.0 can use the cache of 5.1.1. It seems that the artifact put by bazel 5.2 has problem.
Hi, I am unable to reproduce this with the bazel-remote build and bazel 5.2.0 - I'm able to populate the cache, then bazel clean and building again gives cache hits. Could you share your bazel-remote config and the bazel flags that you're using?
Thanks for reply. We use the following script to run a container:
docker run -d -u 1000:1000 --name bazel_cache --restart=unless-stopped -v /work/bazel_cache:/data
-p 9090:8080 -p 9092:9092 buchgr/bazel-remote-cache --max_size=300 --storage_mode=uncompressed
bazelrc config:
build --repository_cache=/xx/repository_cache
# Enable bazel remote cache
build --remote_cache=http://host.docker.internal:9090
build --spawn_strategy=standalone
build --cxxopt="-std=c++17"
build --host_cxxopt="-std=c++17"
Are you able to reproduce this issue when building //:bazel-remote in this repository?
https://bazel.build/docs/remote-caching-debug suggests checking for warnings in the build logs, possibly with --verbose_failures to get more info.
And https://bazel.build/docs/remote-execution-caching-debug#caching-across-machines suggests using --execution_log_binary_file=/tmp/exec1.log though --execution_log_json_file=/tmp/exec1.json might be easier to examine. Could you try building a small target that you expect cache hits for with bazel 5.1.1 and 5.2.0 and compare the .json files to see if there are any obvious problems?
OK, I will do later
Closing for now due to lack of feedback.