cancel
Showing results for 
Search instead for 
Did you mean: 

Deploying Activiti Explorer - NullPointer exception

ncoonghe
Champ in-the-making
Champ in-the-making
Hi

I get the below exception in the catalina log file when I dropped the activiti explorer war file under webapps in tomcat and started tomcat. Prior to starting it I had edited the db.properties to use the standalone H2 server
jdbc.url=jdbc:h2:tcp://localhost/activiti


04:51:54,736 [Thread-2] INFO  org.activiti.explorer.conf.DemoDataConfiguration
04:51:54,791 [Thread-2] INFO  org.activiti.explorer.conf.DemoDataConfiguration
Exception in thread "Thread-5" java.lang.NullPointerException
        at org.activiti.explorer.conf.DemoDataConfiguration$1.run(DemoDataConfig
        at java.lang.Thread.run(Thread.java:662)
04:51:55,114 [Thread-2] INFO  org.springframework.web.servlet.DispatcherServlet
04:51:55,116 [Thread-2] INFO  org.springframework.web.context.support.Annotation
04:51:55,118 [Thread-2] INFO  org.springframework.web.context.support.Annotation
04:51:55,260 [Thread-2] INFO  org.springframework.context.support.PostProcessorR
04:51:55,418 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotat
04:51:55,419 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotat
04:51:55,420 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotat

Can someone help me resolve this.


Regards
Nirmal
6 REPLIES 6

yvoswillens
Champ in-the-making
Champ in-the-making
Hi,

could you post a more complete stacktrace so it's clear on what line the NPE occurs?

Regards,

Yvo

ncoonghe
Champ in-the-making
Champ in-the-making
11:19:16,542 [Thread-2] INFO  org.activiti.explorer.conf.DemoDataConfiguration  - Initializing demo models
11:19:17,052 [Thread-2] INFO  org.activiti.explorer.conf.DemoDataConfiguration  - Initializing demo report data
Exception in thread "Thread-7" java.lang.NullPointerException
        at org.activiti.explorer.conf.DemoDataConfiguration$1.run(DemoDataConfiguration.java:224)
        at java.lang.Thread.run(Thread.java:662)
Jul 31, 2015 11:19:17 AM org.apache.catalina.session.StandardManager startInternal
SEVERE: Exception loading sessions from persistent storage
java.lang.IllegalStateException: Cannot deserialize BeanFactory with id org.springframework.web.context.support.AnnotationConfigWebApplicationContext@8497904: no factory registered for this id
        at org.springframework.beans.factory.support.DefaultListableBeanFactory$SerializedBeanFactoryReference.readResolve(DefaultListableBeanFactory.java:1158)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadResolve(ObjectStreamClass.java:1056)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1765)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1664)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1320)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:477)
        at org.springframework.aop.framework.AdvisedSupport.readObject(AdvisedSupport.java:557)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:477)
        at com.vaadin.event.ListenerMethod.readObject(ListenerMethod.java:108)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
        at java.util.HashSet.readObject(HashSet.java:291)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:477)
        at com.vaadin.event.ListenerMethod.readObject(ListenerMethod.java:108)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
        at java.util.HashSet.readObject(HashSet.java:291)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
        at java.util.HashMap.readObject(HashMap.java:1030)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
        at java.util.HashMap.readObject(HashMap.java:1030)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:969)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1852)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
        at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1600)
        at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1073)
        at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
        at org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
        at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:470)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:148)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5241)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:148)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:812)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:787)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:607)
        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:932)
        at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:723)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:470)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1329)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
        at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
        at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
        at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:389)
        at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:334)
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1041)
        at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:774)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:148)
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1033)
        at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:291)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:148)
        at org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:148)
        at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:727)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:148)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:621)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:322)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:450)
11:19:17,495 [Thread-2] INFO  org.springframework.web.servlet.DispatcherServlet  - FrameworkServlet 'dispatcher': initialization started
11:19:17,499 [Thread-2] INFO  org.springframework.web.context.support.AnnotationConfigWebApplicationContext  - Refreshing WebApplicationContext for namespace 'dispatcher-servlet': startup date [Fri Jul 31 11:19:17 PDT 2015]; parent: Root WebApplicationContext
11:19:17,501 [Thread-2] INFO  org.springframework.web.context.support.AnnotationConfigWebApplicationContext  - Registering annotated classes: [class org.activiti.explorer.servlet.DispatcherServletConfiguration]
11:19:17,634 [Thread-2] INFO  org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker  - Bean 'org.springframework.scheduling.annotation.ProxyAsyncConfiguration' of type [class org.springframework.scheduling.annotation.ProxyAsyncConfiguration$$EnhancerBySpringCGLIB$$8f31ad2e] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
11:19:17,775 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Mapped "{[/editor/stencilset],methods=[GET],params=[],headers=[],consumes=[],produces=[application/json],custom=[]}" onto public java.lang.String org.activiti.rest.editor.main.StencilsetRestResource.getStencilset()
11:19:17,776 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Mapped "{[/model/{modelId}/json],methods=[GET],params=[],headers=[],consumes=[],produces=[application/json],custom=[]}" onto public com.fasterxml.jackson.databind.node.ObjectNode org.activiti.rest.editor.model.ModelEditorJsonRestResource.getEditorJson(java.lang.String)
11:19:17,777 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Mapped "{[/model/{modelId}/save],methods=[PUT],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public void org.activiti.rest.editor.model.ModelSaveRestResource.saveModel(java.lang.String,org.springframework.util.MultiValueMap<java.lang.String, java.lang.String>)
11:19:17,778 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Mapped "{[/process-definition/{processDefinitionId}/diagram-layout],methods=[GET],params=[],headers=[],consumes=[],produces=[application/json],custom=[]}" onto public com.fasterxml.jackson.databind.node.ObjectNode org.activiti.rest.diagram.services.ProcessDefinitionDiagramLayoutResource.getDiagram(java.lang.String)
11:19:17,780 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Mapped "{[/process-instance/{processInstanceId}/diagram-layout],methods=[GET],params=[],headers=[],consumes=[],produces=[application/json],custom=[]}" onto public com.fasterxml.jackson.databind.node.ObjectNode org.activiti.rest.diagram.services.ProcessInstanceDiagramLayoutResource.getDiagram(java.lang.String)
11:19:17,781 [Thread-2] INFO  org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping  - Mapped "{[/process-instance/{processInstanceId}/highlights],methods=[GET],params=[],headers=[],consumes=[],produces=[application/json],custom=[]}" onto public com.fasterxml.jackson.databind.node.ObjectNode org.activiti.rest.diagram.services.ProcessInstanceHighlightsResource.getHighlighted(java.lang.String)
11:19:18,140 [Thread-2] INFO  org.springframework.web.servlet.DispatcherServlet  - FrameworkServlet 'dispatcher': initialization completed in 645 ms
Jul 31, 2015 11:19:18 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory docs
Jul 31, 2015 11:19:18 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory examples
Jul 31, 2015 11:19:18 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory host-manager
Jul 31, 2015 11:19:18 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory manager
Jul 31, 2015 11:19:18 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
Jul 31, 2015 11:19:18 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-apr-8080"]
Jul 31, 2015 11:19:18 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-apr-8009"]
Jul 31, 2015 11:19:18 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 13043 ms

vasile_dirla
Star Contributor
Star Contributor
What version of Activiti are you using?

(Also make sure the H2 server is up and running on the default port.)

If this is doesn't help please provide step by step what are you doing in order to reproduce it.

ncoonghe
Champ in-the-making
Champ in-the-making
I am using activiti-5.17.0. I just dropped the activiti-explorer.war under webapps in tomcat
Changed the DB properties to have the below entries and started tomcat.

db=h2
jdbc.driver=org.h2.Driver
jdbc.url=jdbc:h2:tcp://localhost/activiti
jdbc.username=sa
jdbc.password=

Although the exception comes on start up ….things seem to work. But I do not like the exception to be shown in the log. It does not happen if I use the in memory version of the DB. Only after I changed the jdbc URL to jdbc.url=jdbc:h2:tcp://localhost/activiti I see it happening

Also I run H2 as below

C:\Program Files (x86)\H2\bin>java -cp h2-1.3.176.jar  org.h2.tools.Server
TCP server running at tcp://130.110.217.110:9092 (only local connections)
PG server running at pg://130.110.217.110:5435 (only local connections)
Web Console server running at http://130.110.217.110:8082 (only local connections)


Sometimes the entire stack is not printed in the log just the NullPointerException, other times the whole stack is printed..


03:54:29,063 [Thread-2] INFO  org.activiti.explorer.conf.DemoDataConfiguration  - Initializing demo models
03:54:29,068 [Thread-2] INFO  org.activiti.explorer.conf.DemoDataConfiguration  - Initializing demo report data
Exception in thread "Thread-5" java.lang.NullPointerException
        at org.activiti.explorer.conf.DemoDataConfiguration$1.run(DemoDataConfiguration.java:224)
        at java.lang.Thread.run(Thread.java:662)
Aug 3, 2015 3:54:29 PM org.apache.catalina.session.StandardManager startInternal
SEVERE: Exception loading sessions from persistent storage
java.lang.IllegalStateException: Cannot deserialize BeanFactory with id org.springframework.web.context.support.AnnotationConfigWebApplicationContext@6d7e4dee: no factory registered for this id
        at org.springframework.beans.factory.support.DefaultListableBeanFactory$SerializedBeanFactoryReference.readResolve(DefaultListableBeanFactory.java:1158)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at java.io.ObjectStreamClass.invokeReadResolve(ObjectStreamClass.java:1056)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1765)
        at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1326)
        at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1950)
        at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1874)
        at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1756)

imsrk
Champ in-the-making
Champ in-the-making
Hi,

I'm also experiencing same NullPointerException every time I restart the tomcat.
Activiti Version 5.20.0
Tomcat Version: 7.0.53
JDK: 1.8.0_65
Operating System: OS X 10.10.5
DB: mysql  Ver 14.14 Distrib 5.6.29, for osx10.8 (x86_64)


Though this error (NPE) doesn't have any functional impact on the activiti-explorer or activiti-rest operations still it's going to be a concern if the project has to be moved to Production. Kindly assist/guide on this error to avoid any risk factor it could bring post production.

Stacktrace:

<blockcode>
12:33:40,798 [localhost-startStop-1] INFO  org.activiti.explorer.conf.DemoDataConfiguration  - Initializing demo groups
12:33:40,883 [localhost-startStop-1] INFO  org.activiti.explorer.conf.DemoDataConfiguration  - Initializing demo users
Jun 09, 2016 12:33:41 AM org.apache.catalina.session.StandardManager startInternal
SEVERE: Exception loading sessions from persistent storage
java.lang.IllegalStateException: Cannot deserialize BeanFactory with id org.springframework.web.context.support.AnnotationConfigWebApplicationContext@1912782e: no factory registered for this id
at org.springframework.beans.factory.support.DefaultListableBeanFactory$SerializedBeanFactoryReference.readResolve(DefaultListableBeanFactory.java:1356)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at java.io.ObjectStreamClass.invokeReadResolve(ObjectStreamClass.java:1148)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1810)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1707)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1345)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:501)
at org.springframework.aop.framework.AdvisedSupport.readObject(AdvisedSupport.java:557)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1900)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:501)
at com.vaadin.event.ListenerMethod.readObject(ListenerMethod.java:108)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1900)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
at java.util.HashSet.readObject(HashSet.java:333)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1900)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
at java.util.Hashtable.readObject(Hashtable.java:1193)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1900)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
at java.util.LinkedList.readObject(LinkedList.java:1149)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1900)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2000)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1924)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1801)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1595)
at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1060)
at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:282)
at org.apache.catalina.session.StandardManager.load(StandardManager.java:202)
at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:489)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5476)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1073)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)

12:33:41,150 [localhost-startStop-1] INFO  org.springframework.web.servlet.DispatcherServlet  - FrameworkServlet 'dispatcher': initialization started
</blockcode>

jbarrez
Star Contributor
Star Contributor
This is the Tomcat session serialization failing cause some bits are not serializable …
One quick fix is to disable session serialization on Tomcat.