duncangrant commented on a change in pull request #1096:
URL: https://github.com/apache/brooklyn-server/pull/1096#discussion_r420989424
##########
File path:
rest/rest-resources/src/main/java/org/apache/brooklyn/rest/util/MultiSessionAttributeAdapter.java
##########
@@ -217,7 +219,14 @@ private void invalidateAllSession(HttpSession
preferredSession, HttpSession loca
private HttpSession findValidPreferredSession(HttpSession
localSession, HttpServletRequest optionalRequest) {
if (localSession instanceof Session) {
SessionHandler preferredHandler =
getPreferredJettyHandler((Session)localSession, true, true);
- HttpSession preferredSession = preferredHandler==null ? null :
preferredHandler.getHttpSession(localSession.getId());
+
+ SessionIdManager idManager =
preferredHandler.getSessionIdManager();
+ String id = idManager.getId(localSession.getId());
+ HttpSession preferredSession = preferredHandler.getSession(id);
+
+ if (preferredSession != null &&
!((Session)preferredSession).getExtendedId().equals(id))
Review comment:
I think you're comparing to the wrong id here? the localSession.getId
returns the extended id and the idManager.getId returns the non-extended id
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]