[JIRA] (JENKINS-37781) Pipeline Config: ability to skip whole pipeline or stages based on boolean condition

236 views
Skip to first unread message

andrew.bayer@gmail.com (JIRA)

unread,
Sep 21, 2016, 12:35:01 PM9/21/16
to jenkinsc...@googlegroups.com
Andrew Bayer updated an issue
 
Jenkins / Story JENKINS-37781
Pipeline Config: ability to skip whole pipeline or stages based on boolean condition
Change By: Andrew Bayer
Summary: Pipeline Config: ability to skip whole pipeline or stages based on branch boolean condition
A common enough pattern is to skip either a whole pipeline or a stage based on the branch of execution. This is pretty common in deployment focussed focused pipelines, and would be a strong reason to break out of config and that would be a shame.

It would be nice if this was somewhat first class in pipeline config. Some may be able to be done with a block scoped step... but not clear if all can be.

In scope:

* on
A general way of saying "if this boolean condition is false, skip this stage" would be the way to go - branch declaration as a peer with postBuild or stages
* same on-
branch pattern per stage matching would be one particular use of this, but the right thing to do is go generic.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

anton@piatek.co.uk (JIRA)

unread,
Sep 28, 2016, 12:10:02 PM9/28/16
to jenkinsc...@googlegroups.com
Anton Piatek commented on Story JENKINS-37781
 
Re: Pipeline Config: ability to skip whole pipeline or stages based on boolean condition

It is easy enough to skip a stage with an if block, but then the view of that pipeline gets cleared every time the number of stages changes. It would be nice to report a stage as N/A or skipped, and perhaps have it coloured white to show clearly that it wasn't actually run during this particular build.

andrew.bayer@gmail.com (JIRA)

unread,
Oct 24, 2016, 6:13:01 AM10/24/16
to jenkinsc...@googlegroups.com

pwolf@cloudbees.com (JIRA)

unread,
Oct 24, 2016, 11:40:01 AM10/24/16
to jenkinsc...@googlegroups.com

andrew.bayer@gmail.com (JIRA)

unread,
Oct 24, 2016, 11:42:02 AM10/24/16
to jenkinsc...@googlegroups.com

Well, we'd still "run" the stage - we just wouldn't actually do anything in it, like we now do with stages after a failed stage, so that we preserve the execution plan regardless of status.

pwolf@cloudbees.com (JIRA)

unread,
Oct 24, 2016, 11:45:03 AM10/24/16
to jenkinsc...@googlegroups.com

As pointed out above by Anton, showing it as "Successful", "Failed", or "Unstable" wouldn't be entirely accurate.

Also, would this skip the "post" actions entirely as well?

andrew.bayer@gmail.com (JIRA)

unread,
Oct 24, 2016, 11:48:02 AM10/24/16
to jenkinsc...@googlegroups.com

As of now, there's no way to set a stage to a specific status, so it'll just be whatever the overall status is.

I'd say yes, we would skip post-stage actions as well.

jdumay@cloudbees.com (JIRA)

unread,
Oct 24, 2016, 8:16:02 PM10/24/16
to jenkinsc...@googlegroups.com
James Dumay edited a comment on Story JENKINS-37781
[~hrmpw] [~abayer] what if "skipped" stages were not displayed at all? However, if we did want skipped stages to show we should introduce a skipped state.

jdumay@cloudbees.com (JIRA)

unread,
Oct 24, 2016, 8:16:02 PM10/24/16
to jenkinsc...@googlegroups.com

scm_issue_link@java.net (JIRA)

unread,
Oct 26, 2016, 5:06:01 AM10/26/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTScriptBlock.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStage.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTWhen.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidator.java
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/JSONParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidatorImpl.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java
pipeline-model-definition/src/test/resources/simpleWhen.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/dfab9e247559bf258b0aa35e4160cc91b45e0abc
Log:
JENKINS-37781 Adding Stage.when to specify if a stage should run or not

scm_issue_link@java.net (JIRA)

unread,
Oct 26, 2016, 5:36:01 AM10/26/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java
pipeline-model-definition/src/test/resources/simpleWhen.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/9676206a2bc0ec8b93624ae8fc7cf907e8273b4e
Log:
JENKINS-37781 fixing the compilation of the compiler

and cleaned up some debug echo

scm_issue_link@java.net (JIRA)

unread,
Oct 26, 2016, 11:11:05 AM10/26/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTWhen.java
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidatorImpl.groovy
pipeline-model-definition/src/main/resources/ast-schema.json
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java
pipeline-model-definition/src/test/resources/simpleWhen.groovy
pipeline-model-definition/src/test/resources/when/simpleWhen.groovy
pipeline-model-definition/src/test/resources/when/whenEmpty.groovy
pipeline-model-definition/src/test/resources/when/whenException.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/819bbdfeb1ba3a6351baf142a558bb5ccdc599af
Log:
JENKINS-37781 More tests

Fixed some issues those tests revealed.
Also fixed a bug where the last line of a script or when closure wasn't parsed

scm_issue_link@java.net (JIRA)

unread,
Oct 27, 2016, 5:55:02 AM10/27/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidatorImpl.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/eddf70b8c5747b8c516752e8c033891b6cfc9daa
Log:
JENKINS-37781 Fixed empty when validation

stanislav.tyurikov@gmail.com (JIRA)

unread,
Oct 31, 2016, 11:36:01 AM10/31/16
to jenkinsc...@googlegroups.com

It would be awesome to have such functionally!
From my point of view having DSL like: stage(name: "My Stage", skip: true) would be good enough. If a stage is skipped make it gray on the board.

scm_issue_link@java.net (JIRA)

unread,
Nov 3, 2016, 11:05:03 AM11/3/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:
pipeline-model-api/pom.xml
pipeline-model-declarative-agent/pom.xml
pipeline-model-definition/pom.xml
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
pom.xml
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/b8463d5ab69d6ae10871d80892150fa04d323d82
Log:
Merge branch 'master' of github.com:jenkinsci/pipeline-model-definition-plugin into JENKINS-37781

scm_issue_link@java.net (JIRA)

unread,
Nov 3, 2016, 11:05:04 AM11/3/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/AbstractModelASTCodeBlock.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTScriptBlock.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTWhen.java
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/efe93beefe8be357adc0cab0e2d319a05502fcda
Log:
JENKINS-37781 Split ModelASTScriptBlock and ModelASTWhen

Into having one common ancestor instead of when extending script

Compare: https://github.com/jenkinsci/pipeline-model-definition-plugin/compare/d65d3dc3117f...efe93beefe8b

scm_issue_link@java.net (JIRA)

unread,
Nov 8, 2016, 9:28:04 AM11/8/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

pipeline-model-declarative-agent/pom.xml
pipeline-model-declarative-agent/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/DeclarativeAgent.java
pipeline-model-declarative-agent/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/DeclarativeAgentDescriptor.java
pipeline-model-definition/pom.xml
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/Utils.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/AbstractBuildConditionResponder.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Agent.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/JobProperties.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/MappedClosure.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/NestedModel.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Parameters.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Root.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stages.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/StepsBlock.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Tools.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Triggers.groovy
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ModelStepLoader.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/DockerPipeline.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/DockerPipelineFromDockerfile.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/Label.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/model/BuildCondition.java
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/DockerPipelineFromDockerfileScript.groovy
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AbstractModelDefTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AgentTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/ValidatorTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/LabelAndOtherFieldAgent.java
pipeline-model-definition/src/test/resources/fromAlternateDockerfile.groovy
pipeline-model-definition/src/test/resources/fromDockerfile.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/8c766601a1394bc2f5652c7a5fd8c6497563f265
Log:
Merge remote-tracking branch 'origin/master' into JENKINS-37781

Conflicts:
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy

Compare: https://github.com/jenkinsci/pipeline-model-definition-plugin/compare/efe93beefe8b...8c766601a139

scm_issue_link@java.net (JIRA)

unread,
Nov 8, 2016, 10:10:03 AM11/8/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

README.md
SYNTAX.md
pipeline-model-api/pom.xml
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTPipelineDef.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStage.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStep.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTWrapper.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTWrappers.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidator.java
pipeline-model-declarative-agent/pom.xml
pipeline-model-declarative-agent/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/DeclarativeAgent.java
pipeline-model-declarative-agent/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/DeclarativeAgentDescriptor.java
pipeline-model-declarative-agent/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/DeclarativeAgentScript.java
pipeline-model-definition/pom.xml
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Agent.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Root.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Wrappers.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/WrappersToMap.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/JSONParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidatorImpl.groovy
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/Any.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/DockerPipeline.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/Label.java
pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/None.java
pipeline-model-definition/src/main/resources/ast-schema.json
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ClosureModelTranslator.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/WrappersToMapTranslator.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/DockerPipelineScript.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/LabelScript.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/NoneScript.groovy
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AbstractModelDefTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AgentTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/EnvironmentTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/ToolsTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/ValidatorTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WrappersTest.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/LabelAndOtherFieldAgent.java
pipeline-model-definition/src/test/resources/agentAnyInStage.groovy
pipeline-model-definition/src/test/resources/agentTypeOrdering.groovy
pipeline-model-definition/src/test/resources/environmentInStage.groovy
pipeline-model-definition/src/test/resources/errors/agentMissingRequiredParam.groovy
pipeline-model-definition/src/test/resources/errors/agentUnknownParamForType.groovy
pipeline-model-definition/src/test/resources/errors/invalidWrapperType.groovy
pipeline-model-definition/src/test/resources/errors/unknownAgentType.groovy
pipeline-model-definition/src/test/resources/errors/unknownBareAgentType.groovy
pipeline-model-definition/src/test/resources/json/agentTypeOrdering.json
pipeline-model-definition/src/test/resources/json/environmentInStage.json
pipeline-model-definition/src/test/resources/json/errors/agentMissingRequiredParam.json
pipeline-model-definition/src/test/resources/json/errors/agentUnknownParamForType.json
pipeline-model-definition/src/test/resources/json/errors/invalidWrapperType.json
pipeline-model-definition/src/test/resources/json/errors/unknownAgentType.json
pipeline-model-definition/src/test/resources/json/errors/unknownBareAgentType.json
pipeline-model-definition/src/test/resources/json/multipleWrappers.json
pipeline-model-definition/src/test/resources/json/simpleWrapper.json
pipeline-model-definition/src/test/resources/json/toolsInStage.json
pipeline-model-definition/src/test/resources/multipleWrappers.groovy
pipeline-model-definition/src/test/resources/org/jenkinsci/plugins/pipeline/modeldefinition/agent/impl/LabelAndOtherFieldAgentScript.groovy
pipeline-model-definition/src/test/resources/simpleWrapper.groovy
pipeline-model-definition/src/test/resources/toolsInStage.groovy
pom.xml
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/d65d3dc3117f30a4502cfa7ad48c7494b9c0915d


Log:
Merge branch 'master' of github.com:jenkinsci/pipeline-model-definition-plugin into JENKINS-37781

Conflicts:
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStage.java


pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidator.java
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/JSONParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidatorImpl.groovy
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy

scm_issue_link@java.net (JIRA)

unread,
Nov 8, 2016, 10:10:05 AM11/8/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:

pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/AbstractModelASTCodeBlock.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTScriptBlock.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStage.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTWhen.java


pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidator.java
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/model/Stage.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/JSONParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/parser/ModelParser.groovy
pipeline-model-definition/src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidatorImpl.groovy

pipeline-model-definition/src/main/resources/ast-schema.json
pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/ModelInterpreter.groovy
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java
pipeline-model-definition/src/test/resources/when/simpleWhen.groovy
pipeline-model-definition/src/test/resources/when/whenEmpty.groovy
pipeline-model-definition/src/test/resources/when/whenException.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/ec6f0ea92278c82b854b65710d4fc0e8f65f3413
Log:
Merge pull request #41 from jenkinsci/JENKINS-37781

JENKINS-37781 Adding Stage.when to specify if a stage should run

rsandell@cloudbees.com (JIRA)

unread,
Nov 8, 2016, 11:21:05 AM11/8/16
to jenkinsc...@googlegroups.com
rsandell started work on Story JENKINS-37781
 
Change By: rsandell
Status: Open In Progress

rsandell@cloudbees.com (JIRA)

unread,
Nov 8, 2016, 11:21:06 AM11/8/16
to jenkinsc...@googlegroups.com

rsandell@cloudbees.com (JIRA)

unread,
Nov 8, 2016, 11:22:01 AM11/8/16
to jenkinsc...@googlegroups.com

jdumay@cloudbees.com (JIRA)

unread,
Nov 8, 2016, 3:46:03 PM11/8/16
to jenkinsc...@googlegroups.com
James Dumay commented on Story JENKINS-37781
 
Re: Pipeline Config: ability to skip whole pipeline or stages based on boolean condition

rsandell do you know what skipped sections look like as far as the Blue Ocean visualisation goes?

Andrew Bayer

unread,
Nov 8, 2016, 7:19:04 PM11/8/16
to jenkinsc...@googlegroups.com
The plan is to address that with https://github.com/jenkinsci/pipeline-model-definition-plugin/pull/47 - which needs a downstream PR in Blue Ocean to get the change this depends on merged in workflow-api.

A.

scm_issue_link@java.net (JIRA)

unread,
Nov 9, 2016, 6:12:03 AM11/9/16
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Robert Sandell
Path:
SYNTAX.md
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/71c3d60ee486e48757bbd76315dc69a9e0418775
Log:
Update SYNTAX.md

Noting changes introduced in JENKINS-37792, JENKINS-37781 and JENKINS-37778

Also fixed the script example and marked the code sections as groovy
so that GitHub hopefully can color the code a bit more nicely.

jdumay@cloudbees.com (JIRA)

unread,
Dec 11, 2016, 11:22:03 PM12/11/16
to jenkinsc...@googlegroups.com

Patrick Wolf not sure if this was documented? May have slipped through the cracks.

mail@tknerr.de (JIRA)

unread,
Jan 30, 2017, 2:24:01 AM1/30/17
to jenkinsc...@googlegroups.com

Is this a blue ocean only thing?

I'm wondering if there is a "skipped" state in plain Pipeline DSL / Stage View Plugin, but haven't found it yet...

mail@tknerr.de (JIRA)

unread,
Jan 30, 2017, 2:25:01 AM1/30/17
to jenkinsc...@googlegroups.com
Torben Knerr edited a comment on Story JENKINS-37781
Is this a blue ocean only thing?

I'm wondering if there is a "skipped" state in plain Pipeline DSL / Stage View Plugin, but haven't found it yet...


Also not clear how to use it in the DSL. Can you point me to an example?

mail@tknerr.de (JIRA)

unread,
Jan 30, 2017, 2:27:05 AM1/30/17
to jenkinsc...@googlegroups.com
Torben Knerr edited a comment on Story JENKINS-37781
Is this a blue ocean only thing?

I'm wondering if there is a "skipped" state in plain Pipeline DSL / Stage View Plugin, but haven't found it yet...

- Also not clear how to use it in the DSL. Can you point me to an example? -

*update: * found the docs:
https://github.com/jenkinsci/pipeline-model-definition-plugin/commit/71c3d60ee486e48757bbd76315dc69a9e0418775#diff-fa1a1fd4274e733b635b3978b3d39ce6R88

comscience15@gmail.com (JIRA)

unread,
Feb 9, 2018, 1:46:04 PM2/9/18
to jenkinsc...@googlegroups.com
Nat Sr commented on Story JENKINS-37781

James Dumay rsandell I see this ticket is resolved and wonder when and what release will it out? Could you guys please answer it? Thanks

This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)
Atlassian logo

leandro.lucarella@sociomantic.com (JIRA)

unread,
Mar 9, 2018, 8:12:02 AM3/9/18
to jenkinsc...@googlegroups.com

It's "resolved" as POSTPONED. So it's not fixed. Also, closing issues like that doesn't allow people to vote for them, which kind of sucks (I've seen it for other issues like supporting labels to steps).

andrew.bayer@gmail.com (JIRA)

unread,
Mar 9, 2018, 8:32:03 AM3/9/18
to jenkinsc...@googlegroups.com

Huh? We released the when directive for Declarative ages ago.

leandro.lucarella@sociomantic.com (JIRA)

unread,
Mar 9, 2018, 9:32:02 AM3/9/18
to jenkinsc...@googlegroups.com

Sorry, I think I got the comments mixed up, I was replying about scripted pipelines:

> => therefore filed https://issues.jenkins-ci.org/browse/JENKINS-47286 "Support skipping stages in scripted pipelines for nice visualization in blue ocean and classic UI stage view"

leandro.lucarella@sociomantic.com (JIRA)

unread,
Mar 9, 2018, 9:33:02 AM3/9/18
to jenkinsc...@googlegroups.com
Leandro Lucarella edited a comment on Story JENKINS-37781
Sorry, I think I got the comments mixed up, I was replying about scripted pipelines:

>
{quote} => therefore filed https://issues.jenkins-ci.org/browse/JENKINS-47286 "Support skipping stages in scripted pipelines for nice visualization in blue ocean and classic UI stage view"
{quote}

bitwiseman@gmail.com (JIRA)

unread,
Oct 22, 2019, 11:24:20 PM10/22/19
to jenkinsc...@googlegroups.com
Liam Newman closed an issue as Done
 

Bulk closing resolved issues.

Change By: Liam Newman
Status: Resolved Closed
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages