Skip to content

GH-50283: [CI][Ruby] Switch caching to apache/infrastructure-actions/stash#50284

Merged
kou merged 4 commits into
apache:mainfrom
pitrou:gh50283-ruby-caching
Jul 1, 2026
Merged

GH-50283: [CI][Ruby] Switch caching to apache/infrastructure-actions/stash#50284
kou merged 4 commits into
apache:mainfrom
pitrou:gh50283-ruby-caching

Conversation

@pitrou

@pitrou pitrou commented Jun 29, 2026

Copy link
Copy Markdown
Member

Rationale for this change

apache/infrastructure-actions/stash benefits from much greater size limits than actions/cache, so our compilation cache stands a greater chance of not being evicted by the next time a build runs.

Are these changes tested?

By the affected CI jobs.

Are there any user-facing changes?

No.

@pitrou pitrou changed the title GH-50283: [CI][Ruby] Switch caching to apache/infrastructure-actions/… GH-50283: [CI][Ruby] Switch caching to apache/infrastructure-actions/stash Jun 29, 2026
@github-actions github-actions Bot added the awaiting review Awaiting review label Jun 29, 2026
@pitrou pitrou force-pushed the gh50283-ruby-caching branch 9 times, most recently from f216386 to 94e17b2 Compare June 30, 2026 15:58
@pitrou

pitrou commented Jun 30, 2026

Copy link
Copy Markdown
Member Author

I don't understand why I keep getting permission denied errors when storing the cache on the Ubuntu job:
https://github.com/apache/arrow/actions/runs/28457975587/job/84337896893?pr=50284#step:7:79

Uploading artifact: ruby-ubuntu-22.04-50284_merge.zip
Beginning upload of artifact content to blob storage
Error: An error has occurred while creating the zip file for upload
Error: EACCES: permission denied, open '/home/runner/work/arrow/arrow/.docker/ubuntu-ccache/0/0/stats'
file:///home/runner/work/_actions/actions/upload-artifact/043fb46d1a93c77aae656e7c1c64a875d1fc6a0a/dist/upload/index.js:124113
    throw new Error('An error has occurred during zip creation for the artifact');
    ^

This is the only job where it happens and it doesn't seem fundamentally different from other Docker-based jobs already using the stash action. @rok @raulcd @kou Do you have a clue perhaps?

@pitrou

pitrou commented Jun 30, 2026

Copy link
Copy Markdown
Member Author

Hmm, it seems that not all ccache files are created with the same umask for some reason...

# ls -la /ccache/0/1/
total 2480
drwxr-xr-x  2 root root    4096 Jun 30 16:20 .
drwxr-xr-x 18 root root    4096 Jun 30 16:20 ..
-rw-r--r--  1 root root  246008 Jun 30 14:58 09e4sdh7thcmo3289afb1c4du23g0qsR
-rw-r--r--  1 root root   13819 Jun 30 14:59 1f7t0m6l1ej2irha5ea67s09k6n5qjqM
-rw-r-----  1 root root   19483 Jun 30 15:02 35u65l3sj167luhkfrt4u25vh5r3eiqM
-rw-r--r--  1 root root  125787 Jun 30 14:58 74p5m9fh7j466onmthei1r76gq1bltuR
-rw-r--r--  1 root root     151 Jun 30 14:58 86cg13bqae330mmc9qe0vbqtktm4lbcM
-rw-r--r--  1 root root     495 Jun 30 16:20 88q52lrs72cf63ovc6rji9b0oknuut8R
-rw-r--r--  1 root root  315453 Jun 30 15:00 8dt77dberl8imne0gdmtudj2s5noevsR
-rw-r--r--  1 root root 1442226 Jun 30 15:00 b7ghr6cf0ov78d1epq5lehavh4teblaR
-rw-r--r--  1 root root   13006 Jun 30 14:58 b7pofm1dl56tqivhlrl4adeod4c54seM
-rw-r--r--  1 root root  291495 Jun 30 14:58 d00htmb3jlhrl6qquaf4r48c35l3mioR
-rw-r--r--  1 root root    9776 Jun 30 14:58 f5qc8c6oi0ifg929tin83kphg7dl0h0M
-rw-r--r--  1 root root   14436 Jun 30 14:58 fait9qjho0d8q1u23q6pe563rem16vaM
-rw-r--r--  1 root root      84 Jun 30 16:20 stats

@pitrou pitrou force-pushed the gh50283-ruby-caching branch from 0aa9e99 to ce813a3 Compare June 30, 2026 16:50
@pitrou

pitrou commented Jun 30, 2026

Copy link
Copy Markdown
Member Author

Note that on Windows builds (both MinGW and MSVC), most files are not cached because the build system passes compiler options that ccache does not support.

On MinGW:

Cacheable calls:               1332 / 3188 (41.78%)
  Hits:                        1096 / 1332 (82.28%)
    Direct:                    1066 / 1096 (97.26%)
    Preprocessed:                30 / 1096 ( 2.74%)
  Misses:                       236 / 1332 (17.72%)
Uncacheable calls:             1856 / 3188 (58.22%)
  Called for linking:            42 / 1856 ( 2.26%)
  Called for preprocessing:      42 / 1856 ( 2.26%)
  No input file:                252 / 1856 (13.58%)
  Unsupported compiler option: 1520 / 1856 (81.90%)

On MSVC:

  Hits:                         257 /  342 (75.15 %)
    Direct:                     254 /  342 (74.27 %)
    Preprocessed:                 3 /   88 (3.41 %)
  Misses:                        85
    Direct:                      88
    Preprocessed:                85
  Uncacheable:                 1978

@pitrou

pitrou commented Jun 30, 2026

Copy link
Copy Markdown
Member Author

This is now ready for review @kou

@kou kou left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@kou kou merged commit f349102 into apache:main Jul 1, 2026
60 of 61 checks passed
@kou kou removed the awaiting review Awaiting review label Jul 1, 2026
@github-actions github-actions Bot added the awaiting merge Awaiting merge label Jul 1, 2026
@pitrou pitrou deleted the gh50283-ruby-caching branch July 1, 2026 07:51
@conbench-apache-arrow

Copy link
Copy Markdown

After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit f349102.

There were no benchmark performance regressions. 🎉

The full Conbench report has more details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting merge Awaiting merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants