-
Bug
-
Resolution: Done
-
Major
-
4.0.0.Final, 4.1.0.Final, 4.2.0.BETA1
-
None
-
None
org.infinispan.notifications.AbstractListenerImpl.listenersMap has a org.infinispan.notifications.cachemanagerlistener.annotation.ViewChanged that is
always increasing number of entries (per deploy/undeploy with AS)
[0]org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.target = org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup
[1]org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.target = org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup
[2]org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.target = org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup
[3]org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.target = org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup
[4]org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.target = org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup
[N]org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.target = org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup
keeps increasing until we run out of memory
Looks like we miss removing these because:
org.infinispan.notifications.AbstractListenerImpl.removeListenerInvocation
private void removeListenerInvocation(Class<? extends Annotation> annotation, Object listener) {
if (listener == null) return;
List<ListenerInvocation> l = getListenerCollectionForAnnotation(annotation);
Set<Object> markedForRemoval = new HashSet<Object>();
for (ListenerInvocation li : l)
l.removeAll(markedForRemoval);
}
listener = org.jboss.web.tomcat.service.session.distributedcache.ispn.DefaultLockManagerSource@1d2d2db8
0:li.target=org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup@2eedd32f
1:li.target=org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup@18b9ae20
2:li.target=org.infinispan.transaction.xa.TransactionTable$StaleTransactionCleanup@226d7ba7
... same li.target class for all entries, so they don't get removed
class org.jboss.web.tomcat.service.session.distributedcache.ispn.DefaultLockManagerSource implements LockManagerSource
class org.infinispan.transaction.xa.TransactionTable.StaleTransactionCleanup is a pojo with onViewChange method.