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

Use ToolInstallation as replacement to p4 path specified in Jobs

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • p4-plugin
    • None

      Got this issue :

      job is configured with p4 path on build slave /usr/bin/p4. When tagging a build, an error occurred because executing on master that don't have p4 installed on same path.

      perforce plugin should use the Jenkins concept of ToolInstallation + NodeSpecific, so that it gets simpler to manage differences between nodes.

          [JENKINS-11369] Use ToolInstallation as replacement to p4 path specified in Jobs

          Nicolas De Loof created issue -
          Rob Petti made changes -
          Link New: This issue depends on JENKINS-5120 [ JENKINS-5120 ]
          Rob Petti made changes -
          Link New: This issue depends on JENKINS-2947 [ JENKINS-2947 ]
          Rob Petti made changes -
          Assignee New: Rob Petti [ rpetti ]
          Rob Petti made changes -
          Link Original: This issue depends on JENKINS-5120 [ JENKINS-5120 ]
          Rob Petti made changes -
          Link Original: This issue depends on JENKINS-2947 [ JENKINS-2947 ]
          Rob Petti made changes -
          Link New: This issue is related to JENKINS-5120 [ JENKINS-5120 ]
          Rob Petti made changes -
          Link New: This issue is related to JENKINS-2947 [ JENKINS-2947 ]

          I'm working on this one and I'll create a pull request once ready. I would remove p4 executable path setting from the job level and have it as a tool installation. As a migration path I was thinking to add a tool installation for each different p4 executable path that are being used (case insensitive for Windows). No matter whether the job is enabled or not and whether it's tied on master or slave. Correct tool installation would then be picked for each job. There could be some extra unneeded tool installations but I think it's fair enough. Comments?

          Mikko Tapaninen added a comment - I'm working on this one and I'll create a pull request once ready. I would remove p4 executable path setting from the job level and have it as a tool installation. As a migration path I was thinking to add a tool installation for each different p4 executable path that are being used (case insensitive for Windows). No matter whether the job is enabled or not and whether it's tied on master or slave. Correct tool installation would then be picked for each job. There could be some extra unneeded tool installations but I think it's fair enough. Comments?

          Rob Petti added a comment -

          Sounds good to me! You may want to look into a function called "readResolve" for performing the upgrade between versions. The perforce plugin currently doesn't implement it, but the GitSCM plugin has a good example of how this can be used.

          Rob Petti added a comment - Sounds good to me! You may want to look into a function called "readResolve" for performing the upgrade between versions. The perforce plugin currently doesn't implement it, but the GitSCM plugin has a good example of how this can be used.

            rpetti Rob Petti
            ndeloof Nicolas De Loof
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: