REST API for reindex -/rest/api/2/reindex/request/{requestId} - How to get the request id

Debabrata Sahu August 1, 2017

Where does JIRA stores all the task id related to reindexing both Project level and application level

1 answer

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 1, 2017

In memory, as there's no use for the request id's outside the running process.

Debabrata Sahu August 1, 2017

Thanks Nic,

Then for running above api, how can i get the requestId.

 

Debabrata Sahu August 1, 2017

Our requirement is, if we want to check all the Project Index activities going on currently. Then can we do that.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 1, 2017

I'm guessing you have not managed to find the documentation as you're asking this.  

Check the descriptions of the available calls in https://docs.atlassian.com/jira/REST/server/#api/2/reindex

Debabrata Sahu August 1, 2017

Hi Nic,

 

Thanks i have seen these api's, by the problem is non of them is telling me the progress of Project Reindex task.

 

For GET /rest/api/2/reindex/request/{requestId}

What shoud be the request id, from where can i get it

 

For api/2/reindex/request 

its not showing me the details of on going project reindexing

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 1, 2017

Please, read the documentation, it clearly states how to get the ids and return a progress report.

Debabrata Sahu August 2, 2017

I am sorry, i couldn't find how to get request id in below link https://docs.atlassian.com/jira/REST/server/#api/2/reindex Also i suspect these API is giving information on application level reindex. If i triger a BACKGROUND reindex and hit api/2/reindex/progress with the task id provided in URL, then only I get response. But if same is being done with Project Reindex, then no response.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 2, 2017

Hmm.  I get told about project indexing when I run it.

Debabrata Sahu August 2, 2017

Hi Nick,

Can you please help by being more elaborative. What exactly you tried. 

Did you get the details about Project Reindex by  api/2/reindex/progres and passing the task id given in the url 

secure/project/IndexProjectProgress.jspa?pid=xxxxx&taskId=25329

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 2, 2017

No, the list of currently running index processes returned by the REST call for the list contains the id of any index process currently running.

Debabrata Sahu August 2, 2017

I already checked that and that is what  i am trying to point out, in my case if i triger a Project Reindex and immediatly hit this REST API, i am not getting any id. 

Thomas Strohmaier July 25, 2018
  • When I trigger an re-index by api, I get the id back and can search for it.
  • triggering a re-index in the browser by system->re-index or project->re-index, I can guess the task-id form the browser-URI. If the browser is closed, the id is gone.
  • If I want to find out whether someone else in the system has started an re-index either for an project or the complete system, I am list.

So how can i find out whether there is an re-index running started by anyone in the system?

Like Justin Isler likes this

Suggest an answer

Log in or Sign up to answer