Forums

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

Best method to update 4,00,000 issues in Jira

Rupa Jain July 24, 2020

Hi,

Need to update Custom Fields for 4,00,000 issues/tickets in Jira.

What would be the best approach for doing this keeping in mind speed and Jira performance?

1) Jira REST API

2) CSV Import

3) Jira database update query

4) Plugin like ScriptRunner or CLI etc.

 

Thanks,

Rupa

3 answers

0 votes
Gonchik Tsymzhitov
Community Champion
July 27, 2020

@Rupa Jain  Please, provide more details. 

  • Of course, fastest way is DB query. (here be aware what exactly do you want to achieve) and restart system.
  • The next one is Java way (Groovy. Jython, or your App on Java,Kotlin etc) which on next layer. 
  • Simplest way CSV - too risky. 
  • The lowest way is REST API, until if you will not use multithreading.

To be honest each way has pros/cons. But without details it's tellins fortunes by coffee grounds

Sunny Ape
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.
July 27, 2020

Why do you say using CSV is 'too risky'? Risky in what way?

Gonchik Tsymzhitov
Community Champion
July 27, 2020

@Sunny Ape Because I have seen many masters who forgets to double check the process on test instance especially encodings/delimeters/characters/formats, after I made fixing as  consultancy work and restore from backup. 

But it's simple way.

https://confluence.atlassian.com/adminjiracloud/importing-data-from-csv-776636762.html

Rupa Jain July 27, 2020

Hi @Gonchik Tsymzhitov ,

Here is some more info:

  • These issues belong to different projects in Jira.
  • We need to add 6-7 new Custom fields to all Jira projects and as part of history data these Custom fields need to be populated for older 4,00,000 issues.
  • All Custom fields to be updated are text fields.
  • Also, preference is that users do not get notified of the change.
Like Gonchik Tsymzhitov likes this
Gonchik Tsymzhitov
Community Champion
July 27, 2020

Hi @Rupa Jain , 

based on your proposed info. 

I will do it via groovy. because I can update without updates, notifications. 

And next one, you did not mention to the timeline and milestone, hence it's easy to make project by project

Rupa Jain July 27, 2020

Would actually want to complete it within a day (over a weekend) and for all projects in one go.

0 votes
Sunny Ape
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.
July 24, 2020

CSV import uses the REST API, so they're really one and the same thing.

  1. Export all the issue IDs to CSV files in batches of, say 20,000 issues
  2. Add the custom field value you want to change
  3. Import the CSV files, one at a time, during an off-peak period

Simple and free :)

0 votes
Michael Kuhl {Appfire}
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.
July 24, 2020

Hi Rupa - You can do this with the Bob Swift Jira CLI in one command.

Here's a how to article for exactly this use case: Set field value for issues in bulk using Jira Command Line Interface (CLI) in Jira.

 

FYI - I'm the product manager for the Bob Swift CLI.

Rupa Jain July 25, 2020

Hi Michael,

Will it be possible to trigger update to 4,00,000 issues in one go/one input file or will I have to break it into batches?

Also, will it have any impact on Jira's performance?

And approximately how long will it take with this plugin po make such an update (say 5-6 Custom fields to be updated).

Thanks,

Rupa

Michael Kuhl {Appfire}
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.
July 27, 2020

You can do it in one go.  The performance impact will depend on your Jira configuration.  That also goes for how long it will take: The CLI will execute as quickly as the Jira instance processes the request.

Suggest an answer

Log in or Sign up to answer