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

Error running builds with configuration matrix and TFS plugin

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • tfs-plugin
    • None
    • Windows (both server and client)

      We can't use TFS plugin on a project using configuration matrix. We've tried two different scenarios and both failed. It works fine on a project without a matrix.

      For the following scenarios consider the configuration axes:
      DB_PLATFORM ORACLE, SQL
      TARGET_APP APP1

      Also:

      • Using ANT to build project.
      • There´s no slave machines configured.

      =================
      Scenario 1 - Using Team Foundation Server with flag "Use update" checked.
      =================

      Problem description:
      Jenkins can´t find build.xml file to start the job related to a matrix configuration combination. It does a successful "tf get" from the TFS workspace corresponding to the main job folder, but "tf get" to others configuration matrix does not get any file, raising an error.

      MainJob console output:
      =======================
      Any file is downloaded at this time because a prior 'tf get' was executed and any file was updated in the server.
      Started by user xxxxxxxxxxxx
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspaces -format:brief -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Collection: http://xxx.yyy.zzz:8080/tfs/ABCD
      Workspace Owner Computer C
      ---------------------------------------- ------------------- -------- -
      IC-MainJob user MACHINE
      IC-DB_PLATFORM=ORACLE,TARGET_APP=APP1 user MACHINE
      IC-DB_PLATFORM=SQL,TARGET_APP==APP1 user MACHINE

      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd get . -recursive -version:D2011-07-21T14:35:29Z -noprompt ********
      All files up to date.
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd history $/PROJECT/folder1 -noprompt -version:D2011-07-21T14:16:06Z~D2011-07-21T14:35:30Z -recursive -format:detailed -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      No history entries were found for the item and version combination specified.
      Triggering SQL,11.5.0
      Triggering ORACLE,11.5.0
      Finished: FAILURE

      Job SQL,11.5.0 console output:
      ===================================
      Started by upstream project "MainJob" build number 161
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspaces -format:brief -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Collection: http://xxx.yyy.zzz:8080/tfs/ABCD
      Workspace Owner Computer C
      ------------------------------------- ------------------- -------- -
      IC-MainJob user MACHINE
      IC-DB_PLATFORM=ORACLE,TARGET_APP=APP1 user MACHINE
      IC-DB_PLATFORM=SQL,TARGET_APP==APP1 user MACHINE
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd get . -recursive -version:D2011-07-21T14:35:29Z -noprompt ********
      All files up to date.
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd history $/PROJECT/folder1 -noprompt -version:D2011-07-21T14:16:06Z~D2011-07-21T14:35:30Z -recursive -format:detailed -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      No history entries were found for the item and version combination specified.
      FATAL: Unable to find build script at C:\Apps\Hudson\jobs\MainJob\workspace\DB_PLATFORM/SQL/TARGET_APP/11.5.0\build.xml
      Build step 'Invoke Ant' marked build as failure
      Recording test results
      Finished: FAILURE

      Job ORACLE,11.5.0 console output:
      =================================
      Started by upstream project "MainJob" build number 161
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspaces -format:brief -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Collection: http://xxx.yyy.zzz:8080/tfs/ABCD
      Workspace Owner Computer C
      --------------------------------------- ------------------- -------- -
      IC-MainJob user MACHINE
      IC-DB_PLATFORM=ORACLE,TARGET_APP=APP1 user MACHINE
      IC-DB_PLATFORM=SQL,TARGET_APP==APP1 user MACHINE
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd get . -recursive -version:D2011-07-21T14:35:29Z -noprompt ********
      All files up to date.
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd history $/PROJECT/folder1 -noprompt -version:D2011-07-21T14:16:06Z~D2011-07-21T14:35:30Z -recursive -format:detailed -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      No history entries were found for the item and version combination specified.
      FATAL: Unable to find build script at C:\Apps\Hudson\jobs\MainJob\workspace\DB_PLATFORM/ORACLE/TARGET_APP/11.5.0\build.xml
      Build step 'Invoke Ant' marked build as failure
      Recording test results
      Finished: FAILURE

      ===========
      Scenario 2 - Like scenario 1, but flag "use update" is unchecked
      ===========

      Problem description:
      It´s not possible to map a child TFS workspace to a work folder, because this folder is already mapped to the TFS workspace related to the main (or upstream) job. This TFS workspace was created by Jenkins in the same job execution.

      MainJob console output:
      =======================
      Started by user xxxxxxxxxx
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspaces -format:brief -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Collection: http://xxx.yyy.zzz:8080/tfs/ABCD
      Workspace Owner Computer C
      --------------------------------------- ------------------- -------- -
      IC-MainJob user MACHINE
      IC-DB_PLATFORM=ORACLE,TARGET_APP=APP1 user MACHINE
      IC-DB_PLATFORM=SQL,TARGET_APP==APP1 user MACHINE
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspace -new "IC-MainJob;user" -noprompt -server: http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Workspace 'IC-MainJob' created.
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd workfold -map $/PROJECT/folder1 . "-workspace:IC-MainJob" -server: http://xxx.yyy.zzz:8080/tfs/ABCD ********
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd get . -recursive -version:D2011-07-21T15:04:38Z -noprompt ********
      C:\Apps\Hudson\jobs\MainJob\workspace:
      Getting file1
      ...
      Getting build.xml

      <other project files being downloaded >

      C:\Apps\Hudson\jobs\MainJob\workspace\util:
      Getting build.xml
      [workspace] $ c:\apps\TEE-CLC-10.0.0\tf.cmd history $/PROJECT/folder1 -noprompt -version:D2011-07-21T15:04:13Z~D2011-07-21T15:04:39Z -recursive -format:detailed -server: http://xxx.yyy.zzz:8080/tfs/ABCD ********
      No history entries were found for the item and version combination specified.
      Triggering SQL,11.5.0
      Triggering ORACLE,11.5.0
      Finished: FAILURE

      Job SQL,11.5.0 console output:
      ==================================
      Started by upstream project "MainJob" build number 164
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspaces -format:brief -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Collection: http://xxx.yyy.zzz:8080/tfs/ABCD
      Workspace Owner Computer C
      --------------------------------------- ------------------- -------- -
      IC-MainJob user MACHINE
      IC-DB_PLATFORM=ORACLE,TARGET_APP=APP1 user MACHINE
      IC-DB_PLATFORM=SQL,TARGET_APP==APP1 user MACHINE
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspace -delete IC-DB_PLATFORM=SQL,TARGET_APP=11.5.0;user -noprompt -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Workspace 'IC-DB_PLATFORM=SQL,TARGET_APP=11.5.0' deleted.
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspace -new IC-DB_PLATFORM=SQL,TARGET_APP=11.5.0;user -noprompt -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Workspace 'IC-DB_PLATFORM=SQL,TARGET_APP=11.5.0' created.
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workfold -map $/PROJECT/folder1 . -workspace:IC-DB_PLATFORM=SQL,TARGET_APP=11.5.0 -server: http://xxx.yyy.zzz:8080/tfs/ABCD ********
      An error occurred: The working folder C:\Apps\Hudson\jobs\MainJob\workspace is already in use by the workspace IC-MainJob;user on computer MACHINE.
      FATAL: Executable returned an unexpected result code [100]
      ERROR: null
      Recording test results
      Finished: FAILURE

      Job ORACLE,11.5.0 console output:
      =====================================
      Started by upstream project "MainJob" build number 164
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspaces -format:brief -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Collection: http://xxx.yyy.zzz:8080/tfs/ABCD/
      Workspace Owner Computer C
      --------------------------------------- ------------------- -------- -
      IC-MainJob User MACHINE
      IC-DB_PLATFORM=4GL,TARGET_APP=11.5.0 User MACHINE
      IC-DB_PLATFORM=ORACLE,TARGET_APP=11.5.0 User MACHINE
      IC-DB_PLATFORM=SQL,TARGET_APP=11.5.0 User MACHINE
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspace -delete IC-DB_PLATFORM=ORACLE,TARGET_APP=11.5.0;User -noprompt -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Workspace 'IC-DB_PLATFORM=ORACLE,TARGET_APP=11.5.0' deleted.
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workspace -new IC-DB_PLATFORM=ORACLE,TARGET_APP=11.5.0;User -noprompt -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      Workspace 'IC-DB_PLATFORM=ORACLE,TARGET_APP=11.5.0' created.
      $ c:\apps\TEE-CLC-10.0.0\tf.cmd workfold -map $/PROJECT/folder1 . -workspace:IC-DB_PLATFORM=ORACLE,TARGET_APP=11.5.0 -server:http://xxx.yyy.zzz:8080/tfs/ABCD ********
      An error occurred: The working folder C:\Apps\Hudson\jobs\MainJob\workspace is already in use by the workspace IC-MainJob;User on computer MACHINE.
      FATAL: Executable returned an unexpected result code [100]
      ERROR: null
      Recording test results
      Finished: FAILURE

            dastahel David Staheli
            fcordovabr Flavio Cordova
            Votes:
            4 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: