Hi,
I'm running Windows 7 64-bit, with Tomcat 8.0.22 (64-bit Windows zip), MySQL Connector/J v5.1.35, and MySQL 5.6.17.
I've set up a Fosstrak repository (0.5.0), and, so far, everything is working in that I can upload events via the capture interface, and retrieve them via the query interface.
I'm now trying to add the webadapter, following the instructions in
https://code.google.com/p/fosstrak/wiki/EpcisWebadapterGuideI can get to the page
http://localhost:8080/epcis-webadapter-0.1.0/rest/1/config/epcisurl and change the instance to
http://localhost:8080/epcis-repository-0.5.0However, when I try to go to
http://localhost:8080/epcis-webadapter-0.1.0/ i get the following error:
"org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: [63] in the generated java file: [C:\temp\apache-tomcat-8.0.22\work\Catalina\localhost\epcis-webadapter-0.1.0\org\apache\jsp\index_jsp.java]
The method getDispatcherType() is undefined for the type HttpServletRequest
Stacktrace:
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:102)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:198)
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:450)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:361)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:336)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:323)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:585)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:363)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:396)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:340)
javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)"
Has anyone else had experience of this?
From google (
http://stackoverflow.com/questions/26436463/getdispatchertype-is-undefined-for-the-type-httpservletrequest ), it seems that it's something to do with a conflicting servlet-api version? the recommendation is to change:
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.5</version>
</dependency
to:
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>
</dependency>
However, where would I do this? there are a couple of possible candidate pom.xml files:
<apache-tomcat-8.0.22>\temp\0-epcis-repository-0.5.0\META-INF\maven\org.fosstrak.epcis\epcis-repository\pom.xml
<apache-tomcat-8.0.22>\webapps\epcis-repository-0.5.0\META-INF\maven\org.fosstrak.epcis\epcis-repository\pom.xml
Should I change either of them? both of them? none of them? apparently these files are something to do with something called maven... I'm not running anything fancy on here, just a plain jdk - is maven something that gets bundled with tomcat?
Alternatively, should I just go back to Tomcat 7.x?
Thanks for any pointers!
Dave