-
Bug
-
Resolution: Fixed
-
Major
-
None
I've detected the situation when the network between Jenkins master and Foreman instance was interrupted for awhile. If during this interruption Jenkins master tries to dispose a node from Foreman cloud provider, it can't be obviously recorded on Foreman side. Unfortunately on Foreman side, the attribute RESERVED had to be corrected manually later, otherwise it is blocked forever.
I'd prefer if the plugin on regular basis check which nodes are reserved in reality on the master with the response from the Foreman instance. If there is some leaked node, it should be moved back to the pool immediately.
There can be many reasons why the disposing of a node can fail during decommissioning procedure and so the list of leaked nodes can be a serious issue in the production environment. In addition, nobody can detect that situation easily.
Update: I can imagine that the same situation can happen if Jenkins master restart is requested when a node is busy with a build execution and it isn't possible to dispose the node on Foreman side (network issue, Foreman instance down etc.).