Author: clebert.suconic(a)jboss.com
Date: 2010-07-22 17:07:01 -0400 (Thu, 22 Jul 2010)
New Revision: 9458
Modified:
trunk/src/main/org/hornetq/core/paging/impl/PagingStoreImpl.java
Log:
A little tweak to release internal memory as soon as we're done with reading the
messages
Modified: trunk/src/main/org/hornetq/core/paging/impl/PagingStoreImpl.java
===================================================================
--- trunk/src/main/org/hornetq/core/paging/impl/PagingStoreImpl.java 2010-07-22 13:18:50
UTC (rev 9457)
+++ trunk/src/main/org/hornetq/core/paging/impl/PagingStoreImpl.java 2010-07-22 21:07:01
UTC (rev 9458)
@@ -616,7 +616,22 @@
page.open();
- List<PagedMessage> messages = page.read();
+ List<PagedMessage> messages = null;
+
+ try
+ {
+ messages = page.read();
+ }
+ finally
+ {
+ try
+ {
+ page.close();
+ }
+ catch (Throwable ignored)
+ {
+ }
+ }
if (onDepage(page.getPageId(), storeName, messages))
{
Show replies by date