jenkinsci / jenkinsci/workflow-basic-steps-plugin

[JENKINS-56964] Expose timeout grace period as configurable

Offen
#487 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
component:workflow-basic-steps-plugin imported-jira-issue pipeline priority:minor resolution:unresolved
Vorherrschende Sprache
Java
Sterne
73
Forks
129
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

As a job author, I would like the pipeline timeout GRACE_PERIOD exposed as a configurable option so that I can allow for teardown steps that take longer than 5s or 60s.

 

I use the timeout option on a stage, but during the normal course of operations if that timeout engages items in an always post step only get that grace period to complete.  For processes with extensive cleanup, you see `Body did not finish within grace period; terminating with extreme prejudice` and it force-kills what's running.  This can leave some cleanup process incomplete.  I'd like to see an option in the timeout step to specify how long that grace period ought to be.

 

 Relevant code link: https://github.com/jenkinsci/workflow-basic-steps-plugin/blob/3ecc7bbd91182e330a23a9e661ae1cdfa2d2b55e/src/main/java/org/jenkinsci/plugins/workflow/steps/TimeoutStepExecution.java#L41

---
Originally reported by jgray599, imported from: Expose timeout grace period as configurable


  • status: Open
  • priority: Minor
  • component(s): workflow-basic-steps-plugin
  • label(s): configuration, pipeline, plugin
  • resolution: Unresolved
  • votes: 5
  • watchers: 8
  • imported: 20251215-220547

Raw content of original issue

As a job author, I would like the pipeline timeout GRACE_PERIOD exposed as a configurable option so that I can allow for teardown steps that take longer than 5s or 60s.

 

I use the timeout option on a stage, but during the normal course of operations if that timeout engages items in an always post step only get that grace period to complete.  For processes with extensive cleanup, you see `Body did not finish within grace period; terminating with extreme prejudice` and it force-kills what's running.  This can leave some cleanup process incomplete.  I'd like to see an option in the timeout step to specify how long that grace period ought to be.

 

 Relevant code link: https://github.com/jenkinsci/workflow-basic-steps-plugin/blob/3ecc7bbd91182e330a23a9e661ae1cdfa2d2b55e/src/main/java/org/jenkinsci/plugins/workflow/steps/TimeoutStepExecution.java#L41

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginne mit src/main/java/org/jenkinsci/plugins/workflow/steps/TimeoutStepExecution.java beim verlinkten Code für die Grace-Period. Verfolge, wie der Timeout-Schritt seine Grace-Period behandelt, und ermittle, wo ein vom Job-Autor bereitgestellter Wert akzeptiert und angewendet würde. Als erledigt gilt die Aufgabe, wenn die Timeout-Option eine konfigurierbare Grace-Period offenlegt und die Bereinigung für die ausgewählte Dauer ausgeführt werden darf.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
java
Bereich
ci-cd
Issue-Typ
Feature
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
38/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.