Hi all, I'm trying to check that an import using the dataImportHandler was clean before I take a snapshot of the index to be pulled via snappuller to query nodes. One of the checks I do is verify that a certain minimum number of documents are returned for a query. I do this in a script that I'm calling via the postOptimize hook. However, after a full import the numFound results from the query are not accurate until after the postOptimize code completes and so my checks are failing.
Glancing at the code this looks non-trivial to "fix" as the hook call is pretty deep in the call stack. org.apache.solr.handler.dataimport.DataImporter.doFullImport execute eventually calls org.apache.solr.update.UpdateHandler.callPostOptimizeCallbacks One option would be to spawn and background a new job to check the status with an initial sleep to wait for the postOptimize that spawned it to finish. This is pretty ugly and could lead to some race conditions but will probably work. Any better recommendations on how to acheive this functionality? Thanks...Tom