AnsweredAssumed Answered

Error when configuring h2 as a standalone server

Question asked by swsw1 on Oct 22, 2014
Latest reply on Oct 24, 2014 by jbarrez
I tried to get started with the bpmn-tutorial in chatpter 7 of the activity-manual after successfully installing and deploying the activity-jars and creating a processInstance, which I ran on Tomcat. I likewise installed an h2 database aided by the windows installer - I started the h2 database-server with the *.bat, with the goal in mind to carry out the first step of the bpmn-tutorial which reads as follows:

This tutorial assumes that you have the Activiti demo setup running, and that you are using a standalone H2 server. Edit db.properties and set the jdbc.url=jdbc:h2:tcp://localhost/activiti, and then run the standalone server according to H2's documentation.
 

So I navigated to the dp.properties-file in my war file (C:\foo\bar\ServerFolder\webapps\activiti-explorer.war\WEB-INF\classes\) and altered the string that I beheld therein (db=h2jdbc.driver=org.h2.Driverjdbc.url=jdbc:h2:mem:activiti;DB_CLOSE_DELAY=1000jdbc.username=sajdbc.password=) to this: jdbc.url=jdbc:h2:tcp://localhost/activiti

As a result of this, the Tomcat server, which had started up repeatedly, would no longer start up, the error message - betraying that my programme runs as a Vaadin application named Vaadin - reads as follows:

Servlet.service() for servlet [Vaadin Application] in context with path [/Vaadin] threw exception [java.lang.NullPointerException] with root cause
java.lang.NullPointerException
   at com.example.vaadin.VaadinApplication.init(VaadinApplication.java:35)
   at com.vaadin.Application.start(Application.java:551)
   at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.startApplication(AbstractApplicationServlet.java:1219)
   at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:484)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
   at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
   at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)
   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
   at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)
   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
   at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1041)
   at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:603)
   at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:310)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)




 

Outcomes