This commit is contained in:
Jan Bartel 2017-04-27 12:47:30 +02:00
parent 776fd3e947
commit f9e9fd645d
2 changed files with 5 additions and 9 deletions

View File

@ -519,15 +519,11 @@ public class DefaultSessionIdManager extends ContainerLifeCycle implements Sessi
public Set<SessionHandler> getSessionHandlers()
{
Set<SessionHandler> handlers = new HashSet<>();
Handler[] contexts = _server.getChildHandlersByClass(ContextHandler.class);
for (int i=0; contexts!=null && i<contexts.length; i++)
Handler[] tmp = _server.getChildHandlersByClass(SessionHandler.class);
if (tmp != null)
{
SessionHandler sessionHandler = ((ContextHandler)contexts[i]).getChildHandlerByClass(SessionHandler.class);
if (sessionHandler != null)
{
handlers.add(sessionHandler);
}
for (Handler h:tmp)
handlers.add((SessionHandler)h);
}
return handlers;
}

View File

@ -1257,7 +1257,7 @@ public class SessionHandler extends ScopedHandler
if (isStopping() || isStopped())
return;
if (LOG.isDebugEnabled()) LOG.debug("Scavenging sessions");
if (LOG.isDebugEnabled()) LOG.debug("{} scavenging sessions", this);
//Get a snapshot of the candidates as they are now. Others that
//arrive during this processing will be dealt with on
//subsequent call to scavenge