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

TFS plug-in 4.0.0 lists all workspaces on server

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Critical
    • Resolution: Fixed
    • Component/s: tfs-plugin
    • Labels:
      None
    • Environment:
      Jenkins 1.627
      multi-job plugin
      folder plugin

      Windows 8.1 x64 (master)
      CentOS 5.5 x64 (slave)
    • Similar Issues:

      Description

      I thought I'd give the new 4.0.0 tfs-plugin a spin to see if it solved my intermittent unable to determine workspace errors (https://social.msdn.microsoft.com/Forums/vstudio/en-US/0f9a3368-de75-47b7-925b-3cfbe9ac810c/tf-get-intermittently-reports-unable-to-determine-workspace?forum=tee)

      The workspace list is showing workspaces from all computers and not just the workspaces available on the current computer.

      Started by user <user>
      [EnvInject] - Loading node environment variables.
      Building on master in workspace C:\Program Files (x86)\Jenkins\jobs\7.12\jobs\work\jobs\publish_nl000fs01\workspace
      Querying for remote changeset at '$/<product>/7.12/work/other/internal/qa/ant' as of 'D2015-09-09T06:25:29Z'...
      Query result is: Changeset #208383 by '<domain>\<user>' on '2015-09-01T14:44:48Z'.
      Listing workspaces from https://<server>:8088/tfs/<collection>...
      Workspace                                                 Owner                          Computer                    Comment                                                              
      --------------------------------------------------------- ------------------------------ --------------------------- ---------------------------------------------------------------------
      workspaces from ALL computers shown here
      

      (moved issue 2 'get latest' to JENKINS-30355)

        Attachments

          Activity

          Hide
          smd Stefan Drissen added a comment - - edited

          Hi Olivier,

          I have given the 5.0.0 plug-in a very quick spin (with Jenkins 2.17) on Windows 7. Now no workspaces are listed at all (only the message that workspaces are being listed) - was this the intention?

          09:59:23 Started by user Stefan Drissen
          09:59:23 [EnvInject] - Loading node environment variables.
          09:59:23 Building in workspace C:\Program Files (x86)\Jenkins\workspace\7.20\work\build_bp-11.4
          09:59:23 Querying for remote changeset at '$/project/7.20/work' as of 'D2016-08-10T07:59:23Z'...
          09:59:23 Query result is: Changeset #217899 by 'domain\user' on '2016-07-18T11:47:02Z'.
          09:59:23 Listing workspaces from https://<server>:8088/tfs/BSCollection...
          09:59:23 Getting version 'C217899' to 'C:\Program Files (x86)\Jenkins\workspace\7.20\work\build_bp-11.4'...
          09:59:23 Finished getting version 'C217899'. Retrieved 0 resources.
          

          Regards,

          Stefan

          Show
          smd Stefan Drissen added a comment - - edited Hi Olivier, I have given the 5.0.0 plug-in a very quick spin (with Jenkins 2.17) on Windows 7. Now no workspaces are listed at all (only the message that workspaces are being listed) - was this the intention? 09:59:23 Started by user Stefan Drissen 09:59:23 [EnvInject] - Loading node environment variables. 09:59:23 Building in workspace C:\Program Files (x86)\Jenkins\workspace\7.20\work\build_bp-11.4 09:59:23 Querying for remote changeset at '$/project/7.20/work' as of 'D2016-08-10T07:59:23Z'... 09:59:23 Query result is: Changeset #217899 by 'domain\user' on '2016-07-18T11:47:02Z'. 09:59:23 Listing workspaces from https://<server>:8088/tfs/BSCollection... 09:59:23 Getting version 'C217899' to 'C:\Program Files (x86)\Jenkins\workspace\7.20\work\build_bp-11.4'... 09:59:23 Finished getting version 'C217899'. Retrieved 0 resources. Regards, Stefan
          Hide
          oli_at_jsi Olivier Dagenais added a comment -

          Hi Stefan,

          Good eye!

          Version 5.2.0 of the TFS plugin for Jenkins includes an improvement in the wording of that message.

          Cheers,
          - Oli

          Show
          oli_at_jsi Olivier Dagenais added a comment - Hi Stefan, Good eye! Version 5.2.0 of the TFS plugin for Jenkins includes an improvement in the wording of that message . Cheers, - Oli
          Hide
          smd Stefan Drissen added a comment -

          Nice, in that change I see that you have also changed the test case to match the message, but the test case alertLog seems to indicate that the workspaces /should/ be listed?

          Are the tests not being executed or am I missing something?

          Stefan

          Show
          smd Stefan Drissen added a comment - Nice, in that change I see that you have also changed the test case to match the message, but the test case alertLog seems to indicate that the workspaces /should/ be listed? Are the tests not being executed or am I missing something? Stefan
          Hide
          simpligility Manfred Moser added a comment -

          Currently this is a TODO items to it controlled by a environment variable or job or global config and the listing is only exectued in the test. The normal constructor does not cause the workspaces to be listed. If you want this feature implemented please send a PR or at least file a new issues.

          See https://github.com/jenkinsci/tfs-plugin/blob/master/tfs/src/main/java/hudson/plugins/tfs/commands/ListWorkspacesCommand.java for details and the normal constructor vs the one used in the tests.

          Show
          simpligility Manfred Moser added a comment - Currently this is a TODO items to it controlled by a environment variable or job or global config and the listing is only exectued in the test. The normal constructor does not cause the workspaces to be listed. If you want this feature implemented please send a PR or at least file a new issues. See https://github.com/jenkinsci/tfs-plugin/blob/master/tfs/src/main/java/hudson/plugins/tfs/commands/ListWorkspacesCommand.java for details and the normal constructor vs the one used in the tests.
          Hide
          smd Stefan Drissen added a comment -

          OK, fair enough, thanks for the explanation.

          Show
          smd Stefan Drissen added a comment - OK, fair enough, thanks for the explanation.

            People

            • Assignee:
              smd Stefan Drissen
              Reporter:
              smd Stefan Drissen
            • Votes:
              12 Vote for this issue
              Watchers:
              15 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: