Compilation results
Share build results through GOCACHEPROG.
Connect the Go build cache to shared storage. Fresh runners and developer machines can reuse results when the Go command's cache rules allow it.
.boringcache.toml
workspace = "my-org/app" [adapters.go] tag = "go-cache" command = ["go", "test", "./..."]
boringcache go
permissions: contents: read id-token: write steps: - uses: boringcache/one@1781572d7b3ec5aef652f8ba479b981439b2776b # v1.48.2 with: mode: go trust-policy: auto - run: go test ./...
steps: - label: Build command: > boringcache ci run --oidc-provider buildkite -- boringcache go
build: timeout: 1h id_tokens: BORINGCACHE_OIDC_TOKEN: aud: urn:boringcache:workload script: - boringcache ci run --oidc-provider gitlab -- boringcache go
Share build results through GOCACHEPROG.
Reuse completed tests when Go considers them cacheable.
Keep the commands that already build and test your project.
Downloaded module source and compiled build results are different caches. This integration shares build and test results, not merely the packages needed to produce them.
A warm module cache avoids downloading dependencies. It does not supply their compiled results. BoringCache connects Go's GOCACHEPROG interface to shared build and test results, so compatible CI and local builds can reuse them.
Keep your Go build and test commands. Go computes the cache keys and decides whether a result is reusable; BoringCache handles the shared cache connection and reports its reads and misses.
Run the same commit with the same Go version and build options on a fresh runner. Check the recorded build-cache hits and total time, including transfers. Test output can show (cached) when Go reuses a successful package test result.
Test reuse requires package-list mode, such as go test ./..., and cacheable flags. Changed inputs or -count=1 can make tests run even when compilation hits the cache.
Inspect build-cache reads, misses, transfers, and storage for each run.
Explore the workspace →BoringCache · GitHub runner · 4 vCPU
88.2% of 35,305 lookups over 18 builds
Build times grouped by runner, with cold and warm builds shown separately.
Go
Benchmark →Static site generator written in Go.
Average restore, build and save · lower is better
4 vCPU · 16 GB · Ubuntu 24.04 x86-64
Builds of one commit can land on different CPU models. These ratios use only the build pairs where both caches ran on the same model; above 1.00× means BoringCache's total time over those pairs was lower.
Each table is one workflow run with one build per cache. A row marked Different CPU ran on another CPU model than BoringCache at the same level, so part of its time difference can come from the hardware.
| Cache | Cold | Warm | CPU |
|---|---|---|---|
| BoringCache Build cache | 89.2 s | 20.0 s | Cold: AMD EPYC 9V74 · Warm: Intel Xeon Platinum 8573C |
| Depot Cache | 1 min 52 s | 81.7 s | Cold: AMD EPYC 9V45 · Warm: Intel Xeon Platinum 8370C Different CPU |
| GHA Cache Local cache directory restored and saved by actions/cache | 88.3 s | 6.3 s | Cold: AMD EPYC 7763 · Warm: AMD EPYC 9V45 Different CPU |
BoringCache · GitHub runner · 4 vCPU
88.2% of 35,305 lookups over 18 builds
Give consumers restore access and publishers a separate permission. Connect supported CI through OIDC or use scoped credentials.
Connect your CI →Separate readers and publishers
Send me a repo or a workflow and I'll take a look. I've spent more than a year on slow Docker, Cargo and Bazel builds in CI.
Install the CLI. Run onboarding to connect your repository and configure your cache.
30-day trial. No credit card required.
curl -sSL https://install.boringcache.com/install.sh | sh
boringcache onboard
boringcache go
We use cookies to understand how people use BoringCache. Privacy policy