All,
I've encoutered a java heap space issue while using
Query q = null;
[...] //create an org.apache.lucene.search.Query
FullTextSession fullTextSession = Search.createFullTextSession(session);
FullTextQuery ftq = fullTextSession.createFullTextQuery(q, entityClass);
ftq.setSort(new Sort(new SortField(CatalogItem.ATTR_ID, SortField.STRING)));
scrollableResults = ftq.scroll(ScrollMode.FORWARD_ONLY); //WIth BIG AMOUNT of results thi will CRASH
scrollableResults.beforeFirst();
F.i., this target a database table with an average of 700.000 tuples, which are indexed in lucene through the Hibernate Search fw. Data aren't stored in lucene stuffs (only database maintains the data set).
Isn't a way to scroll a result set without keeping all in-memory ? Is this possible with a Sort constraint ?
Thanks
|