Skip to content

Retry failing Windows builds on non-spot agent#11052

Merged
timja merged 6 commits intojenkinsci:masterfrom
lemeurherve:helpdesk4790-retry-windows-nonspot
Oct 7, 2025
Merged

Retry failing Windows builds on non-spot agent#11052
timja merged 6 commits intojenkinsci:masterfrom
lemeurherve:helpdesk4790-retry-windows-nonspot

Conversation

@lemeurherve
Copy link
Member

@lemeurherve lemeurherve commented Sep 9, 2025

This PR allows failing Windows builds to retry on a non-spot agent to avoid time loss due to spot instance reclaims, similar to what have been implemented in https://github.com/jenkinsci/acceptance-test-harness.

Note: only for Windows cf jenkins-infra/helpdesk#4790 (comment):

The maven-XX are Kubernetes (Linux) agents for which the concept of retrying to non spot makes no sense as we use Karpenter for managing nodes.

Refs:

Testing done

CI: https://ci.jenkins.io/job/Core/job/jenkins/job/PR-11052/7/

Initial spot agent for Windows:

image

Retry non-spot agent for Windows (after manually killing the Windows agent to trigger the retry):

image

Proposed changelog entries

  • N/A

Proposed changelog category

/label skip-changelog

Proposed upgrade guidelines

N/A

Submitter checklist

  • The Jira issue, if it exists, is well-described.
  • [-] The changelog entries and upgrade guidelines are appropriate for the audience affected by the change (users or developers, depending on the change) and are in the imperative mood (see examples). Fill in the Proposed upgrade guidelines section only if there are breaking changes or changes that may require extra steps from users during upgrade.
  • There is automated testing or an explanation as to why this change has no tests.
  • [-] New public classes, fields, and methods are annotated with @Restricted or have @since TODO Javadocs, as appropriate.
  • [-] New deprecations are annotated with @Deprecated(since = "TODO") or @Deprecated(forRemoval = true, since = "TODO"), if applicable.
  • [-] New or substantially changed JavaScript is not defined inline and does not call eval to ease future introduction of Content Security Policy (CSP) directives (see documentation).
  • [-] For dependency updates, there are links to external changelogs and, if possible, full differentials.
  • [-] For new APIs and extension points, there is a link to at least one consumer.

Desired reviewers

@MarkEWaite @dduportal

Before the changes are marked as ready-for-merge:

Maintainer checklist

  • There are at least two (2) approvals for the pull request and no outstanding requests for change.
  • Conversations in the pull request are over, or it is explicit that a reviewer is not blocking the change.
  • Changelog entries in the pull request title and/or Proposed changelog entries are accurate, human-readable, and in the imperative mood.
  • Proper changelog labels are set so that the changelog can be generated automatically.
  • If the change needs additional upgrade steps from users, the upgrade-guide-needed label is set and there is a Proposed upgrade guidelines section in the pull request title (see example).
  • If it would make sense to backport the change to LTS, a Jira issue must exist, be a Bug or Improvement, and be labeled as lts-candidate to be considered (see query).

@lemeurherve

This comment was marked as outdated.

@timja
Copy link
Member

timja commented Sep 9, 2025

Need someone to approve my Jenkinsfile change as I don't have any permission on this repo.

I'll revert 38cb634 and switch the PR as "Ready for review" after a first build on CI showing the expected non-spot agent usage.

There's no way to 'approve' the change, can you just replay it yourself with the contents from the PR?

@lemeurherve
Copy link
Member Author

can you just replay it yourself with the contents from the PR?

I currently don't have the permissions to do so.

Could someone replay https://ci.jenkins.io/job/Core/job/jenkins/job/PR-11052/1/ with the content from https://raw.githubusercontent.com/jenkinsci/jenkins/38cb6348383891c14a201d7e984072e271ee277a/Jenkinsfile please?

@timja
Copy link
Member

timja commented Sep 10, 2025

@NotMyFault ran it for you

@lemeurherve
Copy link
Member Author

/label skip-artifact-caching-proxy

Ref:

@lemeurherve lemeurherve marked this pull request as ready for review September 30, 2025 15:11
@lemeurherve
Copy link
Member Author

Confirmed the retry working as intended (spot then non-spot) with a replay and manually killing the first Windows agent: https://ci.jenkins.io/job/Core/job/jenkins/job/PR-11052/7/

lemeurherve and others added 2 commits September 30, 2025 18:57
Co-authored-by: Tim Jacomb <21194782+timja@users.noreply.github.com>
@lemeurherve
Copy link
Member Author

Linux failures related to #11132

@timja timja merged commit 4e76327 into jenkinsci:master Oct 7, 2025
17 checks passed
@lemeurherve lemeurherve deleted the helpdesk4790-retry-windows-nonspot branch October 7, 2025 08:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-artifact-caching-proxy skip-changelog Should not be shown in the changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants