lhotari opened a new pull request, #25439:
URL: https://github.com/apache/pulsar/pull/25439
### Motivation
When PRs are submitted from forks, the `DEVELOCITY_ACCESS_KEY` secret is not
available, so Gradle build scans are not published. This change introduces a
fallback to public Gradle build scans using the terms-of-service agreement
flow, ensuring build scan links are available for all PR builds regardless of
secret access.
### Modifications
- Created a new composite action `.github/actions/setup-gradle/action.yml`
that centralizes Gradle setup logic:
- When `develocity-access-key` is provided and `build-scan-publish` is
`true`: uses Develocity injection with the Apache Develocity server
- When the key is not available: falls back to public build scan
publishing with terms-of-service acceptance
- Accepts passthrough inputs: `cache-read-only`, `add-job-summary`,
`build-scan-publish`
- Sets `cache-read-only` default based on whether the build is a PR or
non-default branch
- Updated all 4 workflow files (12 total usages) to use the new composite
action:
- `pulsar-ci.yaml` (9 usages)
- `pulsar-ci-flaky.yaml` (1 usage)
- `codeql.yaml` (1 usage)
- `ci-gradle-cache-update.yaml` (1 usage)
- Removed `DEVELOCITY_ACCESS_KEY` environment variable declarations from
job-level env blocks (now passed directly as action input from secrets)
### Verifying this change
- [ ] Make sure that the change passes the CI checks.
This change is already covered by existing tests — CI workflow runs will
validate that Gradle setup works correctly with and without the Develocity
access key.
### Does this pull request potentially affect one of the following parts:
- [ ] Dependencies (add or upgrade a dependency)
- [ ] The public API
- [ ] The schema
- [ ] The default values of configurations
- [ ] The threading model
- [ ] The binary protocol
- [ ] The REST endpoints
- [ ] The admin CLI options
- [ ] The metrics
- [x] Anything that affects deployment
### Documentation
- [x] `doc-not-needed`
--
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]