'Tis the season to be spooky! Read our new blog, How Spooky is Your City? Mapping and Predicting Scary Stuff. In it, @SusanCS provides a fun glimpse into using data to figure out the creepy quotient of where you live! And don't forget to check out our Digital Costume Thread to get yourself in the mood for a candy binge!
JIRA Connector (Macro)
Public Gallery Link: https://gallery.alteryx.com/#!app/JIRA-Connector/58d87c2feffc2a0dd0b5ed8f
I've published a JIRA Connector to the public gallery and hope it will be useful for those using JIRA that are looking for a way to quickly download issues for their JIRA projects. It's pretty straightforward, but here's a preview and quick guide:
30 Second Preview:
Installation & Configuration
Download and import to your Macros folder
As long as your macro folder has been mapped (Options -> User Settings -> Edit User Settings -> Macros), you should find the JIRA Connector tool in the Connectors category on the tool palette the next time you open Alteryx.
3 Tabs: Site & Login, Project & Issues, Fields
Site & Login
Enter the URL for your JIRA site along with your username and password. Email logins will work, but your actual username is preferable because it enables the "Only My Issues" option to work (next tab).
Project & Issues
You'll need to run the workflow at least once with the "Refresh Project List" option selected before being able to use the "Download Issues" option. This loads a list of available JIRA projects that will show in the dropdown under the Download Issues option on subsequent runs.
Once an available project list has loaded, you can select a project to download issues from. You'll also notice some options for filtering issues that belong to yourself or another specific assignee. You can also paginate through large result sets in 1,000 record increments.
Lastly, select one of three options for returned fields and parsing methods.
Summary (S) - a brief summary of the results (record counts, etc.)
Raw JSON (J) - direct JSON response from the JIRA REST API
Parsed Results (P) - the parsed results
That's it! Once again, I hope this will be useful and look forward to getting some decent feedback. I've only been able to test this on our company's [cloud hosted] JIRA projects and honestly have no idea if it will work for private server hosted JIRA environments.
Please feel free to leave feedback and/or report any runtime errors below. I'll do my best to publish new versions to the gallery with essential fixes.
I love this macro - thank you for creating and posting it!
I do have a question. Is there a way to boost the results past 1000, or is this a function of the API? My company is using JIRA heavily to manage large projects and single projects have over 1k tickets presently, so I'm limited in my output. Is this adjustable?
One piece of possible feedback for the future: under Project Issues, "Only My Issues" returns just those assigned to me. It would be helpful if this could also return those that I created, or am watching.
Thank you! I really appreciate it.
Thanks for the kudos, I'm glad you like the connector! Also, the feedback is much appreciated as I was hoping for ideas for improvement, etc.
I've published Version 3, which features a couple of minor enhancements that address the question and suggestion that you made.
"Is there a way to boost the results past 1000, or is this a function of the API?"
- The JIRA API record limits will vary based on an installation's config property setting. For cloud instances, I don't believe this can be changed without opening a JIRA service ticket. Our company's cloud instance, for example, limits # of results to 1,000 for the API endpoint being used in the connector (/rest/api/latest/search). However, I upped the limit in the connector to 5,000 in the chance that an install allows more. Lastly, check out the example for pagination (bottom) - this will help in understanding how you can pull the remaining issues if you have more than 1,000 (or whatever your limit may be).
"One piece of possible feedback for the future: under Project Issues, "Only My Issues" returns just those assigned to me. It would be helpful if this could also return those that I created, or am watching."
- I added 2 options under "Only My Issues". One which returns those assigned to you, and one which returns those reported by you. I'm not sure yet how to query those that you're watching...
I'm not yet sure how to execute "OR" statements in a POST array via JQL - so here's how you could get a list of any issues that are either assigned to you OR reported by you.
Hope this helps!
Thanks Taylor for sharing the connector.
I am currently implementing a worfklow to extract JIRA data. In our current environment, the workflow will return a 302 code, so the project list will not refresh and error out. One possible solution is to open the Jira Connector macro and change the Message tool (the one after the download tool) within the Get Projects, Standard - Formatted, and Kitchen Sink or Standard Raw containers (after enabling it) from:
Message Type: Error - And Stop Passing Records Through This Tool
Message Type: Warning
This will allow the workflow to continue processing and ignore the 302 error code and refresh the project list.
Thanks again for the connector!
Another pagination solution would be something like the following:
Use the JIRA Connector to get the limit and total issues --> Auto Field --> Generate Rows (see settings on screenshot) --> formula to fix initialization row --> Next JIRA Macro to overwrite the "Limit" and "Starting With" values. Add the Unique ID tool as a safety measure (Pending).
I'm actually thinking about integrating this within the Jira Connector itself....
For instance, using similar logic, I would add an optional input to the JIRA Connector that would take a "Next Call" field. The "Summary" output from the connector would include this "Next Call" field with a pre-compiled call (JSON array) that would be used for the next call to the JIRA API. This would allow the user to simply chain the JIRA Connectors together using the summary outputs to (optional) inputs and union each of the "Parsed" outputs.
Another idea would include doing this within a JIRA "Paginator" Macro - which would simply be an iterative macro that executes the aforementioned logic until all calls have been made - or even let the user specify the number of subsequent pages to load. The beauty of this is limiting the number of tools required to pull data to 2...
However, in the spirit of minimizing work and canvas space utilization, I'll probably move the Paginator macro into the connector itself also, while providing the options in the macro interface for the number of pages (or all) to return. And viola! One tool, all results!
Thanks for the insight. I am not sure that I followed the chained approach implementation. It would be nice to have the one tool / all results solution though.
The all results would be good to have to provide an initial load. To keep things in sync, it would be useful to include date filters, so the user can specify the date range and provide change data capture capabilities. For example, similar to the assignee comment above include "updated >%3D -1d" to the filter URL, so only updated issues for the last day would be part of the result set. This would reduce the volume of data and allow the user to process the updates/new issues.