Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to remove unnecessary boards automatically in JIRA?

Pradeep Yadav
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 12, 2021

Need to delete JIRA boards automatically , when for particular Issue type All issues were Resolved AND last change was 3 months ago

2 answers

1 vote
Radek Dostál
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 13, 2021

If you have any plugin which provides you a groovy console, then you can make use of Jira Agile API to get all the boards on the instance, for each, get the filter query, for each query, do a jql search to find out how many issues it returns (or modify the query to your parameters, etc.), and depending on that, you can decide whether you want to remove the board or not.

Without groovy, you'd need to join a few tables in the db to get the boards and their filters, then you would probably need to use REST to check the query search issue count, and then you could use REST (or have to craft an http form, skipping atl. token check) to remove them.

I don't know if there is a plugin but I've had a similar idea before to clean up the filters/dashboards as well.

 

Overall, I'd be very, very cautious before you run the remove/delete part. You could have missing or corrupted indexes causing your jql search count return 0 at all times, you could have invalid jql to begin with (i.e. it still returns issues in the board but if you use it in search it'll error, weird right?), someone could be actively modifying the filter, etc., I don't think that you really want to fully automate this. Do some statistics over time, like maybe "each week this board returns 0 issues" and "these boards have had issues shown sometime in the past 3 weeks so they are good to stay". Automating this is dangerous.

0 votes
Ashu Tyagi
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 12, 2021

I Personally don't think it is possible unless you use some external jira plugin to do that.

Would be curious to see if someone has achieved it already

Suggest an answer

Log in or Sign up to answer