Java.lang.IllegalArgumentException: Too many documents, composite IndexReaders cannot exceed 2147483647


(lzw) #1

Hello everybody,
I was using lucene 4.6 to create document index, my document has 2737197463 documents in 39G, I was used in SearcherManager to search index,but throw IllegalArgumentException.

Exception in thread "main" java.lang.IllegalArgumentException: Too many documents, composite IndexReaders cannot exceed 2147483647
at org.apache.lucene.index.BaseCompositeReader.(BaseCompositeReader.java:77)
at org.apache.lucene.index.DirectoryReader.(DirectoryReader.java:368)
at org.apache.lucene.index.StandardDirectoryReader.(StandardDirectoryReader.java:42)
at org.apache.lucene.index.StandardDirectoryReader$1.doBody(StandardDirectoryReader.java:72)
at org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:843)
at org.apache.lucene.index.StandardDirectoryReader.open(StandardDirectoryReader.java:52)
at org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:66)
at org.apache.lucene.search.SearcherManager.(SearcherManager.java:106)
at com.ctfo.lucene.core.LucSreachCore.(LucSreachCore.java:69)
at com.ctfo.lucene.LucCenter.run(LucCenter.java:93)
at com.ctfo.lucene.LucCenter.main(LucCenter.java:42)

I want to know how fix and set max docment for search index ?


(lzw) #2

pls everyone help me


(system) #3