Wednesday, August 23, 2006 12:26 PM
My code looks like :
TopFieldDocs tfd = indexSearcher.search(query, filter, records, sort);
for (int i=0; i
Document doc = indexSearcher.doc(tfd.scoreDocs[i].doc);
Now the problem is, there is only one instance of indexSearcher in application and many threads are using the same instance to search the index. Now if two different searches have the results and both are calling indexSearcher.doc(int) method to get the document, will it be thread-safe?