[
https://jira.jboss.org/jira/browse/ISPN-220?page=com.atlassian.jira.plugi...
]
Vladimir Blagojevic updated ISPN-220:
-------------------------------------
Attachment: infinispan_leak.zip
Shows path to GC root of an object that is not garbage collected
Test suite has memory leaks
---------------------------
Key: ISPN-220
URL:
https://jira.jboss.org/jira/browse/ISPN-220
Project: Infinispan
Issue Type: Bug
Affects Versions: 4.0.0.BETA2
Reporter: Vladimir Blagojevic
Assignee: Vladimir Blagojevic
Fix For: 4.0.0.CR1
Attachments: infinispan_leak.zip
TestNG during an execution of a test suite keeps references to all executed test class
instances. Our test classes in some cases keep references to instantiated caches thus
preventing cache instances from ever being garbage collected.
Our test classes should never keep references to cache instances other than in a test
method scope. If truly there is a need to keep reference to a cache in a class scope these
references should be cleared and nulled in a method annotated with @AfterClass. Of course,
the same applies to any objects in class scope (cache managers etc etc.)
Since TestNG does not traverse class hierarchy for invocation of @AfterClass annotated
methods a special care has to be taken that every @AfterClass method is invoked in test
class hierarchy (i.e call super).
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira