-
Improvement
-
Resolution: Done
-
Minor
-
None
We use ForemanComputer.terminateForemanComputer() for all necessary operations to terminate a Foreman node. Currently, it is utilized and called only after taskCompleted and taskCompletedWithProblems signals. Currently only ForemanComputer.eagerlyReturnNodeLater() calls (even async.) ForemanComputer.terminateForemanComputer() and it is a public part of the API and thus it can be called anytime.
In a termination process we should change the state of the node to PendingDelete, but don't terminate it immediately. There should be an AsyncPeriodicWork worker which collects all PendingDelete Foreman nodes and terminate them only when they are free (-> Computer.isIdle() == true).
- is related to
-
JENKINS-39148 Implement a cleanup worker
- Resolved