Hi Ben,

UPDATE:  it works!  I added a data security rule that allows write
permissions for the postgis layer.  Thank you so much for your assistance
in this.  You're making the world a better place!

Best,
Todd

On Fri, Jun 15, 2018 at 8:03 AM, Todd Jacobus <t...@tcarta.com> wrote:

> Ben,
>
> Interesting!  I changed the namespace as per your suggestion and I think
> we're making progress.  At least, I'm seeing a different error (see below),
> stating that the layer/table (aoi_features) is read-only.  I assume this
> means GeoServer was able to connect to the right workspace/datastore/layer
> namespace, and I now need to configure the wfs and/or table for write
> permissions.  I don't have any special permissions set on postgres and WFS
> transactions are enabled in the WFS settings.  I noticed that I don't have
> any authentication chains set up for POST requests.  Do I need a explicit
> filter chain allowing anonymous POST requests?  Thank you very much for
> your continued help!
>
> Best,
> Todd
>
>
> org.geoserver.wfs.WFSTransactionException: {http://www.tcartadata.com/
> aoi}aoi_features is read-only
> at org.geoserver.wfs.Transaction.execute(Transaction.java:269)
> at org.geoserver.wfs.Transaction.transaction(Transaction.java:109)
> at org.geoserver.wfs.DefaultWebFeatureService.transaction(
> DefaultWebFeatureService.java:172)
> 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 org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection
> (AopUtils.java:333)
> at org.springframework.aop.framework.ReflectiveMethodInvocation.
> invokeJoinpoint(ReflectiveMethodInvocation.java:190)
> at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(
> ReflectiveMethodInvocation.java:157)
> at org.geoserver.ows.util.RequestObjectLogger.invoke(
> RequestObjectLogger.java:55)
> at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(
> ReflectiveMethodInvocation.java:179)
> at org.springframework.aop.framework.JdkDynamicAopProxy.
> invoke(JdkDynamicAopProxy.java:213)
> at com.sun.proxy.$Proxy95.transaction(Unknown Source)
> 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 org.geoserver.ows.Dispatcher.execute(Dispatcher.java:867)
> at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:270)
> at org.springframework.web.servlet.mvc.AbstractController.handleRequest(
> AbstractController.java:174)
> at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter
> .handle(SimpleControllerHandlerAdapter.java:50)
> at org.springframework.web.servlet.DispatcherServlet.
> doDispatch(DispatcherServlet.java:963)
> at org.springframework.web.servlet.DispatcherServlet.
> doService(DispatcherServlet.java:897)
> at org.springframework.web.servlet.FrameworkServlet.processRequest(
> FrameworkServlet.java:970)
> at org.springframework.web.servlet.FrameworkServlet.
> doPost(FrameworkServlet.java:872)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
> at org.springframework.web.servlet.FrameworkServlet.
> service(FrameworkServlet.java:846)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:291)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.apache.catalina.filters.CorsFilter.handleSimpleCORS(
> CorsFilter.java:301)
> at org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.java:169)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.ThreadLocalsCleanupFilter.doFilter(
> ThreadLocalsCleanupFilter.java:28)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
> SpringDelegatingFilter.java:75)
> at org.geoserver.monitor.MonitorFilter.doFilter(MonitorFilter.java:144)
> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
> SpringDelegatingFilter.java:71)
> at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.
> doFilterInternal(OpenSessionInViewFilter.java:231)
> at org.springframework.web.filter.OncePerRequestFilter.
> doFilter(OncePerRequestFilter.java:107)
> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
> SpringDelegatingFilter.java:71)
> at org.geoserver.wms.animate.AnimatorFilter.doFilter(
> AnimatorFilter.java:71)
> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
> SpringDelegatingFilter.java:71)
> at org.geoserver.filters.SpringDelegatingFilter.doFilter(
> SpringDelegatingFilter.java:46)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.platform.AdvancedDispatchFilter.doFilter(
> AdvancedDispatchFilter.java:50)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.springframework.security.web.FilterChainProxy$
> VirtualFilterChain.doFilter(FilterChainProxy.java:316)
> at org.geoserver.security.filter.GeoServerCompositeFilter$
> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:69)
> at org.springframework.security.web.access.intercept.
> FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:126)
> at org.springframework.security.web.access.intercept.
> FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:90)
> at org.geoserver.security.filter.GeoServerCompositeFilter$
> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:73)
> at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(
> GeoServerCompositeFilter.java:92)
> at org.springframework.security.web.FilterChainProxy$
> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
> at org.geoserver.security.filter.GeoServerCompositeFilter$
> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:69)
> at org.springframework.security.web.access.ExceptionTranslationFilter.
> doFilter(ExceptionTranslationFilter.java:114)
> at org.geoserver.security.filter.GeoServerCompositeFilter$
> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:73)
> at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(
> GeoServerCompositeFilter.java:92)
> at org.springframework.security.web.FilterChainProxy$
> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
> at org.geoserver.security.filter.GeoServerAnonymousAuthenticati
> onFilter.doFilter(GeoServerAnonymousAuthenticationFilter.java:54)
> at org.springframework.security.web.FilterChainProxy$
> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
> at org.geoserver.security.filter.GeoServerCompositeFilter$
> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:69)
> at org.springframework.security.web.context.SecurityContextPersistenceFilt
> er.doFilter(SecurityContextPersistenceFilter.java:91)
> at org.geoserver.security.filter.GeoServerSecurityContextPersis
> tenceFilter$1.doFilter(GeoServerSecurityContextPersistenceFilter.java:53)
> at org.geoserver.security.filter.GeoServerCompositeFilter$
> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:73)
> at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(
> GeoServerCompositeFilter.java:92)
> at org.springframework.security.web.FilterChainProxy$
> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
> at org.springframework.security.web.FilterChainProxy.doFilterInternal(
> FilterChainProxy.java:213)
> at org.springframework.security.web.FilterChainProxy.doFilter(
> FilterChainProxy.java:176)
> at org.geoserver.security.GeoServerSecurityFilterChainProxy.doFilter(
> GeoServerSecurityFilterChainProxy.java:152)
> at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(
> DelegatingFilterProxy.java:346)
> at org.springframework.web.filter.DelegatingFilterProxy.doFilter(
> DelegatingFilterProxy.java:262)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:88)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.XFrameOptionsFilter.doFilter(
> XFrameOptionsFilter.java:89)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:42)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.SessionDebugFilter.doFilter(
> SessionDebugFilter.java:48)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.geoserver.filters.FlushSafeFilter.doFilter(FlushSafeFilter.java:44)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.springframework.web.filter.CharacterEncodingFilter.
> doFilterInternal(CharacterEncodingFilter.java:197)
> at org.springframework.web.filter.OncePerRequestFilter.
> doFilter(OncePerRequestFilter.java:107)
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> ApplicationFilterChain.java:239)
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> ApplicationFilterChain.java:206)
> at org.apache.catalina.core.StandardWrapperValve.invoke(
> StandardWrapperValve.java:219)
> at org.apache.catalina.core.StandardContextValve.invoke(
> StandardContextValve.java:106)
> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
> AuthenticatorBase.java:502)
> at org.apache.catalina.core.StandardHostValve.invoke(
> StandardHostValve.java:142)
> at org.apache.catalina.valves.ErrorReportValve.invoke(
> ErrorReportValve.java:79)
> at org.apache.catalina.valves.AbstractAccessLogValve.invoke(
> AbstractAccessLogValve.java:617)
> at org.apache.catalina.core.StandardEngineValve.invoke(
> StandardEngineValve.java:88)
> at org.apache.catalina.connector.CoyoteAdapter.service(
> CoyoteAdapter.java:518)
> at org.apache.coyote.http11.AbstractHttp11Processor.process(
> AbstractHttp11Processor.java:1091)
> at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.
> process(AbstractProtocol.java:668)
> at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.
> doRun(NioEndpoint.java:1521)
> at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.
> run(NioEndpoint.java:1478)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(
> ThreadPoolExecutor.java:1142)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(
> ThreadPoolExecutor.java:617)
> at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(
> TaskThread.java:61)
> at java.lang.Thread.run(Thread.java:745)
>
> On Thu, Jun 14, 2018 at 5:06 PM, Ben Caradoc-Davies <b...@transient.nz>
> wrote:
>
>> Todd,
>>
>> I do not think the namespace matches. You have: xmlns:aoi="aoi" and
>> targetNamespace="aoi" which I think should be something like (for
>> example)): xmlns:aoi="http://www.tcartadata.com/aoi"; and
>> targetNamespace="http://www.tcartadata.com/aoi";.
>>
>> Please check your workspace settings for the "aoi" workspace and confirm
>> that the namespace is *not* "aoi". It should an an HTTP URI. It does not
>> need to be resolvable. In my example above I suggest something like: "
>> http://www.tcartadata.com/aoi"; but it could be anything. I would not use
>> a service URL.
>>
>> The workspace namespace *must* match the xmlns *namespace* in your
>> request ("http://www.tcartadata.com/aoi";), not the *namespace prefix*
>> ("aoi"). GeoServer defaults to using namespace prefix equal to workspace
>> name and is quite permissive in many GET circumstances but a XML POST must
>> match exactly.
>>
>> Kind regards,
>> Ben.
>>
>>
>> On 15/06/18 10:50, Todd Jacobus wrote:
>>
>>> Thanks again Ben,
>>>
>>> Here's the DescribeFeatureType response:
>>>
>>> <xsd:schema xmlns:aoi="aoi" xmlns:gml="http://www.opengis.net/gml";
>>> xmlns:xsd="http://www.w3.org/2001/XMLSchema";
>>> elementFormDefault="qualified"
>>> targetNamespace="aoi">
>>> <xsd:import namespace="http://www.opengis.net/gml"; schemaLocation="
>>> http://www.tcartadata.com:80/geoserver/schemas/gml/3.1.1/base/gml.xsd"/>
>>> <xsd:complexType name="aoi_featuresType">
>>> <xsd:complexContent>
>>> <xsd:extension base="gml:AbstractFeatureType">
>>> <xsd:sequence>
>>> <xsd:element maxOccurs="1" minOccurs="0" name="geom" nillable="true"
>>> type="gml:PointPropertyType"/>
>>> </xsd:sequence>
>>> </xsd:extension>
>>> </xsd:complexContent>
>>> </xsd:complexType>
>>> <xsd:element name="aoi_features" substitutionGroup="gml:_Feature"
>>> type="aoi:aoi_featuresType"/>
>>> </xsd:schema>
>>>
>>> As far as I can tell, the namespace matches, though, I'm still new at
>>> WFS-T
>>> so I could be missing something.
>>>
>>> It looks like I can get a GetFeature response as well (of course, there's
>>> nothing in the database table yet):
>>>
>>> url:
>>> http://www.tcartadata.com/geoserver/wfs?service=wfs&version=
>>> 1.1.0&request=GetFeature&typeNames=aoi:aoi_features
>>>
>>> <wfs:FeatureCollection xmlns:xs="http://www.w3.org/2001/XMLSchema";
>>> xmlns:wfs="http://www.opengis.net/wfs"; xmlns:gml="http://www.opengis.
>>> net/gml"
>>> xmlns:aoi="aoi" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>>> numberOfFeatures="0" timeStamp="2018-06-14T22:45:25.259Z"
>>> xsi:schemaLocation="http://www.opengis.net/wfs
>>> http://www.tcartadata.com:80/geoserver/schemas/wfs/1.1.0/wfs.xsd aoi
>>> http://www.tcartadata.com:80/geoserver/wfs?service=WFS&versi
>>> on=1.1.0&request=DescribeFeatureType&typeName=aoi%3Aaoi_features
>>> "/>
>>>
>>> Thanks again!
>>>
>>> Best,
>>> Todd
>>>
>>> On Thu, Jun 14, 2018 at 4:33 PM, Ben Caradoc-Davies <b...@transient.nz>
>>> wrote:
>>>
>>> Todd,
>>>>
>>>> what is the namespace of the aoi workspace? Does it match the xmlns
>>>> below?
>>>>
>>>> Are you able to get a WFS 1.1 GetFeature response?
>>>>
>>>> Kind regards,
>>>> Ben.
>>>>
>>>> On 15/06/18 10:29, Todd Jacobus wrote:
>>>>
>>>>    Hi Ben,
>>>>>
>>>>> Thanks very much for the help.  I have since migrated to OpenLayers
>>>>> since
>>>>> they have a function that writes the transaction GML for you, which has
>>>>> made things much simpler.  However, I would love to ask another
>>>>> question.
>>>>> I'm seeing a " Feature type 'aoi_features' is not available" error
>>>>> (I'll
>>>>> paste the trace bellow).  I checked the logs on start-up and it seems
>>>>> that
>>>>> WFS is enabled on the workspace.  I see two broad possibilities:
>>>>>
>>>>>
>>>>>      1. The namespace is still not specified correctly in the GML as
>>>>> sent
>>>>> out
>>>>>      by OpenLayer (I'll paste the new GML request below).  My
>>>>> workspace =
>>>>> aoi,
>>>>>      data-store = aoi_store, layer = aoi_features
>>>>>         1. my data store is a postgis database and the 'aoi_features'
>>>>> layer
>>>>>         is a table with just an ID and GEOM column.
>>>>>      2. The workspace is not configured correctly on the GeoServer side
>>>>>         1. Other than checking the box to enable transactions, I'm not
>>>>> sure
>>>>>
>>>>>         what else to configure here.
>>>>>
>>>>>
>>>>> Thanks again for your help!
>>>>>
>>>>> Best,
>>>>> Todd
>>>>>
>>>>> my GML:
>>>>>
>>>>> <Transaction xmlns="http://www.opengis.net/wfs"; service="WFS"
>>>>> version="1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>>>>> xsi:schemaLocation="http://www.opengis.net/wfs
>>>>> http://schemas.opengis.net/
>>>>> wfs/1.1.0/wfs.xsd">
>>>>> <Insert>
>>>>> <aoi_features xmlns="http://www.tcartadata.com/geoserver/wfs/aoi";>
>>>>> <geometry>
>>>>> <Polygon xmlns="http://www.opengis.net/gml"; srsName="EPSG:3857">
>>>>> <exterior>
>>>>> <LinearRing srsName="EPSG:3857">
>>>>> <posList srsDimension="2">-14079089.113903182 5126784.361143341
>>>>> -14196496.389349211 4138606.4594725836 -13413781.219709007
>>>>> 2622095.8182946863 -12063597.552079653 2817774.6107047377
>>>>> -11760295.423844075 4275581.614159619 -12679985.748171315
>>>>> 5048512.844179321
>>>>> -14079089.113903182 5126784.361143341
>>>>> </posList>
>>>>> </LinearRing>
>>>>> </exterior>
>>>>> </Polygon>
>>>>> </geometry>
>>>>> </aoi_features>
>>>>> </Insert>
>>>>> </Transaction>
>>>>>
>>>>> Here's the error trace from the logs:
>>>>>
>>>>> 2018-06-14 22:28:59,599 INFO [geoserver.wfs] -
>>>>> Request: getServiceInfo
>>>>> 2018-06-14 22:28:59,601 DEBUG [geotools.xml] - schemaLocation found:
>>>>> http://www.opengis.net/wfs http://schemas.opengis.net/wfs
>>>>> /1.1.0/wfs.xsd
>>>>> 2018-06-14 22:28:59,602 DEBUG [geotools.xml] - Found override for
>>>>> http://www.opengis.net/wfs: http://schemas.opengis.net/wfs
>>>>> /1.1.0/wfs.xsd
>>>>> ==>
>>>>> jar:file:/home/tcartada/appservers/apache-tomcat-8x/
>>>>> webapps/geoserver/WEB-INF/lib/gs-wfs-2.13.0.jar!/org/
>>>>> geoserver/wfs/xml/v1_1_0/wfs.xsd
>>>>> 2018-06-14 22:28:59,603 DEBUG [geotools.xml] - Could not find
>>>>> declaration
>>>>> for: {http://www.tcartadata.com/geoserver/wfs/aoi}aoi_features.
>>>>> Checking
>>>>> if
>>>>> containing type declares a single particle.
>>>>> 2018-06-14 22:28:59,604 DEBUG [geotools.xml] - Could not find
>>>>> declaration
>>>>> for: {http://www.tcartadata.com/geoserver/wfs/aoi}geometry. Checking
>>>>> if
>>>>> containing type declares a single particle.
>>>>> 2018-06-14 22:28:59,604 DEBUG [geotools.xml] - Could not find
>>>>> declaration
>>>>> for: {http://www.tcartadata.com/geoserver/wfs/aoi}geometry. Performing
>>>>> lookup by ignoring namespace
>>>>> 2018-06-14 22:28:59,604 DEBUG [geotools.xml] - Could not find
>>>>> declaration
>>>>> for: {http://www.tcartadata.com/geoserver/wfs/aoi}geometry. Creating a
>>>>> mock
>>>>> element declaration and parsing anyways...
>>>>> 2018-06-14 22:28:59,610 DEBUG [geoserver.wfs] - Locating FeatureSource
>>>>> uri:'
>>>>> http://www.tcartadata.com/geoserver/wfs/aoi' name:'aoi_features'
>>>>> 2018-06-14 22:28:59,610 ERROR [geoserver.ows] -
>>>>> 2018-06-14 21:47:24,323 ERROR [geoserver.ows] -
>>>>> org.geoserver.wfs.WFSTransactionException: Feature type
>>>>> 'aoi_features' is
>>>>> not available:
>>>>> at org.geoserver.wfs.Transaction.execute(Transaction.java:221)
>>>>> at org.geoserver.wfs.Transaction.transaction(Transaction.java:109)
>>>>> at org.geoserver.wfs.DefaultWebFeatureService.transaction(
>>>>> DefaultWebFeatureService.java:172)
>>>>> 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 org.springframework.aop.support.AopUtils.invokeJoinpointUsin
>>>>> gReflection
>>>>> (AopUtils.java:333)
>>>>> at org.springframework.aop.framework.ReflectiveMethodInvocation.
>>>>> invokeJoinpoint(ReflectiveMethodInvocation.java:190)
>>>>> at org.springframework.aop.framework.ReflectiveMethodInvocation
>>>>> .proceed(
>>>>> ReflectiveMethodInvocation.java:157)
>>>>> at org.geoserver.ows.util.RequestObjectLogger.invoke(
>>>>> RequestObjectLogger.java:55)
>>>>> at org.springframework.aop.framework.ReflectiveMethodInvocation
>>>>> .proceed(
>>>>> ReflectiveMethodInvocation.java:179)
>>>>> at org.springframework.aop.framework.JdkDynamicAopProxy.
>>>>> invoke(JdkDynamicAopProxy.java:213)
>>>>> at com.sun.proxy.$Proxy95.transaction(Unknown Source)
>>>>> 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 org.geoserver.ows.Dispatcher.execute(Dispatcher.java:867)
>>>>> at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatche
>>>>> r.java:270)
>>>>> at org.springframework.web.servlet.mvc.AbstractController.handl
>>>>> eRequest(
>>>>> AbstractController.java:174)
>>>>> at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter
>>>>> .handle(SimpleControllerHandlerAdapter.java:50)
>>>>> at org.springframework.web.servlet.DispatcherServlet.
>>>>> doDispatch(DispatcherServlet.java:963)
>>>>> at org.springframework.web.servlet.DispatcherServlet.
>>>>> doService(DispatcherServlet.java:897)
>>>>> at org.springframework.web.servlet.FrameworkServlet.processRequest(
>>>>> FrameworkServlet.java:970)
>>>>> at org.springframework.web.servlet.FrameworkServlet.
>>>>> doPost(FrameworkServlet.java:872)
>>>>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
>>>>> at org.springframework.web.servlet.FrameworkServlet.
>>>>> service(FrameworkServlet.java:846)
>>>>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:291)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilte
>>>>> r.java:52)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.apache.catalina.filters.CorsFilter.handleSimpleCORS(
>>>>> CorsFilter.java:301)
>>>>> at org.apache.catalina.filters.CorsFilter.doFilter(CorsFilter.j
>>>>> ava:169)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.ThreadLocalsCleanupFilter.doFilter(
>>>>> ThreadLocalsCleanupFilter.java:28)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
>>>>> SpringDelegatingFilter.java:75)
>>>>> at org.geoserver.monitor.MonitorFilter.doFilter(MonitorFilter.j
>>>>> ava:144)
>>>>> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
>>>>> SpringDelegatingFilter.java:71)
>>>>> at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.
>>>>> doFilterInternal(OpenSessionInViewFilter.java:231)
>>>>> at org.springframework.web.filter.OncePerRequestFilter.
>>>>> doFilter(OncePerRequestFilter.java:107)
>>>>> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
>>>>> SpringDelegatingFilter.java:71)
>>>>> at org.geoserver.wms.animate.AnimatorFilter.doFilter(AnimatorFi
>>>>> lter.java:71)
>>>>> at org.geoserver.filters.SpringDelegatingFilter$Chain.doFilter(
>>>>> SpringDelegatingFilter.java:71)
>>>>> at org.geoserver.filters.SpringDelegatingFilter.doFilter(
>>>>> SpringDelegatingFilter.java:46)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.platform.AdvancedDispatchFilter.doFilter(
>>>>> AdvancedDispatchFilter.java:50)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.springframework.security.web.FilterChainProxy$
>>>>> VirtualFilterChain.doFilter(FilterChainProxy.java:316)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter$
>>>>> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:69)
>>>>> at org.springframework.security.web.access.intercept.
>>>>> FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:126)
>>>>> at org.springframework.security.web.access.intercept.
>>>>> FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:90)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter$
>>>>> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:73)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(
>>>>> GeoServerCompositeFilter.java:92)
>>>>> at org.springframework.security.web.FilterChainProxy$
>>>>> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter$
>>>>> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:69)
>>>>> at org.springframework.security.web.access.ExceptionTranslationFilter.
>>>>> doFilter(ExceptionTranslationFilter.java:114)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter$
>>>>> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:73)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(
>>>>> GeoServerCompositeFilter.java:92)
>>>>> at org.springframework.security.web.FilterChainProxy$
>>>>> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
>>>>> at org.geoserver.security.filter.GeoServerAnonymousAuthenticati
>>>>> onFilter.doFilter(GeoServerAnonymousAuthenticationFilter.java:54)
>>>>> at org.springframework.security.web.FilterChainProxy$
>>>>> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter$
>>>>> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:69)
>>>>> at org.springframework.security.web.context.SecurityContextPers
>>>>> istenceFilt
>>>>> er.doFilter(SecurityContextPersistenceFilter.java:91)
>>>>> at org.geoserver.security.filter.GeoServerSecurityContextPersis
>>>>> tenceFilter$1.doFilter(GeoServerSecurityContextPersistenceFi
>>>>> lter.java:53)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter$
>>>>> NestedFilterChain.doFilter(GeoServerCompositeFilter.java:73)
>>>>> at org.geoserver.security.filter.GeoServerCompositeFilter.doFilter(
>>>>> GeoServerCompositeFilter.java:92)
>>>>> at org.springframework.security.web.FilterChainProxy$
>>>>> VirtualFilterChain.doFilter(FilterChainProxy.java:330)
>>>>> at org.springframework.security.web.FilterChainProxy.doFilterInternal(
>>>>> FilterChainProxy.java:213)
>>>>> at org.springframework.security.web.FilterChainProxy.doFilter(
>>>>> FilterChainProxy.java:176)
>>>>> at org.geoserver.security.GeoServerSecurityFilterChainProxy.doFilter(
>>>>> GeoServerSecurityFilterChainProxy.java:152)
>>>>> at org.springframework.web.filter.DelegatingFilterProxy.invokeD
>>>>> elegate(
>>>>> DelegatingFilterProxy.java:346)
>>>>> at org.springframework.web.filter.DelegatingFilterProxy.doFilter(
>>>>> DelegatingFilterProxy.java:262)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:88)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.XFrameOptionsFilter.doFilter(
>>>>> XFrameOptionsFilter.java:89)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:42)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.SessionDebugFilter.doFilter(
>>>>> SessionDebugFilter.java:48)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.geoserver.filters.FlushSafeFilter.doFilter(FlushSafeFilt
>>>>> er.java:44)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.springframework.web.filter.CharacterEncodingFilter.doFil
>>>>> terInternal(
>>>>> CharacterEncodingFilter.java:197)
>>>>> at org.springframework.web.filter.OncePerRequestFilter.
>>>>> doFilter(OncePerRequestFilter.java:107)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>>>>> ApplicationFilterChain.java:239)
>>>>> at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>>>>> ApplicationFilterChain.java:206)
>>>>> at org.apache.catalina.core.StandardWrapperValve.invoke(
>>>>> StandardWrapperValve.java:219)
>>>>> at org.apache.catalina.core.StandardContextValve.invoke(
>>>>> StandardContextValve.java:106)
>>>>> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
>>>>> AuthenticatorBase.java:502)
>>>>> at org.apache.catalina.core.StandardHostValve.invoke(
>>>>> StandardHostValve.java:142)
>>>>> at org.apache.catalina.valves.ErrorReportValve.invoke(
>>>>> ErrorReportValve.java:79)
>>>>> at org.apache.catalina.valves.AbstractAccessLogValve.invoke(
>>>>> AbstractAccessLogValve.java:617)
>>>>> at org.apache.catalina.core.StandardEngineValve.invoke(
>>>>> StandardEngineValve.java:88)
>>>>> at org.apache.catalina.connector.CoyoteAdapter.service(
>>>>> CoyoteAdapter.java:518)
>>>>> at org.apache.coyote.http11.AbstractHttp11Processor.process(
>>>>> AbstractHttp11Processor.java:1091)
>>>>> at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.
>>>>> process(AbstractProtocol.java:668)
>>>>> at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.
>>>>> doRun(NioEndpoint.java:1521)
>>>>> at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.
>>>>> run(NioEndpoint.java:1478)
>>>>> at java.util.concurrent.ThreadPoolExecutor.runWorker(
>>>>> ThreadPoolExecutor.java:1142)
>>>>> at java.util.concurrent.ThreadPoolExecutor$Worker.run(
>>>>> ThreadPoolExecutor.java:617)
>>>>> at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(
>>>>> TaskThread.java:61)
>>>>> at java.lang.Thread.run(Thread.java:745)
>>>>>
>>>>>
>>>>> On Wed, Jun 13, 2018 at 5:06 PM, Ben Caradoc-Davies <b...@transient.nz>
>>>>> wrote:
>>>>>
>>>>> Todd,
>>>>>
>>>>>>
>>>>>> secondary namespaces are only required for the app-schema data store,
>>>>>> which does not support WFS-T.
>>>>>>
>>>>>> For non-app-schema data stores, namespace prefixes should be defined
>>>>>> in
>>>>>> the WFS-T request document. The error you see is consistent with an
>>>>>> undefined namespace prefix. Try adding an xmlns:aoi_points attribute
>>>>>> to
>>>>>> the
>>>>>> wfs:Transaction element.
>>>>>>
>>>>>> Kind regards,
>>>>>> Ben.
>>>>>>
>>>>>>
>>>>>> On 14/06/18 06:39, Todd Jacobus wrote:
>>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>>>
>>>>>>> Thank you for viewing this post.  I'm trying to set up a simple WFS-T
>>>>>>> datastore on a PostGIS database table that talks to a leaflet map.
>>>>>>> I'm
>>>>>>> using jquery ajax to send a transaction POST request by sending the
>>>>>>> transaction-insert xml stored as a string.  The request seems to go
>>>>>>> through
>>>>>>> just fine, but in the GeoServer logs I see a namespace error:
>>>>>>>
>>>>>>>     "2018-06-13 19:11:16,073 ERROR [geoserver.ows] -
>>>>>>> org.xml.sax.SAXParseException; lineNumber: 11; columnNumber: 26; The
>>>>>>> prefix
>>>>>>> "aoi_points" for element "aoi_points:wfst_aoi" is not bound."
>>>>>>>
>>>>>>> Some googling directed me to the secondary namespaces
>>>>>>> <http://docs.geoserver.org/stable/en/user/data/app-schema/
>>>>>>> secondary-namespaces.html#when-to-configure-for-secondary-na
>>>>>>> mespaces>
>>>>>>> page in the docs, but I'm not sure what's going on here.  A couple of
>>>>>>> things:
>>>>>>>
>>>>>>>
>>>>>>>       1.  Can someone explain why (or if) a secondary namespace
>>>>>>> might be
>>>>>>>       necessary in this case?
>>>>>>>       2.  How can I reference a database table properly in the xml
>>>>>>> transaction
>>>>>>>
>>>>>>>       request?
>>>>>>>
>>>>>>> Here's the full xml request I'm sending to GeoServer:
>>>>>>>
>>>>>>>            '<wfs:Transaction'
>>>>>>>            '  service="WFS"\n'
>>>>>>> '  version="1.1.0"\n'
>>>>>>>            '  xmlns:grp="http://lab.georepublic.info"\n'
>>>>>>> '  xmlns:wfs="http://www.opengis.net/wfs"\n'
>>>>>>> '  xmlns:gml="http://www.opengis.net/gml"\n'
>>>>>>> '  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\n'
>>>>>>> '  xsi:schemaLocation="http://www.opengis.net/wfs\n'
>>>>>>> '
>>>>>>> http://schemas.opengis.net/wfs/1.1.0/WFS-transaction.xsd\n'
>>>>>>> '
>>>>>>> http://www.example.com/geoserver/wfs/DescribeFeatureType?
>>>>>>> typename=aoi:wfst_aoi
>>>>>>> ">\n'
>>>>>>> '  <wfs:Insert>\n'
>>>>>>> '    <aoi_points:wfst_aoi>\n'
>>>>>>> '      <wfst_aoi:geom>\n'
>>>>>>> '        <gml:Polygon srsName="urn:x-ogc:def:crs:EPSG:4326">\n'
>>>>>>> '          <gml:coordinates decimal="." cs="," ts=" ">' +
>>>>>>> geoJson[0].geometry.coordinates + '</gml:coordinates>\n'
>>>>>>> '        </gml:Polygon>\n'
>>>>>>> '      </wfst_aoi:geom>\n'
>>>>>>> '    </aoi_points:wfst_aoi>\n'
>>>>>>> '  </wfs:Insert>\n'
>>>>>>> '</wfs:Transaction>'
>>>>>>>
>>>>>>> Thanks very much!
>>>>>>>
>>>>>>> Best,
>>>>>>> Todd
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------
>>>>>>> ------------------
>>>>>>> Check out the vibrant tech community on one of the world's most
>>>>>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> Geoserver-users mailing list
>>>>>>>
>>>>>>> Please make sure you read the following two resources before posting
>>>>>>> to
>>>>>>> this list:
>>>>>>> - Earning your support instead of buying it, but Ian Turton:
>>>>>>> http://www.ianturton.com/talks/foss4g.html#/
>>>>>>> - The GeoServer user list posting guidelines:
>>>>>>> http://geoserver.org/comm/userlist-guidelines.html
>>>>>>>
>>>>>>> If you want to request a feature or an improvement, also see this:
>>>>>>> https://github.com/geoserver/geoserver/wiki/Successfully-req
>>>>>>> uesting-and-integrating-new-features-and-improvements-in-GeoServer
>>>>>>>
>>>>>>>
>>>>>>> Geoserver-users@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>>
>>>>>> Ben Caradoc-Davies <b...@transient.nz>
>>>>>> Director
>>>>>> Transient Software Limited <https://transient.nz/>
>>>>>> New Zealand
>>>>>>
>>>>>>
>>>>>>
>>>>> --
>>>> Ben Caradoc-Davies <b...@transient.nz>
>>>> Director
>>>> Transient Software Limited <https://transient.nz/>
>>>> New Zealand
>>>>
>>>>
>>>
>> --
>> Ben Caradoc-Davies <b...@transient.nz>
>> Director
>> Transient Software Limited <https://transient.nz/>
>> New Zealand
>>
>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to