Hi all,
I’m trying to build the newest GeoNetwork v3.6 and deploy the .war file using Tomcat. I’m wondering what is the difference between the branch 3.6.x and the tag 3.6.0. I tried both, only the war file build from branch 3.6.x works followed the software development steps.
For the tag 3.6.0 repository from github, I got the following error messages:
Raised exception while starting the application. Fix the error and restart.
Message <br>java.lang.ClassCastException: org.geotools.jdbc.JDBCFeatureSource cannot be cast to org.geotools.data.FeatureStore<br>
Handler <br>org.fao.geonet.Geonetwork<br>
Exception <br>java.lang.RuntimeException: java.lang.ClassCastException: org.geotools.jdbc.JDBCFeatureSource cannot be cast to org.geotools.data.FeatureStore<br>
Stack <br>java.lang.RuntimeException: java.lang.ClassCastException: org.geotools.jdbc.JDBCFeatureSource cannot be cast to org.geotools.data.FeatureStore<br> at org.fao.geonet.kernel.search.SearchManager$Spatial.createWriter(SearchManager.java:1616)<br> at org.fao.geonet.kernel.search.SearchManager$Spatial.<init>(SearchManager.java:1597)<br> at org.fao.geonet.kernel.search.SearchManager.initNonStaticData(SearchManager.java:507)<br> at org.fao.geonet.kernel.search.SearchManager.init(SearchManager.java:488)<br> at org.fao.geonet.Geonetwork.start(Geonetwork.java:283)<br> at jeeves.server.JeevesEngine.initAppHandler(JeevesEngine.java:448)<br> at jeeves.server.JeevesEngine.init(JeevesEngine.java:191)<br> at jeeves.server.sources.http.JeevesServlet.init(JeevesServlet.java:84)<br> at javax.servlet.GenericServlet.init(GenericServlet.java:158)<br> at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1144)<br> at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1091)<br> at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:983)<br> at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4998)<br> at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5312)<br> at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)<br> at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1389)<br> at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:692)<br> at org.apache.catalina.manager.HTMLManagerServlet.doPost(HTMLManagerServlet.java:218)<br> at javax.servlet.http.HttpServlet.service(HttpServlet.java:661)<br> at javax.servlet.http.HttpServlet.service(HttpServlet.java:742)<br> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)<br> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)<br> at org.apache.catalina.filters.CsrfPreventionFilter.doFilter(CsrfPreventionFilter.java:136)<br> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)<br> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)<br> at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)<br> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)<br> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)<br> at org.apache.catalina.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:109)<br> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)<br> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)<br> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)<br> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)<br> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:610)<br> at org.apache.catalina.valves.RequestFilterValve.process(RequestFilterValve.java:348)<br> at org.apache.catalina.valves.RemoteAddrValve.invoke(RemoteAddrValve.java:52)<br> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)<br> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)<br> at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:650)<br> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)<br> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)<br> at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:800)<br> at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)<br> at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:806)<br> at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)<br> at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)<br> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)<br> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)<br> at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)<br> at java.lang.Thread.run(Thread.java:748)<br>Caused by: java.lang.ClassCastException: org.geotools.jdbc.JDBCFeatureSource cannot be cast to org.geotools.data.FeatureStore<br> at org.fao.geonet.kernel.search.spatial.SpatialIndexWriter.findSpatialIndexStore(SpatialIndexWriter.java:456)<br> at org.fao.geonet.kernel.search.spatial.SpatialIndexWriter.createFeatureStore(SpatialIndexWriter.java:432)<br> at org.fao.geonet.kernel.search.spatial.SpatialIndexWriter.<init>(SpatialIndexWriter.java:122)<br> at org.fao.geonet.kernel.search.SearchManager$Spatial.createWriter(SearchManager.java:1611)<br> ... 49 more<br><br>
I’m wondering does anybody ever try to use the tag 3.6.0 repository to build the .war file, or if anyone had seen this error messages and may have any clue how to solve it. Any suggestions or ideas would be appreciated.
Thank you all.
Zhuoyue Zhou