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

Polling broken on Matrix configuration

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Critical Critical
    • p4-plugin
    • None
    • Jenkins ver. 2.19.1
      p4-plugin version 1.4.8
      matrix-project 1.6

      After upgrading p4-plugin from 1.0.14 to 1.4.8, all our matrix build configurations started triggering continuously. It turns out, the plugin changed the way it resolves variables in the workspace name for the matrix configuration. The way the SCM polling does it and the actual build is different, which leads to the polling trying to use a non-existent workspace name, and always detecting new changes.

      Build name: test-build-config
      Workspace name in configuration: jenkins-${NODE_NAME}-${JOB_NAME}

      Polling log, observe the workspace name has been calculated using the JOB_NAME of the job of the first matrix axis combination. In previous versions of the plugin, this would be the build name, so the workspace would be 'jenkins-master-test-build-config'.

      Perforce Software Polling Log
      
      Started on Oct 11, 2016 12:15:00 AM
      Polling SCM changes on master
      P4: Polling on: master with:jenkins-master-test-build-config-AXIS_1-value_1-AXIS_2-Value_2-AXIS_3-Value_3
      ... p4 client -o jenkins-master-test-build-config-AXIS_1-value_1-AXIS_2-Va___ +
      ... p4 info +
      
      P4 Task: establishing connection.
      ... server: perforce-ci.tomtomgroup.com:1666
      ... node: michi-jenkins-00
      P4: Polling with cstat: //jenkins-master-test-build-config-AXIS_1-value_1-AXIS_2-Value_2-AXIS_3-Value_3/...
      ... p4 cstat //jenkins-master-test-build-config-AXIS_1-value_1-AXIS_2-Valu___ +
      ... p4 change -o 2418201 +
      ... found change: 2418201
      ... p4 change -o 2364282 +
      ... found change: 2364282
      ... p4 change -o 2357042 +
      ... found change: 2357042
      Done. Took 1.7 sec
      Changes found
      

      Build log (the kick off of the master build, before spawning the builds for each matrix axis combination), however, checks out 'jenkins-master-test-build-config'. So the polling workspace and the build workspace are different. And since the former does not exist, each poll triggers a build.

            Unassigned Unassigned
            mejdys Michal Ejdys
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: