Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-5040

Session.exists() returns false when ThreadContext#session is not set to current session

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 6.5.0
    • Fix Version/s: 6.6.0
    • Component/s: wicket
    • Labels:
      None

      Description

      There are several places in Wicket which check for the existence of a Session before actually getting a reference to it, e.g. FeedbackCollector:

      public final List<FeedbackMessage> collect(final IFeedbackMessageFilter filter)
      {
      ...
      if (includeSession && Session.exists())

      { messages.addAll(Session.get().getFeedbackMessages().messages(filter)); }

      }

      If no one has called Session#get(), all calls to Session#exists() return false although a session might exist in the session store, i.e. it might just not be set to ThreadContext#session already.

        Attachments

        Issue Links

          Activity

            People

            • Assignee:
              svenmeier Sven Meier
              Reporter:
              svenmeier Sven Meier

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment