Child pages
  • JIRA FishEye Plugin 3.0.17 - Perforce Job Integration
Skip to end of metadata
Go to start of metadata

This document contains simple instructions for integrating Atlassian JIRA, Atlassian FishEye and Perforce. For a more detailed description of the plugin's features (including Crucible integration) check out the JIRA FishEye Plugin space:

http://confluence.atlassian.com/display/JIRAEXT/FishEye+for+JIRA

Download and install the applications (if you haven't already)

All applications must be running when you set up the integration.

The JIRA FishEye Plugin can connect to any Perforce server on the network, but requires you to have a copy of the P4 executable installed on the same server as JIRA.

Install the plugin (if required)

Follow the installation guide, then return to this page.

(info) You will need to create a project in JIRA (if you haven't already done so).

Integrate JIRA with FishEye

You may skip this step if you were already using the FishEye plugin. Your existing configuration should will have been copied over automatically.

  1. In JIRA, navigate to Administration -> FishEye Configuration:
    1. Press Setup FishEye
    2. In the FishEye URL enter the of your FishEye instance and press Update
    3. enter the key of the Project you wish to map to the FishEye repository, then press 'Update'.

Your JIRA instance is now connected to FishEye.

Integrate JIRA with Perforce

If you previously had the Perforce plugin installed, all of your custom fields and job-related workflows will be upgraded automatically. However, you will need to configure your connection to Perforce.

  1. Map your JIRA Issues to your Perforce Job Specification:
    • If you don't mind updating your job specification, import perforce-plugin.jobspec (provided in the plugin distribution) into Perforce using the p4 jobspec command.
    • If you have a custom jobspec that you want to keep, follow the instructions for Mapping Custom Fields.
  2. In JIRA 6.0 or earlier, navigate to Administration -> FishEye Configuration:
    1. press Edit Primary Configuration
    2. in the Perforce section, set Enable Perforce Integration to Yes
    3. Configure the settings for your Perforce instance:
  3. In JIRA 6.1 or later, navigate to Administration -> Perforce Job Integration
    1. Click Enable Perforce Job Integration
    2. Configure the settings for your Perforce instance:

To authenticate with Perforce, you will need to specify either:

  • P4USER and P4PASSWD; or
  • P4USER and a valid ticket file

The user must have read and write permissions in Perforce.

Administration settings 

Variable

Description

Example

Notes on variables

P4 Executable

Full path to the P4 executable.

The Perforce executable must not be located in the JIRA-HOME folder. It also cannot be located in the JIRA attachments or plugins folders.

/usr/bin/p4 or C:\Program Files\Perforce\p4.exe

Because the Perforce executable property can be set to anything, it is a security vulnerability if the administrator's account becomes compromised. To mitigate this risk, the Perforce executables are whitelisted to allow p4.exe and p4 only. This whitelist can be changed by setting the p4.executable.allowed.pattern property in the perforce-jira-plugin.properties file. This properties file is stored inside the JIRA FishEye Plugin .JAR.

Because network paths such as:

\\JIMSCOMPUTER\ 

on Windows can become a security vulnerability, by default this functionality is disallowed in the JIRA FishEye plugin. This setting can be toggled by setting the p4.executable.allow.network.share.path property in the perforce-jira-plugin.properties file. This properties file is stored inside the JIRA FishEye Plugin .JAR.

P4PORT

The P4PORT to connect to, includes the hostname.

localhost:1666

 

P4CLIENT

The P4CLIENT to use.

 

 

P4USER

The P4USER to run as (must have read and write permissions)

 

 

P4PASSWD

The P4PASSWD to use for the P4USER, if one has been set.

 

 

Ticket file

The P4TICKETS file, see Ticket-Based Authentication info below.

 

Ticket-Based Authentication

Overrides any value in P4PASSWD
To enable Ticket-Based authentication, use the Ticket File property to specify the name of the file to which p4 tickets are stored (as defined in the P4TICKETS environment variable). If the file is on the classpath, you can just specify the filename. Alternatively you may specify the full path to the file. The plugin will retrieve the ticket number associated with the user as specified in P4USER. The user must have already logged into the Perforce server with the 'p4 login' command.

P4CHARSET

(Optional) If specified, this will set the P4CHARSET parameter for all perforce calls made by JIRA.

 

 

View Job Link

(Optional) A link template specifying a P4WEB/P4DB server to link jobs to.

 

 

Log Level

The granularity of Perforce related log entries.

 

 

System Root

(Windows Servers only) Your Windows install folder.

C:\Windows

 

System Drive

(Windows Servers only) Your system drive.

C:

 

    1. If you have elected not to use the provided JIRA Perforce jobspec, you will need to check the box marked Skip Connection Test and then press the Map Custom Fields link to map your JIRA issue schema to your Perforce jobspec.
    2. press Update

Since Version 2.3 of the plugin, it is possible to configure multiple Perforce depots and map them to different JIRA projects.

View Job Link formats

For P4Web:

 http://localhost:5050/@md\=c@[JOBNAME]ac\=111 

or P4DB:

 http://localhost:5500/p4db/jobView.cgi?JOB=[JOBNAME] 

Alternatively, browse to a job in your preferred viewer and copy the URL. Replace the job name with the token [JOBNAME] as in the above examples and paste it into the View Job Link field.

Integrate FishEye with Perforce

Outside the scope of this doc, see: http://confluence.atlassian.com/display/FISHEYE/Perforce

Create a workspace / depot in Perforce

Outside the scope of this doc, see: http://www.perforce.com/perforce/doc.973/cmdguide/html/quicksta.htm

Add the Perforce Job custom field and Test it all works

  1. Add a Perforce Job custom field to JIRA
    1. Go to Administration -> Custom Fields -> Add Custom Field
    2. Select Job Checkbox and press Next
    3. Enter a Field Name and press Finish
  2. Create a new JIRA Issue and select Yes for the Create Perforce job field.

If the above installation and configuration has been successful, you should see a P4 Job field in the upper section of the View Issue screen. If you have configured a View Job Link you should be able to click through to your P4WEB or P4DB server from the P4 Job field.

You should also see a Source issue tab panel. This replaces the old P4 Changes and P4 Job panels from the JIRA Perforce Plugin. Any Perforce commits referencing the issue/job key will show up under this tab.

Creating Jobs for ALL issues in a project

Another method of creating jobs (without the need to configure custom fields) is to set the Always create jobs for issues in this project flag in the project-level Perforce administration screen.

This document is a quick setup guide. For a full explanation of the JIRA FishEye Plugin's features and functionality, check out the following links:

Bugs, Feature Requests & Improvements?

If you've found a bug in the JIRA FishEye plugin or would like to request a new feature or improvement - please raise an issue in the JIRA FishEye Plugin project.

  • No labels