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

Wicket Session may be null in SessionBindingListener after deserialization

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 6.6.0
    • 6.7.0, 1.5.11
    • wicket
    • None

    Description

      I got this exception when starting my wicket app:

      10:00:24.879 [WARN ] qtp725811713-28 - o.e.j.server.AbstractHttpConnection - /
      java.lang.NullPointerException: null
      at org.apache.wicket.session.HttpSessionStore$SessionBindingListener.valueUnbound(HttpSessionStore.java:469) ~[wicket-core-6.6.0.jar:6.6.0]
      at org.eclipse.jetty.server.session.AbstractSession.unbindValue(AbstractSession.java:519) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.AbstractSession.clearAttributes(AbstractSession.java:370) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.AbstractSession.doInvalidate(AbstractSession.java:337) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.HashedSession.doInvalidate(HashedSession.java:90) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.AbstractSession.invalidate(AbstractSession.java:327) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.AbstractSession.access(AbstractSession.java:283) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.AbstractSessionManager.access(AbstractSessionManager.java:188) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:172) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1009) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.Server.handle(Server.java:368) ~[jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:488) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.BlockingHttpConnection.handleRequest(BlockingHttpConnection.java:53) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:932) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:994) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:640) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.BlockingHttpConnection.handle(BlockingHttpConnection.java:72) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.server.bio.SocketConnector$ConnectorEndPoint.run(SocketConnector.java:264) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543) [jetty-all-server-8.1.9.v20130131.jar:8.1.9.v20130131]
      at java.lang.Thread.run(Thread.java:722) [na:1.7.0_13]

      The line is: wicketSession.onInvalidate(); A simple null check should suffice.

      Attachments

        Activity

          People

            mgrigorov Martin Tzvetanov Grigorov
            cleiter Christoph Leiter
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: