Skip to content

Microsoft Team Foundation Server Plug-in

Last update April 17, 2019

Plug-in Version 1.0.3

The Microsoft Team Foundation Server (TFS) plug-in lets you track work items through the release pipeline.

The TFS plug-in synchronizes work items between Team Foundation Server or Visual Studio Team Services (VSTS) and Automic® Continuous Delivery Director. This integration allows TFS and VSTS to be used as any other content source for a release in Automic® Continuous Delivery Director.

Content synced includes features, epics, code review requests, tasks, test cases, and bugs. You can also import content into Automic® Continuous Delivery Director from TFS and VSTS.

Supported Versions

The TFS plug-in supports TFS 2017 and above.

To learn more about TFS, see https://www.visualstudio.com/tfs/

To learn more about VSTS, see https://www.visualstudio.com/team-services/

Capabilities

The TFS plug-in lets you synchronize work items between TFS or VSTS and Automic® Continuous Delivery Director.

What's New

The following updates were made for plug-in version 1.0.3:

  • Support was added for Java 11.

Configuration

Register the plug-in and create endpoints as described in Manage Plug-ins

Manifest URL

For plug-in registration, use the following TFS manifest URL: http://<plugin-server>:<port>/cdd-tfs-plugin/manifest.json.

Endpoint Parameters

Select the TFS plug-in in the ADD ENDPOINT dialog to create an endpoint for the TFS plug-in. The following information is required when you create an endpoint:

  • URL
    Enter the URL of your TFS machine or VSTS instance. 
    Syntax: (For TFS) http://machine-name:8080/tfs
    Example:  (For TFS) http://192.123.45.678/ tfs
    Syntax: (For VSTS) http://<instance-name>.visualstudio.com
    Example: (For VSTS) https://catech.visualstudio.com
  • Collection
    Enter the name of your team project collection (a group of team projects).
  • Authentication Type
    Select one of the following methods to authenticate to the TFS service:
    • Personal Access Token
    • NTLM
      For Personal Access Token Authentication only
    • Username
      Enter the user name to authenticate to the TFS service.
    • Personal Access Token
      Enter your personal access token to authenticate to the TFS service.
      For NTLM Authentication only
    • Username
      Enter the user name to authenticate to the TFS service.
    • Password
      Enter your password to authenticate to the TFS service.
    • Domain
      Enter the domain of your TFS machine
      Example:ca.com

To check the connection to TFS, use the endpoint Test Connection option.

Import Work Items

The TFS plug-in lets you sync content between TFS and Automic® Continuous Delivery Director releases. Use this capability when you create a release to see the related TFS information.

Follow these steps:

  1. In a release, expand the Apps & Work Items tree on the left menu, and  select the version number.
  2. Select Add Work Items.
    The ADD WORK ITEMS window opens.
  3. Select the External Work Items option.
  4. Enter a name for the work items source.
    Example: TFS Feed
  5. Under Work Items Source, select the TFS plug-in and a configured TFS endpoint.
  6. In Import Using, select either Filter or WIQL. WIQL lets you write queries in Work Item Query Language to import content.
  7. Provide information in the required parameter fields. These fields let you build a query that searches TFS or VSTS for work items that match the criteria.

    WIQL
    Available fields:

    • Query
      Specify a WIQL query to import work items.
      Example:

      SELECT [System.ID],[System.WorkItemType],[System.Title],[System.State] 
      FROM WorkItems
      WHERE [System.TeamProject] = 'TFS Demo'

    Filter
    The following fields are available for filtering the content import results:

    Values:   To select from a list of possible values, type an at sign "@" in the field. You cannot combine values with free text or tokens. Applies to all fields except Work Item Tags .
    • Team Project
      Specify the name of the TFS team project that contains the content you want to import. Type an at sign "@" to select from a list of team projects in the TFS endpoint. Type the at sign "@" in other fields to select from a dynamic list of entities that are associated with the selected team project.
      Values: An alphanumeric string.
      • Must not contain any Unicode control characters or surrogate characters
      • Must not contain the following characters: / : \ ~ & % ; @ ' " ? < > | # $ * } { , + = [ ]
      • Must not start with an underscore (_)
      • Must not start or end with a period (.)
    • Area Path
      Specify the area path that is defined for the team project. 
    • Iteration Path
      Specify the iteration path that is defined for the team project.
    • Work Item Type
      Specify the type of work item that you want to import.
    • Work Item State
      Specify the work item states to import. This field lets you filter what is imported based on the state.
      Example: Import only work items that are in the Done state.
    • Work Item Tags
      Specify the work item tags stored in TFS or VSTS. This field lets you filter what work items are imported as long as the items contain at least one specified tag.
  8. Click Create.
    The content source is saved and a list of the returned work items is displayed under the application in the left menu. These work items are now available to assign to tasks in phases to associate with the release.

Tasks

The TFS plug-in provides the following tasks:

  • Run Build
  • Create Work Item
  • Update Work Item
  • Wait for Approval

For more information about creating tasks, see How to design and create releases 

Values: To define a value, do one of the following actions (depending on availability):

  • To select from a list of possible values, type an at sign "@" in the field

  • To select from a list of built-in tokens (reusable placeholders that are used to create generic workflows), type a percent sign "%" in the field

  • Type free text

  • Enter a combination of free text and tokens

Run Build

The Run Build task lets you run TFS project builds in the context of Automic® Continuous Delivery Director phases and releases. This task requires the following information, which must match the corresponding TFS values:

Input Parameters

  • Project Name
    Specify the name of a TFS or VSTS team project.

  • Build Definition Name
    Specify the name of a TFS or VSTS build definition related to the specified project.

  • Ignore Warnings
    Determine whether warnings are suppressed at build level.
    Default: True

  • Agent Queue
    Specify the agent queue used by the specified build definition.

  • Branch
    Specify the version control branch used by the project.

  • Parameters
    Specify the parameters for a TFS or VSTS parametrized build to pass to the specified build configuration. Define the parameters in JSON format.
    Syntax: {“param1”:”value”, “param2”:”value” }

Output Parameters

  • Build Number
    Returns the ID of the build that was run.
  • Build Result
    Returns the status of the build that was run.
  • Source Version
    Returns a link to the change-set of the build.

Create Work Item

The Create Work Item task lets you create a work item and returns its ID for future use.

Input Parameters

  • Team Project
    Specify the name of the TFS or VSTS team project where you want to create the work item.

  • Work Item Type
    Specify the type of work item that you want to create.
    Note: (For VSTS) Enter a valid VSTS work item type. This field is case-sensitive.

  • Work Item Title
    Specify the name of the work item that you want to create.

  • Work Item Tags
    Specify the work item tags to be added to the work item that you want to create. Use simple text and separate multiple tags with commas.
    Example: tag1, tag2, ...

  • Additional Fields
    Specify one or more "field name":"value" pairs. You can update multiple fields using the following format: {"field1":"value1","field2":"value2"…}.  You can use this parameter for both standard and custom fields.
    Example: {"System.Description": "Follow the code samples from MSDN"}

Output Parameters

  • Work Item ID
    Specifies the ID of the newly created work item.

Update Work Item

The Update Work Item task lets you update an existing work item with customized fields.

Input Parameters

  • Work Item IDs
    Specify one or more IDs of work items to update. Separate multiple IDs with commas. 
    Note: The fields to update must be common to all work items you list here.

  • Fields to Update
    Specify one or more "field name":"value" pairs. You can update multiple fields using the following format: {"field1":"value1","field2":"value2"…}. You can use this parameter for both standard and custom fields. 
    Example: {"System.Description": "Follow the code samples from MSDN"}

Wait for Approval

The Wait for Approval task lets you determine that tasks are queued until the completion and approval of a specified work item.

Input Parameters

  • Work Item ID
    Specify the ID of a work item to be completed and approved before the next task starts.
    Note: (For VSTS) Enter a valid VSTS work item type. This field is case-sensitive.

  • Required State
    Specify the required state for the selected work item to reach before the next task starts.

  • Poll Interval
    Specify the length of time in seconds between system requests for the work item state.
    Default: 120 seconds
Was this helpful?

Please log in to post comments.