InsertSensor response: "Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure"

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

InsertSensor response: "Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure"

TSlawecki
I have set up a 52N SOS 4.3.6 server on a Windows 2012 server running Tomcat 7.0.70, PostgreSQL 9.5.3 Win X86-64, and PostGIS 2.2. The client, admin, and other pages are reachable, and I can change settings, etc.

However, when I try to post the POX SOS 2.0 InsertSensor example from the test client, I get the following response:

<?xml version="1.0" encoding="UTF-8"?>
<ows:ExceptionReport xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.0.0" xsi:schemaLocation="http://www.opengis.net/ows/1.1 http://schemas.opengis.net/ows/1.1.0/owsAll.xsd">
  <ows:Exception exceptionCode="NoApplicableCode">
    <ows:ExceptionText>Error while inserting sensor data into database!
[EXEPTION]:
Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure</ows:ExceptionText>
  </ows:Exception>
</ows:ExceptionReport>

Thanks,

Tad

Reply | Threaded
Open this post in threaded view
|

Re: InsertSensor response: "Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure"

Carsten Hollmann
Hi Tad,

Have you selected "PostgreSQL/PostGIS" as datasource during the
installation process?

Because the TProcedure is only loaded from the mapping files if the
"Transactional Profile" is checked on the datasource configuration page
during the installation.

If the "Transactional Profile" was checked it might be that the mapping
file was not loaded correctly. Then a reload of the SOS/Tomcat may solve
the issue.

Best,
Carsten

_______________________________________________
SWE mailing list
[hidden email]
http://list.52north.org/mailman/listinfo/swe
http://sensorweb.forum.52north.org
Please respect our mailing list guidelines:
http://52north.org/resources/mailing-lists-and-forums/guidelines
Reply | Threaded
Open this post in threaded view
|

Re: InsertSensor response: "Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure"

TSlawecki
I restarted the Tomcat service and received the same result. Since I wasn't sure about the datasource and Transactional Profile setting, I then reset the SOS and redid the configuration, and received the following error (which I now recall also occurred on the initial configuration) after pressing install:

HTTP Status 500 - Request processing failed; nested exception is java.lang.IllegalStateException: invalidate: Session already invalidated

type Exception report

message Request processing failed; nested exception is java.lang.IllegalStateException: invalidate: Session already invalidated

description The server encountered an internal error that prevented it from fulfilling this request.

exception

org.springframework.web.util.NestedServletException: Request processing failed; nested exception is java.lang.IllegalStateException: invalidate: Session already invalidated
        org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:948)
        org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
        org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
        org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        org.n52.sos.web.install.InstallFilter.doFilter(InstallFilter.java:62)
        org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:186)
        org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:160)
        org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)
        org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)
        org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
        com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:168)
        com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:233)
root cause

java.lang.IllegalStateException: invalidate: Session already invalidated
        org.apache.catalina.session.StandardSession.invalidate(StandardSession.java:1260)
        org.apache.catalina.session.StandardSessionFacade.invalidate(StandardSessionFacade.java:183)
        org.n52.sos.web.install.InstallFinishController.post(InstallFinishController.java:81)
        sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        java.lang.reflect.Method.invoke(Unknown Source)
        org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:219)
        org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)
        org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)
        org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)
        org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)
        org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)
        org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)
        org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
        org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
        org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
        org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
        org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        org.n52.sos.web.install.InstallFilter.doFilter(InstallFilter.java:62)
        org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:186)
        org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:160)
        org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)
        org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)
        org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
        com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:168)
        com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:233)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.70 logs.

Apache Tomcat/7.0.70

-----

A copy of the 52N log is at https://limno.sharefile.com/d-sbf3a7f124ef4f3c9.

Reply | Threaded
Open this post in threaded view
|

Re: InsertSensor response: "Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure"

Carsten Hollmann
Hi Tad,

in the log statements from 2016-07-20 the TProcedure.hbm.xml is not
listed. So it looks like the transactional profile was not enabled.

On Windows machines it can be that the Hibernate sessions/database
connection are not closed/released if you execute a reset of the SOS
configuration.

So after a restart of the Tomcat the SOS should work.

Best,
Carsten

Am 21.07.2016 um 12:42 schrieb TSlawecki:

> I restarted the Tomcat service and received the same result. Since I wasn't
> sure about the datasource and Transactional Profile setting, I then reset
> the SOS and redid the configuration, and received the following error (which
> I now recall also occurred on the initial configuration) after pressing
> install:
>
> HTTP Status 500 - Request processing failed; nested exception is
> java.lang.IllegalStateException: invalidate: Session already invalidated
>
> type Exception report
>
> message Request processing failed; nested exception is
> java.lang.IllegalStateException: invalidate: Session already invalidated
>
> description The server encountered an internal error that prevented it from
> fulfilling this request.
>
> exception
>
> org.springframework.web.util.NestedServletException: Request processing
> failed; nested exception is java.lang.IllegalStateException: invalidate:
> Session already invalidated
>
> org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:948)
>
> org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
>
> org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
> org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
> org.n52.sos.web.install.InstallFilter.doFilter(InstallFilter.java:62)
>
> org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:186)
>
> org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:160)
>
> org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)
>
> org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)
>
> org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
>
> org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
> com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:168)
> com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:233)
> root cause
>
> java.lang.IllegalStateException: invalidate: Session already invalidated
>
> org.apache.catalina.session.StandardSession.invalidate(StandardSession.java:1260)
>
> org.apache.catalina.session.StandardSessionFacade.invalidate(StandardSessionFacade.java:183)
>
> org.n52.sos.web.install.InstallFinishController.post(InstallFinishController.java:81)
> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> java.lang.reflect.Method.invoke(Unknown Source)
>
> org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:219)
>
> org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)
>
> org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)
>
> org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)
>
> org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)
>
> org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)
>
> org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)
>
> org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
>
> org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
>
> org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
>
> org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
> org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
> org.n52.sos.web.install.InstallFilter.doFilter(InstallFilter.java:62)
>
> org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:186)
>
> org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:160)
>
> org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:343)
>
> org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:260)
>
> org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
>
> org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
> com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:168)
> com.thetransactioncompany.cors.CORSFilter.doFilter(CORSFilter.java:233)
> note The full stack trace of the root cause is available in the Apache
> Tomcat/7.0.70 logs.
>
> Apache Tomcat/7.0.70
>
> -----
>
> A copy of the 52N log is at https://limno.sharefile.com/d-sbf3a7f124ef4f3c9.
>
>
>
>
>
> --
> View this message in context: http://sensorweb.forum.52north.org/InsertSensor-response-Unknown-entity-org-n52-sos-ds-hibernate-entities-TProcedure-tp4028584p4028586.html
> Sent from the 52° North - Sensor Web Community Forum mailing list archive at Nabble.com.
> _______________________________________________
> SWE mailing list
> [hidden email]
> http://list.52north.org/mailman/listinfo/swe
> http://sensorweb.forum.52north.org
> Please respect our mailing list guidelines:
> http://52north.org/resources/mailing-lists-and-forums/guidelines
>

--
Carsten Hollmann

52°North Initiative for Geospatial Open Source Software GmbH
Martin-Luther-King-Weg 24
48155 Münster, Germany

E-Mail: [hidden email]
Fon: +49 (0)-251-396371-35
Fax: +49 (0)-251-396371-11
http://52north.org/
Twitter: @FiveTwoN

General Managers: Dr. Albert Remke, Dr. Andreas Wytzisk
Local Court Muenster HRB 10849
_______________________________________________
SWE mailing list
[hidden email]
http://list.52north.org/mailman/listinfo/swe
http://sensorweb.forum.52north.org
Please respect our mailing list guidelines:
http://52north.org/resources/mailing-lists-and-forums/guidelines
Reply | Threaded
Open this post in threaded view
|

Re: InsertSensor response: "Unknown entity: org.n52.sos.ds.hibernate.entities.TProcedure"

TSlawecki
The issue was resolved by restarting the Windows VM (I was impatient and wasn't sure where I was in the SOS v. Tomcat restart sequence, so I reset everything with a reboot).

I will be building a similar instance in the next few weeks and will update this thread with results.