Related to issue Related to issue 29766: Retail Operations Buffer: store all transactions in operations table before processing
authorMartin Taal <martin.taal@openbravo.com>
Sun, 07 Jun 2015 17:26:57 +0200
changeset 26870 c57a5fc3eaf2
parent 26869 41fa0431e85a
child 26872 9939e14fd9fb
child 26880 326ba5d4ca99
Related to issue Related to issue 29766: Retail Operations Buffer: store all transactions in operations table before processing
Evict the import entry from the session to free mem asap
src/org/openbravo/service/importprocess/ImportEntryManager.java
--- a/src/org/openbravo/service/importprocess/ImportEntryManager.java	Sun Jun 07 13:09:55 2015 +0200
+++ b/src/org/openbravo/service/importprocess/ImportEntryManager.java	Sun Jun 07 17:26:57 2015 +0200
@@ -513,6 +513,8 @@
                     final ImportEntry entry = (ImportEntry) entries.get(0);
                     try {
                       manager.handleImportEntry(entry);
+                      // remove it from the internal cache to keep it small
+                      OBDal.getInstance().getSession().evict(entry);
                     } catch (Throwable t) {
                       // ImportEntryProcessors are custom implementations which can cause
                       // errors, so always catch them to prevent other import entries