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

Need to be able to use Flexible Publish in matrix job post-build actions

    Details

    • Similar Issues:

      Description

      I would love to be able to use this (and, by extension, Conditional Build Steps), in matrix job post-build actions. Please please!!

        Attachments

          Issue Links

            Activity

            owenmehegan Owen Mehegan created issue -
            Hide
            celltestr celltestr added a comment -

            We are also having a problem with the Flexible publish plugin on matrix jobs. The checkbox does not exist in the "Post-build Actions"

            I tried copying the xml code from a regular job and update the config.xml of the matrix job and it worked. The problem is that every time someone is configuring the matrix job and hit save it removes the Flexible publish section since it does not exist in the UI.

            Fix will be really appreciated.

            Show
            celltestr celltestr added a comment - We are also having a problem with the Flexible publish plugin on matrix jobs. The checkbox does not exist in the "Post-build Actions" I tried copying the xml code from a regular job and update the config.xml of the matrix job and it worked. The problem is that every time someone is configuring the matrix job and hit save it removes the Flexible publish section since it does not exist in the UI. Fix will be really appreciated.
            Hide
            cjw296 Chris Withers added a comment -

            Yes please...

            Show
            cjw296 Chris Withers added a comment - Yes please...
            Hide
            ikedam ikedam added a comment -

            Flexible Publish for multiconfiguration projects are disabled with code:

                    public boolean isApplicable(final Class<? extends AbstractProject> aClass) {
                        //@TODO enable for matrix builds - requires aggregation
            //            return FreeStyleProject.class.equals(aClass);
                        return !MatrixProject.class.equals(aClass) && !PROMOTION_JOB_TYPE.equals(aClass.getCanonicalName());
                    }
            

            @bap
            Let me know the case using Flexible Publish in a multiconfiguration project causes a problem. That is the case that requires an aggregation. I'll consider a way to resolve.

            Show
            ikedam ikedam added a comment - Flexible Publish for multiconfiguration projects are disabled with code: public boolean isApplicable( final Class <? extends AbstractProject> aClass) { //@TODO enable for matrix builds - requires aggregation // return FreeStyleProject. class. equals(aClass); return !MatrixProject. class. equals(aClass) && !PROMOTION_JOB_TYPE.equals(aClass.getCanonicalName()); } @bap Let me know the case using Flexible Publish in a multiconfiguration project causes a problem. That is the case that requires an aggregation. I'll consider a way to resolve.
            Hide
            ikedam ikedam added a comment -

            Flexible Publish must support MatrixAggregatable for work with multiconfiguration projects.
            This allows publishers work both for each axe combination builds and the parent build.

            Show
            ikedam ikedam added a comment - Flexible Publish must support MatrixAggregatable for work with multiconfiguration projects. This allows publishers work both for each axe combination builds and the parent build.
            Hide
            ikedam ikedam added a comment -
            Show
            ikedam ikedam added a comment - Sent a pull request. https://github.com/jenkinsci/flexible-publish-plugin/pull/2
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalMatrixAggregator.java
            src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java
            src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexibleMatrixAggregator.java
            src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexiblePublisher.java
            src/main/java/org/jenkins_ci/plugins/flexible_publish/MarkPerformedBuilder.java
            src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/config.jelly
            src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/config.properties
            src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/help-configuredAggregation.html
            http://jenkins-ci.org/commit/flexible-publish-plugin/3fbb375fed52cc506e7493a6542d967bcf846af3
            Log:
            JENKINS-14494 Supports MatrixAggregator.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalMatrixAggregator.java src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexibleMatrixAggregator.java src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexiblePublisher.java src/main/java/org/jenkins_ci/plugins/flexible_publish/MarkPerformedBuilder.java src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/config.jelly src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/config.properties src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/help-configuredAggregation.html http://jenkins-ci.org/commit/flexible-publish-plugin/3fbb375fed52cc506e7493a6542d967bcf846af3 Log: JENKINS-14494 Supports MatrixAggregator.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java
            http://jenkins-ci.org/commit/flexible-publish-plugin/22d147c19a151d1942a4f5d6dc3bf252b2a775a1
            Log:
            JENKINS-14494 compatibility of the constructor of ConditionalPublisher.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java http://jenkins-ci.org/commit/flexible-publish-plugin/22d147c19a151d1942a4f5d6dc3bf252b2a775a1 Log: JENKINS-14494 compatibility of the constructor of ConditionalPublisher.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java
            src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/config.jelly
            http://jenkins-ci.org/commit/flexible-publish-plugin/99e2d375f166e1e1ff02a40f74d08bf354380e71
            Log:
            JENKINS-14494 use ${it} instead of Stapler.getCurrentRequest().findAncestorObject()

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java src/main/resources/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher/config.jelly http://jenkins-ci.org/commit/flexible-publish-plugin/99e2d375f166e1e1ff02a40f74d08bf354380e71 Log: JENKINS-14494 use ${it} instead of Stapler.getCurrentRequest().findAncestorObject()
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexiblePublisher.java
            src/test/java/org/jenkins_ci/plugins/flexible_publish/AggregationRecorder.java
            src/test/java/org/jenkins_ci/plugins/flexible_publish/MatrixAggregationTest.java
            http://jenkins-ci.org/commit/flexible-publish-plugin/d172222f1b743581acb1ca8c899616bddde1f31f
            Log:
            [FIX JENKINS-14494] Tests for Matrix Support.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexiblePublisher.java src/test/java/org/jenkins_ci/plugins/flexible_publish/AggregationRecorder.java src/test/java/org/jenkins_ci/plugins/flexible_publish/MatrixAggregationTest.java http://jenkins-ci.org/commit/flexible-publish-plugin/d172222f1b743581acb1ca8c899616bddde1f31f Log: [FIX JENKINS-14494] Tests for Matrix Support.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java
            src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexiblePublisher.java
            http://jenkins-ci.org/commit/flexible-publish-plugin/4b03cee2f35acac2018237871495cb49897908ea
            Log:
            JENKINS-14494 Removed unnecessary imports.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/java/org/jenkins_ci/plugins/flexible_publish/ConditionalPublisher.java src/main/java/org/jenkins_ci/plugins/flexible_publish/FlexiblePublisher.java http://jenkins-ci.org/commit/flexible-publish-plugin/4b03cee2f35acac2018237871495cb49897908ea Log: JENKINS-14494 Removed unnecessary imports.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: ikedam
            Path:
            pom.xml
            http://jenkins-ci.org/commit/flexible-publish-plugin/6b8fb4023efc2b50f456bd53f914ca95813db4ff
            Log:
            JENKINS-14494 Make compilable with JDK 1.7.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: pom.xml http://jenkins-ci.org/commit/flexible-publish-plugin/6b8fb4023efc2b50f456bd53f914ca95813db4ff Log: JENKINS-14494 Make compilable with JDK 1.7.
            Hide
            ikedam ikedam added a comment -

            I added this feature in flexible-publish-0.11.
            Please try, and report issues if something wrong.

            Show
            ikedam ikedam added a comment - I added this feature in flexible-publish-0.11. Please try, and report issues if something wrong.
            ikedam ikedam made changes -
            Field Original Value New Value
            Status Open [ 1 ] Closed [ 6 ]
            Assignee bap [ bap ] ikedam [ ikedam ]
            Resolution Fixed [ 1 ]
            Hide
            wh WH added a comment -

            Jenkins LTS 1.532.1
            Flexible publisher plugin 0.12
            Jenkins Subversion Tagging Plugin 1.16

            I have a matrix job with 2 labels and the flexible publisher as post build action.
            I checked the check butten "Condition for matrix aggregation", set "Run on parent?" to "Always" and set "Perform subversion tagging on successful build" as action.

            Result: The matrix parent job performs no tagging! The parent jobs console output even shows no output from the flexible publisher plugin.

            Originally I hoped the new matrix support will solve this problem: https://issues.jenkins-ci.org/browse/JENKINS-9683

            Show
            wh WH added a comment - Jenkins LTS 1.532.1 Flexible publisher plugin 0.12 Jenkins Subversion Tagging Plugin 1.16 I have a matrix job with 2 labels and the flexible publisher as post build action. I checked the check butten "Condition for matrix aggregation", set "Run on parent?" to "Always" and set "Perform subversion tagging on successful build" as action. Result: The matrix parent job performs no tagging! The parent jobs console output even shows no output from the flexible publisher plugin. Originally I hoped the new matrix support will solve this problem: https://issues.jenkins-ci.org/browse/JENKINS-9683
            wh WH made changes -
            Resolution Fixed [ 1 ]
            Status Closed [ 6 ] Reopened [ 4 ]
            Hide
            ikedam ikedam added a comment -

            Subversion Tagging Plugin does not support running on matrix parents.
            Even without Flexible Publisher plugin, your job should not run as expected.
            Flexible Publisher plugin does not make a publisher who does not support matrix projects support them.

            Anyway, Create a new ticket.

            Show
            ikedam ikedam added a comment - Subversion Tagging Plugin does not support running on matrix parents. Even without Flexible Publisher plugin, your job should not run as expected. Flexible Publisher plugin does not make a publisher who does not support matrix projects support them. Anyway, Create a new ticket.
            ikedam ikedam made changes -
            Status Reopened [ 4 ] Closed [ 6 ]
            Resolution Fixed [ 1 ]
            wh WH made changes -
            Link This issue is related to JENKINS-21345 [ JENKINS-21345 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 145130 ] JNJira + In-Review [ 206006 ]

              People

              • Assignee:
                ikedam ikedam
                Reporter:
                owenmehegan Owen Mehegan
              • Votes:
                6 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: