Development: Use an internal Maven Central mirror to prevent dependency rate-limit errors in CI#12927
Conversation
…al mirror Add the TUM AET Reposilite (https://reposilite.aet.cit.tum.de/releases) as the preferred (first-listed) repository in all Gradle repository declarations to avoid Maven Central 429 rate-limit errors during build and server-test dependency resolution. mavenCentral() is kept as a fallback. Sites updated: settings.gradle (pluginManagement), build.gradle (project dependencies), and gradle/openapi.gradle (openapi-generator buildscript). Consolidate the GitHub Actions Gradle cache onto gradle/actions/setup-gradle in every server build/test workflow and drop the redundant cache: 'gradle' on setup-java (the two contend for ~/.gradle). setup-gradle prunes unused artifacts before saving, keeping cache entries lean to reduce eviction and the resulting dependency re-downloads. Adds Gradle caching to bean-instantiations.yml, which previously had none. Workflows updated: build.yml, test.yml, test-mysql.yml, codeql-analysis.yml, nightly-lti-interop.yml, bean-instantiations.yml. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
WalkthroughAdds a TUM-hosted reposilite Maven Central mirror ( ChangesReposilite Maven Mirror Configuration
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR improves CI reliability by preferring an internal TUM AET Reposilite proxy for Maven Central (to avoid upstream 429 rate limiting) and by consolidating Gradle dependency caching in GitHub Actions onto gradle/actions/setup-gradle@v6.
Changes:
- Added the internal Reposilite Maven Central mirror as the first Gradle repository for plugin resolution, build dependencies, and the OpenAPI buildscript.
- Replaced
actions/setup-java’s Gradle caching withgradle/actions/setup-gradle@v6across the affected CI workflows to avoid cache contention and keep caches leaner. - Added Gradle caching to workflows that previously lacked it (e.g., bean instantiation checks).
Reviewed changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
settings.gradle |
Prefer internal Reposilite mirror for Gradle plugin resolution, keeping Maven Central as fallback. |
gradle/openapi.gradle |
Prefer internal Reposilite mirror for OpenAPI buildscript dependencies. |
build.gradle |
Prefer internal Reposilite mirror for project dependency resolution. |
.github/workflows/test.yml |
Use setup-gradle@v6 as the sole Gradle caching mechanism for server test/style jobs. |
.github/workflows/test-mysql.yml |
Use setup-gradle@v6 as the sole Gradle caching mechanism for MySQL server tests. |
.github/workflows/nightly-lti-interop.yml |
Add setup-gradle@v6 caching to the nightly LTI interop job. |
.github/workflows/codeql-analysis.yml |
Add setup-gradle@v6 caching before the Gradle build used for CodeQL. |
.github/workflows/build.yml |
Remove setup-java Gradle cache usage and standardize on setup-gradle@v6. |
.github/workflows/bean-instantiations.yml |
Add setup-gradle@v6 caching to the bean instantiation workflow. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Resolve conflicts from develop's CI consolidation (#12745), which renamed the legacy workflows into the ci-*.yml umbrella structure: - build.yml / test.yml: deleted by develop (now ci-build.yml / ci-test.yml / ci-quality.yml). Accepted the deletions. - codeql-analysis.yml: develop turned it into a thin scheduled caller of the reusable ci-codeql.yml. Took develop's version. - ci-bean-instantiations.yml: kept develop's `java-version: ${{ env.java }}` refactor; replaced `cache: 'gradle'` with the SHA-pinned setup-gradle@v6. Carried this PR's caching consolidation onto the renamed successors so setup-gradle@v6 remains the sole Gradle dependency-cache mechanism across every server build/test workflow (ci-test, ci-quality, ci-codeql, ci-bean-instantiations), matching the form develop already adopted in ci-build.yml. Pinned the setup-gradle refs in test-mysql.yml and nightly-lti-interop.yml to the same SHA and updated stale "See build.yml" comments to ci-build.yml. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
End-to-End Test Results
❌ Failed Tests
Flakiness Scores for Failed Tests
Test Strategy: Running all tests (configuration or infrastructure changes detected) Overall: ❌ E2E tests failed 🔗 Workflow Run · 📊 Test Report |
Switch all gradle/actions/setup-gradle references from the SHA pin (50e97c2, v6.1.0) to the floating major tag @v6, keeping all 7 references consistent (including ci-build.yml). The wrapper-validation references are intentionally left SHA-pinned (separate, checksum- sensitive action, out of scope for this PR). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
FelixTJDietrich
left a comment
There was a problem hiding this comment.
Changes look good to me, Claude Opus 4.8 usually insists on pinning workflows to follow best practices. AFAIK you can also make this compatible with renovate / other dependency automations, if it is not already. But using a major version with trusted workflows should usually be fine, especially on GitHub runners.
Summary
Builds and server tests resolve their Gradle dependencies directly from Maven Central. Because many CI jobs run concurrently behind a shared egress IP, this regularly triggers HTTP
429 Too Many Requestsresponses from Maven Central — and due to Gradle's blacklist-on-error behavior, a single 429 fails the whole build. This PR routes dependency resolution through the internal TUM AET Reposilite mirror (which proxies Maven Central and has no per-IP rate limit) as the preferred repository, and unifies the GitHub Actions Gradle dependency cache ontosetup-gradle.Checklist
General
Motivation and Context
CI experienced repeated Maven Central
429 Too Many Requestserrors during dependency resolution. With many build/test jobs running concurrently behind a shared egress IP (the self-hostedaet-large-ubunturunners in particular), the aggregate request volume crosses Maven Central's per-IP rate limit. Gradle (4.3+) does not fall through to the next repository on an HTTP error — it blacklists the repository and fails the build — so a single 429 aborts the job.The TUM AET Reposilite instance proxies Maven Central from inside our own infrastructure and is not subject to a per-IP rate limit, so making it the preferred repository removes the root cause.
Description
Gradle — preferred mirror (with
mavenCentral()kept as a fallback), added first in all three repository declaration sites:settings.gradle→pluginManagement.repositories(plugin + root buildscript classpath resolution)build.gradle→ top-levelrepositories(project / server dependencies)gradle/openapi.gradle→buildscript.repositories(openapi-generator)The mirror (
https://reposilite.aet.cit.tum.de/releases) is listed first;mavenCentral()remains as a fallback, and the existing Spring-milestone / Gradle / Shibboleth repos andgradlePluginPortal()are kept for artifacts the mirror does not proxy.GitHub Actions — Gradle caching via
setup-gradle:gradle/actions/setup-gradle@v6as the sole Gradle dependency-cache mechanism, removing the redundantcache: 'gradle'fromsetup-javawhere present (the two would otherwise contend for~/.gradle).setup-gradleprunes unused artifacts before saving, keeping cache entries lean — this reduces GitHub Actions cache eviction (10 GB/repo, LRU) and the dependency re-downloads it causes.ci-bean-instantiations.yml, which previously had none (full fresh download on every run).setup-gradlereferences use the floating@v6tag and are kept consistent across:ci-build.yml,ci-test.yml,ci-quality.yml,ci-codeql.yml,ci-bean-instantiations.yml,nightly-lti-interop.yml,test-mysql.yml. (gradle/actions/wrapper-validationremains SHA-pinned.)Steps for Testing
This change is verified by CI itself rather than by manual feature testing:
ci-buildWAR build), confirm dependency/plugin artifacts are fetched fromreposilite.aet.cit.tum.derather thanrepo1.maven.org.Setup Gradlestep reports a Gradle cache restore/save in each migrated workflow.Testserver States
You can manage test servers using Helios. Check environment statuses in the environment list. To deploy to a test server, go to the CI/CD page, find your PR or branch, and trigger the deployment.
Review Progress
Code Review