Skip Indexing During bootRun initiate them after server is started

22 views Asked by At

I am facing time out error on cloud when deploying my java-groovy service. I am using hibernate elastic search due to which the indexing starts itself when I bootRun the app. which takes a couple of hour to start. I want to skip this heavy process while bootRun and start it once server starts.

I tried update config value to index_schema_management_strategy: none

Also I am not sure from where the indexing queries are initiate from code.

I tried update config value to index_schema_management_strategy: none, still indexing happens on bootRun.

2

There are 2 answers

1
yrodiere On

Hibernate Search most certainly doesn't trigger mass indexing on boot.

Either you're using an additional framework that triggers mass indexing on boot (though I don't know any), or you have code in your application that does so.

Also I am not sure from where the indexing queries are initiate from code.

Look for the string massIndex in your code.

See also https://docs.jboss.org/hibernate/stable/search/reference/en-US/html_single/#search-batchindex-massindexer

0
NITHYA T On

If you can't find massIndex in your code then you are not using massIndexing for indexing. Can you search for 'startAndWait' to find where you are calling the indexing in your application. Once you found the function you can create a Scheduled Job rater than calling it on start of the application