Introduction


The purpose of this article is to provide a starting point so that you can set up Jira integration to fit the needs of your organization. The integration will enable you to connect an item in SystemWeaver with an issue in Jira by putting an attribute on the Jira Issue which contains the id, the URL, of the SystemWeaver item. Once implemented, when you select an item in SystemWeaver, you can query Jira for all issues connected to this item. The extension also shows how to create a new issue pointing back to the selected item. This is done through a SystemWeaver extension, which uses the Jira REST API. This article covers the following:

  • Setting Up Jira
  • Configuring the Extension
  • Running the Extension


For a video demonstrating this extension, see Jira integration video.


Setting Up Jira


This section explains how to setup Jira to work with this extension. You need a Jira project and a Jira issue type. If you do not have a project, we recommend that you create a project of type Basic software development.



Give the project a Name:



Remember the Key above since it is needed to configure the extension to find the project.


Next, whether you have an existing project or you created one as described above, you need to store the links between the Jira issues and SystemWeaver items. This is done through a Jira custom field. You need to create a custom field of type Text Field (single line):



After creating the field, you have to figure out the Jira id of the field. This id is needed to correctly configure the extension later on. The id looks something like customfield_0100200.


A simple way to contruct this id is to: 

  1. Go to Administration/Custom Fields.
  2. Click on the "Configure" link for the custom field you're interested in.
  3. In the URL of the Configure Custom Field page, note the number after "customFieldId=" and append it to "customfield_" to build the custom field ID.

So, if the URL says customFieldID=01000123, then the id will be customfield_01000123.


Configuring the Extension


For the extension to work, you have to configure it for your Jira installation. In order to do this, you must have the SystemWeaver Architect role. Log in and to to File > Configure the explorer.




You have to find the view Jira in the list and activate the view.



Next, you need to edit the xml configuration which looks like this:


<JiraConfiguration>
  <BaseUrl>http://jiraserver:8085</BaseUrl>
  <MainProject>ESP</MainProject>
  <CustomField>customfield_0100200</CustomField>
  <ItemType>RQ</ItemType>
  <IssueType>Bug</IssueType>
</JiraConfiguration>



BaseURL


This is the location of the JiraServer:


Example:  http://localhost:8080.


MainProject


The Jira Project Key:



CustomField


Formal name of the Text Field as mentioned above used by the JIRA Rest API.


Example: customfield_0100200


This can be found as mentioned above.


ItemType


This is the SystemWeaver SID of the item-type that you wish this extension to be activated by.


Running the Extensions


Build and make sure that the extension resides in the swExplorerExtension folder and run swExplorer.exe, as described in the GitHub documentation. 


Select an item of the type specified by the ItemType SID above and the view should activate and be visible in the toolbar.


For the view to start showing anything, you have to click the Login button. Enter the credentials for the Jira Server. The Login will be stored for the length of the swExplorer session and will have to be reentered when restarting the swExplorer.