Wednesday, 30 October 2013

Export JIRA Data Using Pentaho DI

JIRA tool is very useful when organizing development process. Although there are lots of information available in the application and lots of plugins which give different views, sometimes there is a need for extracting data from JIRA database. It is normal for the JIRA server to hide its database and forbid direct access to it though. Most of the times there is web interface used for accessing particular JIRA data.

There are lots of tools and development libraries available for accessing this web interface also. What I'm providing is a useful plugin for those who use Pentaho Data Integration. This plugin is a simple step to connect remote JIRA instance, and fetch some data into the transformation using simple JQL (JIRA Query Language) expressions. All the data input can be then processed in different ways into the PDI transformations or jobs.

You can get trial JIRA version here, and you can download absolutely free of charge Pentaho DI from here.

Plugin Installation

PDI Jira Plugin can be downloaded from here.
After downloading the zipped package, you have to just unzip it in the PDI steps folders:

${pdi.home}/plugins/steps

Where ${pdi.home} is the folder where PDI is installed. That is all you need. Then start the PDI Spoon GUI.

PDI Jira Quick Start

Start a new transformation with Spoon. Then add 'Jira Plugin' from the 'Input' category.

After double clicking the Jira Plugin step you'll be able to edit remote Jira instance connection properties:
On connection tab there is also a 'Test Connection' button which can be used for testing connection to remote instance.

On JQL tab you'll be able to edit Jira Query Language statement which will be used to obtain data from remote Jira server.
Data from the Jira instance is provided to the next step in the transformation as JSON string which has field named as specified in 'Output field name'.

For the moment you can use available JSON Input plugin in Pentaho DI to extract required data from the JSON text. JSON Input plugin uses JSON Path which is much like XPath query language. For instance to extract issue key, issue status and summary you can configure following JSON Path statements:













No comments:

Post a Comment