Fastest way to reindex changes from a plugin

29 views
Skip to first unread message

WekTorALL

unread,
Aug 8, 2016, 9:59:41 AM8/8/16
to Repo and Gerrit Discussion
Hi,

I am searching for a solution to delete project changes from index without calling Gerrit API for each change. Currently I am using a plugin that should send a POST request to https://localhost/a/changes/CHANGE_ID/index for each change, but this is a very slow process if we have more changes in a project (I've found this solution here: https://groups.google.com/forum/?hl=en#!searchin/repo-discuss/plugin$20reindex|sort:relevance/repo-discuss/hdBTxTp_nRU/_DnnycFjAAAJ )... Is there any way to do the same thing directly from the plugin?

Thank's

Edwin Kempin

unread,
Aug 8, 2016, 10:21:53 AM8/8/16
to WekTorALL, Repo and Gerrit Discussion
On Mon, Aug 8, 2016 at 3:59 PM, WekTorALL <wekt...@gmail.com> wrote:
Hi,

I am searching for a solution to delete project changes from index without calling Gerrit API for each change. Currently I am using a plugin that should send a POST request to https://localhost/a/changes/CHANGE_ID/index for each change, but this is a very slow process if we have more changes in a project (I've found this solution here: https://groups.google.com/forum/?hl=en#!searchin/repo-discuss/plugin$20reindex|sort:relevance/repo-discuss/hdBTxTp_nRU/_DnnycFjAAAJ )... Is there any way to do the same thing directly from the plugin?
On server-side your plugin can get com.google.gerrit.server.index.change.ChangeIndexer injected and use it to index changes.
 

Thank's

--
--
To unsubscribe, email repo-discuss+unsubscribe@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


WekTorALL

unread,
Aug 9, 2016, 9:49:29 AM8/9/16
to Repo and Gerrit Discussion, wekt...@gmail.com
Thank's Edwin, it works!


On Monday, August 8, 2016 at 5:21:53 PM UTC+3, Edwin Kempin wrote:
On Mon, Aug 8, 2016 at 3:59 PM, WekTorALL <wekt...@gmail.com> wrote:
Hi,

I am searching for a solution to delete project changes from index without calling Gerrit API for each change. Currently I am using a plugin that should send a POST request to https://localhost/a/changes/CHANGE_ID/index for each change, but this is a very slow process if we have more changes in a project (I've found this solution here: https://groups.google.com/forum/?hl=en#!searchin/repo-discuss/plugin$20reindex|sort:relevance/repo-discuss/hdBTxTp_nRU/_DnnycFjAAAJ )... Is there any way to do the same thing directly from the plugin?
On server-side your plugin can get com.google.gerrit.server.index.change.ChangeIndexer injected and use it to index changes.
 

Thank's

--
--
To unsubscribe, email repo-discuss...@googlegroups.com

More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages