> If you don't mind accessing the underlying implementation classes, you > can use the flush() method of the underlying SearchIndex > implementation to ensure that all pending indexing tasks have been > completed. See the o.a.j.core.query.lucene.IndexingQueueTest class in > jackrabbit-core for an example of how this works.
I do now flush the SearchIndex and that helps! It was not very easy to do that - had to use some reflection tricks because I do not get the SearchIndex over a "public" API because the getQueryHandler method of QueryManagerImpl is protected - but it works now! Thx very much for your help! BR, Sascha -----Ursprüngliche Nachricht----- Von: Jukka Zitting [mailto:[email protected]] Gesendet: Mittwoch, 26. Oktober 2011 19:22 An: [email protected] Betreff: Re: AW: How do I get the total size of nodes/rows from a QueryResult Hi, On Wed, Oct 26, 2011 at 9:22 AM, <[email protected]> wrote: > I could now implement a delay in my tests but the best solution would be to > wait until the XMLTextExtractor job is finished. Is there a possibility to do > that or am I completely wrong with my suggestion? If you don't mind accessing the underlying implementation classes, you can use the flush() method of the underlying SearchIndex implementation to ensure that all pending indexing tasks have been completed. See the o.a.j.core.query.lucene.IndexingQueueTest class in jackrabbit-core for an example of how this works. BR, Jukka Zitting
