glassfish
  1. glassfish
  2. GLASSFISH-14179

NPE in org.glassfish.web.ha.session.management.HASessionStoreValve.invoke(HASessionStoreValve.java:110

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Duplicate
    • Affects Version/s: 3.1
    • Fix Version/s: 3.1_ms07
    • Component/s: cdi
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: Linux

    • Issuezilla Id:
      14,179

      Description

      After deploying the J1 ShoppingCart application with availabilityenabled and
      accessing the index page get the following NPE. Using 24th Oct nightly build.
      This is a regression since previously we were able to access the application.

      [#|2010-10-25T11:30:29.859+0530|INFO|glassfish3.1|javax.enterprise.resource.webcontainer.jsf.config|_ThreadID=15;_ThreadName=Thread-1;|Initializing
      Mojarra 2.1.0 (SNAPSHOT b06) for context '/ShoppingCart'|#]

      [#|2010-10-25T11:30:32.510+0530|INFO|glassfish3.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=94;_ThreadName=http-thread-pool-24848(2);|WEB0671:
      Loading application [ShoppingCart] at [/ShoppingCart]|#]

      [#|2010-10-25T11:30:32.510+0530|INFO|glassfish3.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=94;_ThreadName=http-thread-pool-24848(2);|WEB0671:
      Loading application [ShoppingCart] at [/ShoppingCart]|#]

      [#|2010-10-25T11:30:32.510+0530|INFO|glassfish3.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=15;_ThreadName=Thread-1;|WEB0671:
      Loading application [ShoppingCart] at [/ShoppingCart]|#]

      [#|2010-10-25T11:30:34.441+0530|INFO|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=15;_ThreadName=Thread-1;|ShoppingCart
      was successfully deployed in 13,232 milliseconds.|#]

      [#|2010-10-25T11:30:35.642+0530|SEVERE|glassfish3.1|org.apache.catalina.connector.CoyoteAdapter|_ThreadID=15;_ThreadName=Thread-1;|PWC3989:
      An exception or error occurred in the container during the request processing
      java.lang.NullPointerException
      at
      org.glassfish.web.ha.session.management.HASessionStoreValve.invoke(HASessionStoreValve.java:110)
      at
      org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:623)
      at
      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:595)
      at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:98)
      at
      com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:91)
      at
      org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:162)
      at
      org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:326)
      at
      org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:227)
      at
      com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:170)
      at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:817)
      at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:718)
      at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1007)
      at
      com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
      at
      com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
      at
      com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
      at
      com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
      at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
      at
      com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
      at
      com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
      at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
      at
      com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
      at
      com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
      at java.lang.Thread.run(Thread.java:619)

      #]

      To reproduce run the test from DFT workspace.

      1. $cd gf-ha-qe/functional/cdi
      2. Follow the readme to start the database and configure the tables.
      3. $ant shopping-cart

        Issue Links

          Activity

          Hide
          sonymanuel added a comment -

          Created an attachment (id=5214)
          instance1 server log

          Show
          sonymanuel added a comment - Created an attachment (id=5214) instance1 server log
          Hide
          Mahesh Kannan added a comment -

          Assigning this to Rajiv

          Show
          Mahesh Kannan added a comment - Assigning this to Rajiv
          Hide
          Rajiv Mordani added a comment -

          Fixed the NPE however now I see the following exception. Assigning to Siva as we
          cannot put things in session that are not serializable.

          [#|2010-10-25T13:11:21.015-
          0700|INFO|glassfish3.1|org.apache.catalina.session.ManagerBase|_ThreadID=15;_Thr
          eadName=Thread-1;|PWC2785: Cannot serialize session attribute
          org.jboss.weld.context.SessionContext#org.jboss.weld.bean-weld-ManagedBean-class
          org.jboss.weld.conversation.ServletConversationManager for session
          5043732c9c552186df105f24301aeam.java:330)
          at
          java.util.concurrent.ConcurrentHashMap.writeObject(ConcurrentHashMap.java:1247)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at
          sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at
          sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
          a:25)
          at java.lang.reflect.Method.invoke(Method.java:597)
          at
          java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:945)
          at
          java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1469)
          at
          java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
          at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
          at
          java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
          at
          java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483)
          at
          java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
          at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
          at
          java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
          at
          java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483)
          at
          java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
          at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
          at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330)
          at
          org.apache.catalina.session.StandardSession.writeObject(StandardSession.java:206
          3)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at
          sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at
          sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
          a:25)
          at java.lang.reflect.Method.invoke(Method.java:597)
          at
          java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:945)
          at
          java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1469)
          at
          java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
          at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
          at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330)
          at
          org.apache.catalina.session.StoreBase.writeSession(StoreBase.java:269)
          at
          org.glassfish.web.ha.session.management.HAStoreBase.getByteArray(HAStoreBase.jav
          a:229)
          at
          org.glassfish.web.ha.session.management.ReplicationStore.doValveSave(Replication
          Store.java:145)
          at
          org.glassfish.web.ha.session.management.ReplicationWebEventPersistentManager.doV
          alveSave(ReplicationWebEventPersistentManager.java:157)
          at
          org.glassfish.web.ha.session.management.HASessionStoreValve.doPostInvoke(HASessi
          onStoreValve.java:175)
          at
          org.glassfish.web.ha.session.management.HASessionStoreValve.postInvoke(HASession
          StoreValve.java:136)
          at
          org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:670)
          at
          org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:595)
          at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:98)
          at
          com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingS
          tandardPipeline.java:91)
          at
          org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:162)
          at
          org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:326)
          at
          org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:227)
          at
          com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java
          :170)
          at
          com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:817)
          at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:718)
          at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1007)
          at
          com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:22
          5)
          at
          com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.
          java:137)
          at
          com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
          at
          com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
          at
          com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
          at
          com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54
          )
          at
          com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)

          at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
          at
          com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:53
          2)
          at
          com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
          at java.lang.Thread.run(Thread.java:662)

          Show
          Rajiv Mordani added a comment - Fixed the NPE however now I see the following exception. Assigning to Siva as we cannot put things in session that are not serializable. [#|2010-10-25T13:11:21.015- 0700|INFO|glassfish3.1|org.apache.catalina.session.ManagerBase|_ThreadID=15;_Thr eadName=Thread-1;|PWC2785: Cannot serialize session attribute org.jboss.weld.context.SessionContext#org.jboss.weld.bean-weld-ManagedBean-class org.jboss.weld.conversation.ServletConversationManager for session 5043732c9c552186df105f24301aeam.java:330) at java.util.concurrent.ConcurrentHashMap.writeObject(ConcurrentHashMap.java:1247) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav a:25) at java.lang.reflect.Method.invoke(Method.java:597) at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:945) at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1469) at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400) at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158) at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518) at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483) at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400) at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158) at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518) at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483) at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400) at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158) at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330) at org.apache.catalina.session.StandardSession.writeObject(StandardSession.java:206 3) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav a:25) at java.lang.reflect.Method.invoke(Method.java:597) at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:945) at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1469) at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400) at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158) at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330) at org.apache.catalina.session.StoreBase.writeSession(StoreBase.java:269) at org.glassfish.web.ha.session.management.HAStoreBase.getByteArray(HAStoreBase.jav a:229) at org.glassfish.web.ha.session.management.ReplicationStore.doValveSave(Replication Store.java:145) at org.glassfish.web.ha.session.management.ReplicationWebEventPersistentManager.doV alveSave(ReplicationWebEventPersistentManager.java:157) at org.glassfish.web.ha.session.management.HASessionStoreValve.doPostInvoke(HASessi onStoreValve.java:175) at org.glassfish.web.ha.session.management.HASessionStoreValve.postInvoke(HASession StoreValve.java:136) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:670) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:595) at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:98) at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingS tandardPipeline.java:91) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:162) at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:326) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:227) at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java :170) at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:817) at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:718) at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1007) at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:22 5) at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain. java:137) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90) at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79) at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54 ) at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59) at com.sun.grizzly.ContextTask.run(ContextTask.java:71) at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:53 2) at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513) at java.lang.Thread.run(Thread.java:662)
          Hide
          Rajiv Mordani added a comment -

          Changing category to CDI.

          Show
          Rajiv Mordani added a comment - Changing category to CDI.
          Hide
          Sivakumar Thyagarajan added a comment -

          Marking this as an duplicate of 13881

              • This issue has been marked as a duplicate of 13881 ***
          Show
          Sivakumar Thyagarajan added a comment - Marking this as an duplicate of 13881 This issue has been marked as a duplicate of 13881 ***

            People

            • Assignee:
              Sivakumar Thyagarajan
              Reporter:
              sonymanuel
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: