Hey all,
I've set up a chunking request for my JPA objects but it seems to not be clearing the old chunks and I am running out of heap space.
The way it works is I request a page size of 2k using
selectQuery.setFirstResult(currentPage * DEFAULT_PAGE_SIZE);
selectQuery.setMaxResults(DEFAULT_PAGE_SIZE);
with the current page being the chunk we want, and the page size being 2k
But around page 45 I run out of heap memory in my java VM.
and i'm doing the normal clear functions
selectQuery = null;
this.entityManager.clear();
this.entityManager.close();
this.entityManager = null;
this.entityManager = Persistence.createEntityManagerFactory("ASDFS").createEntityManager();
Anyone know any other way to clear the EntityManager's data?
[Message sent by forum member 'brianpeck' (brianpeck)]
http://forums.java.net/jive/thread.jspa?messageID=249612