When PUSH transport is websocket, the request associated to atmosphere is a stub implementation that always returns false for 'isRequestedSessionIdValid()' preventing PushSessionTracker to serialize the session.
In addition, accessing the request from a background thread may throw IllegalStateException if the servlet container is recycling request objects (e.g. Tomcat facade). With this change, the session validity is checked against the SessionListener that is already observing session lifecycle events.
Description
When PUSH transport is websocket, the request associated to atmosphere is a stub implementation that always returns false for 'isRequestedSessionIdValid()' preventing PushSessionTracker to serialize the session. In addition, accessing the request from a background thread may throw IllegalStateException if the servlet container is recycling request objects (e.g. Tomcat facade). With this change, the session validity is checked against the SessionListener that is already observing session lifecycle events.
Fixes #119
Type of change
Checklist
Additional for
Feature
type of change