This section describes the steps necessary to configure the Perforce connector so Perforce jobs can be synced with Jira issues.

Note

This page applies to other application besides Jira, eg, the connector can be used with QC, Doors, etc.


The following image illustrates the usecase for the Perforce adapter. 

                       

  1. Jira user will create a new defect.
  2. ConnectALL will automatically create a new Perforce job with the name of the issue key, eg, DEV-321.

                 

  3. As fields in the Perforce job are edited, the related Jira issue's fields will be modified.
  4. As fields in the Jira issue are edited, the related Perforce job fields will be modified.
  5. Any changelists that are attached to the Perforce job will be displayed in a Jira custom field.

                 

 

Note the red rectangle above is a file that was checked in with changelist #3. The file name is also a link to the compare page using the p4 web application.

           


A ConnectALL query can be used to further limit the jobs that will be scanned for changes. For a very large Perforce installation, this improves the scanning times (and scanning overhead). For example, a query like "fast|quick" //depot/proj/..." will limit the scan to jobs that contain the words fast, or quick in any job field, and files that are linked to files in the depot/proj path.

See "http://www.perforce.com/perforce/r14.2/manuals/cmdref/p4_jobs.html" for more information.

Note the default behavior in Perforce is to close the job when a changelist is attached. If the Perforce status is linked to the Jira status, this will also close the Jira issue. This behavior can be changed by a Perforce administrator as described here.

Step-by-step guide

  1. To complete these steps a Jira project admin or Jira admin login is needed. Also, a Perforce login must be know which has open and list permission in at least one file in the repository.
  2. Create a new application in the ConnectALL GUI, selecting the Jira icon and the Perforce icon, giving the automation a unique name.
  3. In the next page, enter the authentication credentials for Jira and Perforce.

                
    1. The URL for Perforce will be p4java, or p4javassl (if a ssl connection is required for your Perforce).

  4. The next page is the Entity Mapping screen. On this screen, the p4 web URL can be set if desired.
  5. The last screen is the Field Mapping. Remember to map the Perforce "Job" field to a Jira custom field. This is to display the changelists and checked files.
    1. The Jira custom field can be rendered as text, wiki markup, or HTML.
    2. The attachment markup type in the advanced properties tab is set to choose the desired rendering of the changelist.
    3. Be sure the Jira custom field is also set to the correct render (default, wiki, or html) in the Jira field configuration scheme. Contact your Jira administrator for setting the proper field renderer.

Changelist Rendering in Jira

Perforce changelist can also be rendered in the Jira issue tab panel as shown below.

                     

Note: It requires you to install the Jira Source Control plugin for ConnectALL. Refer ConnectALL Jira Plugin for more details.

Step-1: We need to map Perforce ChangeList field to a custom field in Jira. 

                   

Step-2: This Jira custom field has to be configured in the Jira Source control plugin configuration page to enable issue tab panel rendering.

                   

Time Difference Configuration

To know how to calculate the time difference, and configure it in the ConnectALL UI,  read the topic Time Difference Configuration.