Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-21194

Distinguish between nodes manually taken offline as opposed to nodes taken offline by Jenkins after idle period

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      JENKINS-17305 gave the ability for nodes to be skipped in All Nodes for Label Factory if they are currently offline. This is fine if nodes are always kept online, but if nodes are only bought online and offline on demand by jenkins (as configured in the node configuration) then nodes get skipped even if they are perfectly able to service requests.

      It would be nice to have an option to only skip nodes that have been explicitly taken offline (e.g. via the "Mark this node temporarily offline" button).

        Attachments

          Issue Links

            Activity

            Hide
            domi Dominik Bartholdi added a comment -

            You'r right - I thought about this just yesterday
            Although this is something we should have a solution for, I don't like to glut the UI for the parameter definition with so many options.

            How about adding option on the node itself? e.g. "mark this node as usable for the nodelabel-plugin" - this would allow to keep the parameter configuration as easy as possible and allow to solve the issue.

            Show
            domi Dominik Bartholdi added a comment - You'r right - I thought about this just yesterday Although this is something we should have a solution for, I don't like to glut the UI for the parameter definition with so many options. How about adding option on the node itself? e.g. "mark this node as usable for the nodelabel-plugin" - this would allow to keep the parameter configuration as easy as possible and allow to solve the issue.
            Hide
            smorriso Stephen Morrison added a comment -

            I agree glut isn't good, but I'm not sure separating what is really a job specific option from the job configuration would be best UI experience either? Maybe the existing checkbox just needs to be changed to a pulldown box called something like "Node Eligibility"? Defaults to All Possible Nodes. Then has the options for Exclude All Offline Nodes and Exclude Only Temporarily Offline Nodes?

            Show
            smorriso Stephen Morrison added a comment - I agree glut isn't good, but I'm not sure separating what is really a job specific option from the job configuration would be best UI experience either? Maybe the existing checkbox just needs to be changed to a pulldown box called something like "Node Eligibility"? Defaults to All Possible Nodes. Then has the options for Exclude All Offline Nodes and Exclude Only Temporarily Offline Nodes?
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: imod
            Path:
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterValue.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/MultipleNodeDescribingParameterDefinition.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterValue.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodeUtil.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/AllNodeEligibility.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreOfflineNodeEligibility.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreTempOfflineNodeEligibility.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/NodeEligibility.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/parameterizedtrigger/NodeLabelBuildParameter.java
            src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/wrapper/TriggerNextBuildWrapper.java
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition/config.jelly
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition/config.properties
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition/help-nodeEligibility.html
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/Messages.properties
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition/config.jelly
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition/config.properties
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition/help-nodeEligibility.html
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/node/AllNodeEligibility/config.jelly
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreOfflineNodeEligibility/config.jelly
            src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreTempOfflineNodeEligibility/config.jelly
            src/test/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodelLabelNodePropertyTest.java
            src/test/java/org/jvnet/jenkins/plugins/nodelabelparameter/TriggerJobsTest.java
            http://jenkins-ci.org/commit/nodelabelparameter-plugin/c84f71466823c726420ab2f6af7dd989cf766bf7
            Log:
            [FIXED JENKINS-21194] add notion of NodeEligibility to differentiate between different offline modes of nodes

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: imod Path: src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterValue.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/MultipleNodeDescribingParameterDefinition.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterValue.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodeUtil.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/AllNodeEligibility.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreOfflineNodeEligibility.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreTempOfflineNodeEligibility.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/node/NodeEligibility.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/parameterizedtrigger/NodeLabelBuildParameter.java src/main/java/org/jvnet/jenkins/plugins/nodelabelparameter/wrapper/TriggerNextBuildWrapper.java src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition/config.jelly src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition/config.properties src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/LabelParameterDefinition/help-nodeEligibility.html src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/Messages.properties src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition/config.jelly src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition/config.properties src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/NodeParameterDefinition/help-nodeEligibility.html src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/node/AllNodeEligibility/config.jelly src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreOfflineNodeEligibility/config.jelly src/main/resources/org/jvnet/jenkins/plugins/nodelabelparameter/node/IgnoreTempOfflineNodeEligibility/config.jelly src/test/java/org/jvnet/jenkins/plugins/nodelabelparameter/NodelLabelNodePropertyTest.java src/test/java/org/jvnet/jenkins/plugins/nodelabelparameter/TriggerJobsTest.java http://jenkins-ci.org/commit/nodelabelparameter-plugin/c84f71466823c726420ab2f6af7dd989cf766bf7 Log: [FIXED JENKINS-21194] add notion of NodeEligibility to differentiate between different offline modes of nodes
            Hide
            domi Dominik Bartholdi added a comment -
            Show
            domi Dominik Bartholdi added a comment - I just released the 1.5.0-beta version with this, feedback very welcome: https://wiki.jenkins-ci.org/display/JENKINS/NodeLabel+Parameter+Plugin#NodeLabelParameterPlugin-1.5.0beta%2816.Jan2014%29
            Hide
            smorriso Stephen Morrison added a comment -

            I don't think this is working as expected for me. I have a JOB1, which kicks off multiple concurrent JOB2s using the node label factory. I changed the JOB2 node parameter to ignore temp offline nodes, and then ran JOB1. I have 3 nodes, 2 of which only come online by demand, and one which I have marked as being temporarily offline. It looks like a job for the temp offline node is still generated, so it sits there in the queue forever. I think the node label factory needs to not generate the job in the first place?

            Also, If I click "Ignore Offline Nodes" for the node label config, and run the test again, a single job is still generated that sits forever in the queue despite none of the nodes being online. A message is printed in JOB1's output "No online node for label [MYLABEL] found, triggering with original label." Not sure why that happens.

            Finally, I don't know if this is related, but if I kill the jobs waiting in the queue, JOB1 sits there forever waiting for the completion of the now non-existant jobs.

            Show
            smorriso Stephen Morrison added a comment - I don't think this is working as expected for me. I have a JOB1, which kicks off multiple concurrent JOB2s using the node label factory. I changed the JOB2 node parameter to ignore temp offline nodes, and then ran JOB1. I have 3 nodes, 2 of which only come online by demand, and one which I have marked as being temporarily offline. It looks like a job for the temp offline node is still generated, so it sits there in the queue forever. I think the node label factory needs to not generate the job in the first place? Also, If I click "Ignore Offline Nodes" for the node label config, and run the test again, a single job is still generated that sits forever in the queue despite none of the nodes being online. A message is printed in JOB1's output "No online node for label [MYLABEL] found, triggering with original label." Not sure why that happens. Finally, I don't know if this is related, but if I kill the jobs waiting in the queue, JOB1 sits there forever waiting for the completion of the now non-existant jobs.

              People

              • Assignee:
                domi Dominik Bartholdi
                Reporter:
                smorriso Stephen Morrison
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: