lockable-resources-plugin icon indicating copy to clipboard operation
lockable-resources-plugin copied to clipboard

Create function lockNode()

Open mPokornyETM opened this issue 2 years ago • 0 comments

What feature do you want to see added?

Most of our locks are used to lock the node for whole pipeline time. To explain. I have pipeline running on several nodes parallel. On every node we make setup. Synchronize it and then start the test. This must be running on all nodes at the same time. The problem is that setup on node 1 takes 2 minutes and on node 3 10 minutes. The node 1 will be free in jenkins for 8 minutes and there might be running other tasks which might broke my setup.

I think similar issue has many users.

Why new function? It will be great when the resources labels, description and name are equals to the node. In this case will be possible to create direct link in the lockable resources to computer/node.

The function shall has an optional parameter

String nodeName = env.NODE_NAME

So the groovy might locked currently used node per default or given node name.

I do not care about node labels as parameter. It will be complicated to handle it on both sides (user groovy and plugin java). With this limitation I am very fine.

Upstream changes

No response

mPokornyETM avatar Oct 17 '22 22:10 mPokornyETM