[JIRA] (JENKINS-37828) Pipeline Model: Steps at peer level to parallel below stage cause compilation error

2 views
Skip to first unread message

andrew.bayer@gmail.com (JIRA)

unread,
Aug 30, 2016, 6:25:04 PM8/30/16
to jenkinsc...@googlegroups.com
Andrew Bayer created an issue
 
Jenkins / Bug JENKINS-37828
Pipeline Model: Steps at peer level to parallel below stage cause compilation error
Issue Type: Bug Bug
Assignee: Andrew Bayer
Components: pipeline-model-definition-plugin
Created: 2016/Aug/30 10:24 PM
Environment: Pipeline Model 0.1
Priority: Minor Minor
Reporter: Andrew Bayer

This is a fun side effect of ParallelStep not having a DataBoundConstructor - theoretically, it should be possible to have both parallel and other steps directly within a stage, but the attempt to validate the arguments to parallel goes wrong due to that missing DataBoundConstructor.

The ModelParser does look for parallel and treat it differently if it's the only step under the stage, but we're not looking for that in JSONParser at all, and we're not rejecting parallel in other cases in the first place. So...need to think about this some.

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

andrew.bayer@gmail.com (JIRA)

unread,
Sep 1, 2016, 10:09:01 AM9/1/16
to jenkinsc...@googlegroups.com
Andrew Bayer started work on Bug JENKINS-37828
 
Change By: Andrew Bayer
Status: Open In Progress

andrew.bayer@gmail.com (JIRA)

unread,
Sep 1, 2016, 10:25:01 AM9/1/16
to jenkinsc...@googlegroups.com

andrew.bayer@gmail.com (JIRA)

unread,
Sep 1, 2016, 10:25:01 AM9/1/16
to jenkinsc...@googlegroups.com

scm_issue_link@java.net (JIRA)

unread,
Sep 6, 2016, 9:59:01 AM9/6/16
to jenkinsc...@googlegroups.com
SCM/JIRA link daemon commented on Bug JENKINS-37828
 
Re: Pipeline Model: Steps at peer level to parallel below stage cause compilation error

Code changed in jenkins
User: Andrew Bayer
Path:
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStep.groovy
src/main/groovy/org/jenkinsci/plugins/pipeline/modeldefinition/validator/ModelValidator.groovy
src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/ValidatorTest.java
src/test/resources/errors/rejectParallelMixedInSteps.groovy
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/cb86d2ba560a5d89005495876376d549fc6a1b44
Log:
[FIXED JENKINS-37828] Properly reject parallel.

More notably, reject it when it's not the only step in a block. In the
JSON representation, we don't even use the term parallel - we just
have multiple branches. In the groovy parsing, we look for parallel as
the only step in a stage and treat it differently (resulting in
multiple branches). So any time we see parallel as a step by the time
we get to validation, well, it's wrong. So, yeah.

andrew.bayer@gmail.com (JIRA)

unread,
Sep 6, 2016, 10:14:01 AM9/6/16
to jenkinsc...@googlegroups.com
 

Will be released in Pipeline Model Definition 0.2

Change By: Andrew Bayer
Status: In Review Resolved
Resolution: Fixed

bitwiseman@gmail.com (JIRA)

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

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