assignUser commented on code in PR #41378:
URL: https://github.com/apache/arrow/pull/41378#discussion_r1581724489


##########
.github/workflows/python.yml:
##########
@@ -171,6 +171,23 @@ jobs:
         with:
           fetch-depth: 0
           submodules: recursive
+      - name: Install ccache

Review Comment:
   Hey! So the issue here is that `actions/cache` doesn't really work great for 
caching build caches like ccache as caches are immutable and if a primary key 
was hit it will not update the cache, leading to worse and worse hit rates.
   
   In this case you also used the same key for 2 different jobs, this will lead 
to a key clash and prevent one job from caching (looking at the results likely 
arm64 was cached -> 0% hit rate on amd64 as ccache is os/arch specific).
   
   A workaround is to create unique keys (e.g. `ccache-python-macos-<arch>-${{ 
github.sha }}` on each run and use 'restore-keys: ccache-python-macos-<arch>-' 
to still get a hit. This is quite wasteful and leads to frequent cache 
evictions as only 10GB/repo are allowed which we frequently go over (massivly)
   
![image](https://github.com/apache/arrow/assets/16141871/8cf7ccb4-8e41-4d60-a74f-d23bb3810d14)
   
   I created an [alternative](https://github.com/assignUser/stash) for this 
case but have to ask infra to allow-list it.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to