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

Perforce plugin should replace variables from matrix configuration

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: perforce-plugin
    • Labels:
      None
    • Environment:
      Linux, Perforce
    • Similar Issues:

      Description

      It would be nice to be able to build software from different branches using matrix configuration.

      I would like to have a parameter in the client view map, like this:

      //mib2_com/${BRANCH}/sqlite3/... //WRK/sqlite3/...

      and this should be replaced with the actual branch, e.g. "dev/main", "rel/2014", ...

      Master Job checkout behaviour:
      As there is currently no way to omit the checkout in the Master Matrix Job, the first value of the axes should be used.

      As we're doing a lot of branches in our company, I would appreciate this behaviour a lot! This would make our configuration so much more light weight

      Thanks in advance,
      Christian

        Attachments

          Issue Links

            Activity

            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            src/main/java/hudson/plugins/perforce/utils/MacroStringHelper.java
            http://jenkins-ci.org/commit/perforce-plugin/a35f1fe507ac86a08f857fe0e03a36d658a66138
            Log:
            [FIXED JENKINS-23599] - Substitute Matrix Axis values in PerforceSCM

            Behavior:

            • MatrixConfiguration: Inject Values
            • MatrixProject: Inject the first value or empty string if it is not available

            Signed-off-by: Oleg Nenashev <o.v.nenashev@gmail.com>

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: src/main/java/hudson/plugins/perforce/utils/MacroStringHelper.java http://jenkins-ci.org/commit/perforce-plugin/a35f1fe507ac86a08f857fe0e03a36d658a66138 Log: [FIXED JENKINS-23599] - Substitute Matrix Axis values in PerforceSCM Behavior: MatrixConfiguration: Inject Values MatrixProject: Inject the first value or empty string if it is not available Signed-off-by: Oleg Nenashev <o.v.nenashev@gmail.com>
            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            Master Job checkout behaviour:
            As there is currently no way to omit the checkout in the Master Matrix Job, the first value of the axes should be used.

            SCMCheckoutStrategy allows to implement such feature.
            Implementation: https://wiki.jenkins-ci.org/display/JENKINS/Extension+points#Extensionpoints-jenkins.scm.SCMCheckoutStrategy
            AFAIK, there was an issue for the new strategy implementation

            Commit in Perforce: https://github.com/jenkinsci/perforce-plugin/commit/a35f1fe507ac86a08f857fe0e03a36d658a66138

            Show
            oleg_nenashev Oleg Nenashev added a comment - Master Job checkout behaviour: As there is currently no way to omit the checkout in the Master Matrix Job, the first value of the axes should be used. SCMCheckoutStrategy allows to implement such feature. Implementation: https://wiki.jenkins-ci.org/display/JENKINS/Extension+points#Extensionpoints-jenkins.scm.SCMCheckoutStrategy AFAIK, there was an issue for the new strategy implementation Commit in Perforce: https://github.com/jenkinsci/perforce-plugin/commit/a35f1fe507ac86a08f857fe0e03a36d658a66138
            Hide
            krizleebear krizleebear added a comment -

            I tested CloudBees build #126 and it works like a charm! Thanks for this extremely useful improvement! So now I'm really looking forward to the official release!

            Show
            krizleebear krizleebear added a comment - I tested CloudBees build #126 and it works like a charm! Thanks for this extremely useful improvement! So now I'm really looking forward to the official release!
            Hide
            krizleebear krizleebear added a comment -

            After two more months, there is still no release containing this fix
            Will there be ever a new release of Perforce plugin? There hasn't been a release since Januar (https://github.com/jenkinsci/perforce-plugin/releases).

            I've also seen that there's a completely new perforce plugin (https://github.com/jenkinsci/p4-plugin) that's in active development.

            Show
            krizleebear krizleebear added a comment - After two more months, there is still no release containing this fix Will there be ever a new release of Perforce plugin? There hasn't been a release since Januar ( https://github.com/jenkinsci/perforce-plugin/releases ). I've also seen that there's a completely new perforce plugin ( https://github.com/jenkinsci/p4-plugin ) that's in active development.
            Hide
            krizleebear krizleebear added a comment -

            Thanks a lot! The new version of Perforce plugin released in November includes this issue and it works like a charm!

            Unfortunately there's a subsequent problem with encoding slash characters in Jenkins core (or matrix plugin?) that should have been fixed a few years ago. I reopened this issue: https://issues.jenkins-ci.org/browse/JENKINS-2670
            Is there anything else I can do to help this problem getting fixed?

            Show
            krizleebear krizleebear added a comment - Thanks a lot! The new version of Perforce plugin released in November includes this issue and it works like a charm! Unfortunately there's a subsequent problem with encoding slash characters in Jenkins core (or matrix plugin?) that should have been fixed a few years ago. I reopened this issue: https://issues.jenkins-ci.org/browse/JENKINS-2670 Is there anything else I can do to help this problem getting fixed?
            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            Please do not re-open cases without an analysis.
            JENKINS-25599 overs your case.
            Hopefully, the new plugin version will be released on this week.

            P.S: If you experience any issue, please feel free to contribute. There's no 24/7 maintainers of this plugin

            Show
            oleg_nenashev Oleg Nenashev added a comment - Please do not re-open cases without an analysis. JENKINS-25599 overs your case. Hopefully, the new plugin version will be released on this week. P.S: If you experience any issue, please feel free to contribute. There's no 24/7 maintainers of this plugin

              People

              • Assignee:
                oleg_nenashev Oleg Nenashev
                Reporter:
                krizleebear krizleebear
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: