Skip to content

Conversation

@dliappis
Copy link
Contributor

Backport PR #17063 to 8.17 branch, original message:


Release notes

[rn:skip]

What does this PR do?

This commit simplifies the DRA process in Logstash by removing the need to maintain a separate file for the active branches, and instead rely on a centrally maintained file containing source of truth.
While at it, we refactor/simplify the creation of an array with the versions in .buildkite/scripts/snyk/resolve_stack_version.sh.

Why is it important/What is the impact to the user?

Removes a manual step required when new branches get cut.

How to test this PR locally

$ PIPELINES_TO_TRIGGER="test-pipeline" .buildkite/scripts/common/trigger-pipeline-generate-steps.sh 
--- Printing generated steps
steps:
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / 7.17"
    build:
      branch: "7.17"
      message: ":testexecute: Scheduled build for 7.17"
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / 8.x"
    build:
      branch: "8.x"
      message: ":testexecute: Scheduled build for 8.x"
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / 8.16"
    build:
      branch: "8.16"
      message: ":testexecute: Scheduled build for 8.16"
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / 8.17"
    build:
      branch: "8.17"
      message: ":testexecute: Scheduled build for 8.17"
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / 8.18"
    build:
      branch: "8.18"
      message: ":testexecute: Scheduled build for 8.18"
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / 9.0"
    build:
      branch: "9.0"
      message: ":testexecute: Scheduled build for 9.0"
  - trigger: test-pipeline
    label: ":testexecute: Triggering test-pipeline / main"
    build:
      branch: "main"
      message: ":testexecute: Scheduled build for main"
$ .buildkite/scripts/snyk/resolve_stack_version.sh 
Fetching versions from https://storage.googleapis.com/artifacts-api/snapshots/branches.json
7.17 8.x 8.16 8.17 8.18 9.0 main

Test in buildkite by triggering the scheduled pipeline: https://buildkite.com/elastic/logstash-pipeline-scheduler/builds/568#0194fa84-0a66-42d7-8806-d4610ce2abce/64-100

@dliappis dliappis requested a review from mashhurs February 12, 2025 16:32
@dliappis dliappis self-assigned this Feb 12, 2025
@dliappis
Copy link
Contributor Author

@mashhur same request as in #17073 (comment); compared to main and 9.0, in this branch the resolve_stack_version.sh script doesn't consult ci/branches.json so I left it as is.

@elastic-sonarqube
Copy link

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

cc @dliappis

Copy link
Contributor

@mashhurs mashhurs left a comment

Choose a reason for hiding this comment

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

🎉 LGTM!

@mashhurs mashhurs merged commit 6398d96 into elastic:8.17 Feb 12, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants