-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(issue#912, management) Fixed a memory leak by altering CollectOnlyMa… #841
(issue#912, management) Fixed a memory leak by altering CollectOnlyMa… #841
Conversation
…nagementSessionStrategy.soSessionClosed to call doSessionClosedListeners on the sessionBean.
The PR looks good and seems to fix the problem. I didn't merge because I thought of adding an integration test. |
@danibusu Any ideas for how to do the integration test? I thought it might be possible to do one by using a test service so it can examine the MX bean on the session. I am not sure it's possible though. The unit test does confirm the code change. |
Added integration test JmxSessionIT to check for MX session bean leak
…and verify there are none (otherwise the test was passing without the fix for kaazing#912).
Build failed twice in http.proxy service (ProxyServiceTest), filed as #846 |
|
||
mbeanNames = mbeanServerConn.queryNames( | ||
ObjectName.getInstance("*:serviceType=echo,name=sessions,*"), null); | ||
for (ObjectName name : mbeanNames) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why use a for statement? The test will stop running after the first failure. Maybe check that the set size is zero?
…nagementSessionStrategy.soSessionClosed to call doSessionClosedListeners on the sessionBean.
This should hopefully address the memory leak noted in ticket 912: the gateway is accumulating SessionMXBeanImpl instances.