Skip to content

SONARJAVA-6247 Use orchestrator-cache in autoscan tests#5563

Merged
tomasz-tylenda-sonarsource merged 2 commits intomasterfrom
tt/autoscan-orchestrator-cache
Apr 10, 2026
Merged

SONARJAVA-6247 Use orchestrator-cache in autoscan tests#5563
tomasz-tylenda-sonarsource merged 2 commits intomasterfrom
tt/autoscan-orchestrator-cache

Conversation

@tomasz-tylenda-sonarsource
Copy link
Copy Markdown
Contributor

@tomasz-tylenda-sonarsource tomasz-tylenda-sonarsource commented Apr 10, 2026

@hashicorp-vault-sonar-prod hashicorp-vault-sonar-prod bot changed the title Use orchestrator-cache in autoscan tests SONARJAVA-6247 Use orchestrator-cache in autoscan tests Apr 10, 2026
@hashicorp-vault-sonar-prod
Copy link
Copy Markdown
Contributor

hashicorp-vault-sonar-prod bot commented Apr 10, 2026

SONARJAVA-6247

@sonar-review-alpha
Copy link
Copy Markdown

sonar-review-alpha bot commented Apr 10, 2026

Summary

Adds orchestrator-cache to the autoscan CI workflow job, bringing it in line with the caching strategy already applied to plugin and ruling QA jobs. This avoids redundant downloads of the SonarQube artifact by reusing versions cached by other jobs in the same workflow run. Changes the SonarQube version from a hardcoded parameter to an environment variable that coordinates with the cache action.

What reviewers should know

What changed:

  • New orchestrator-cache action step inserted before Run autoscan tests (lines 332–335)
  • Added SQ_VERSION environment variable to define the SonarQube version
  • Maven parameter changed from -Dsonar.runtimeVersion=LATEST_RELEASE to -Dsonar.runtimeVersion="$SQ_VERSION" to use the env var

For reviewers:
The diff is straightforward — the autoscan job now uses the same caching mechanism as plugin and ruling QA (via the reusable ./.github/actions/orchestrator-cache action). No changes to test logic or other workflow steps. The author confirmed in testing that the cached artifact is properly reused across jobs.


  • Generate Walkthrough
  • Generate Diagram

🗣️ Give feedback

Copy link
Copy Markdown

@sonar-review-alpha sonar-review-alpha bot left a comment

Choose a reason for hiding this comment

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

LGTM! ✅

Clean, focused change that brings the autoscan job in line with the caching pattern already used by ruling and plugin-qa. The SQ_VERSION env var is wired correctly through both the orchestrator-cache action and the Maven -Dsonar.runtimeVersion property, and the cache action handles LATEST_RELEASE as expected.

🗣️ Give feedback

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM but I think it would be nicer if we moved the starting double a bit further

Co-authored-by: Dorian Burihabwa <75226315+dorian-burihabwa-sonarsource@users.noreply.github.com>
@tomasz-tylenda-sonarsource tomasz-tylenda-sonarsource enabled auto-merge (squash) April 10, 2026 15:31
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for the change!

@sonarqube-next
Copy link
Copy Markdown

@tomasz-tylenda-sonarsource tomasz-tylenda-sonarsource merged commit 68a696a into master Apr 10, 2026
14 of 15 checks passed
@tomasz-tylenda-sonarsource tomasz-tylenda-sonarsource deleted the tt/autoscan-orchestrator-cache branch April 10, 2026 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants