Thanks Ben, The error is intermittent in that stopping and starting GeoServer may reproduce the error. However, once the error occurs, any request for that feature results in the error.
So the error logs can be readily viewed, but don't seem to be informative. I'll see if I can find someone to help me set-up the Eclipse de-bugging environment. Cheers Bruce Simons Information Modeller Land and Water/ Environmental Information Infrastructures E: [email protected] T: +61 3 9252 6514 M: +61 475 954 391 PO Box 56, Highett, Victoria, 3190 -----Original Message----- From: Ben Caradoc-Davies [mailto:[email protected]] Sent: Tuesday, 12 May 2015 9:23 AM To: Simons, Bruce (L&W, Highett); [email protected] Subject: Re: [Geoserver-users] GeoServer app-schema: No FID expression found for type Bruce, this is a nasty one as it is intermittent. The first step has to be reproducing the failure. I suggest running a shell script that makes a hundred or so concurrent requests against a test GeoServer instance using curl: #!/bin/bash i=0 while(($i<100)) do curl 'http://localhost:8080/geoserver/wfs?service=WFS&version=2.0.0&request=GetFeature&typenames=gwml-well:GW_Well' & ((i=$i+1)) done You could also try sequential requests (note no "&"): #!/bin/bash i=0 while(($i<100)) do curl 'http://localhost:8080/geoserver/wfs?service=WFS&version=2.0.0&request=GetFeature&typenames=gwml-well:GW_Well' ((i=$i+1)) done You can also try multiple concurrent requests for different types. #!/bin/bash i=0 while(($i<100)) do curl 'http://localhost:8080/geoserver/wfs?service=WFS&version=2.0.0&request=GetFeature&typenames=gwml-well:GW_Well' & curl 'http://localhost:8080/geoserver/wfs?service=WFS&version=2.0.0&request=GetFeature&typenames=ns:SomeOtherType' & ((i=$i+1)) done The requests could be for a range of feature types. The test instance might use the same database backend, but could also use a test copy of the database to avoid inconveniencing other users. When you are able to reproduce the failure in a test environment, the next step is to catch it in the debugger. The test GeoServer instance could be in tomcat, configured for remote debugging, but it might be easier to just launch it in Eclipse on your desktop in debug mode. Setting a breakpoint at UnmappingFilterVisitor:307 in Eclipse will allow you to catch GeoServer in the act and examine the state that caused the failure. Kind regards, Ben. On 11/05/15 17:20, [email protected] wrote: > Hi Ben, > I'm still getting this intermittent "No FID expression found for type x" > error. > Stopping and starting the TomCat service, without changing the configuration > files, will sometimes result in a valid feature query response, or result in > the same error for a different GetFeature request. > > Pavel had a quick look at the problem earlier this year but couldn't identify > any obvious cause. Can you suggest a way forward? > > Cheers > Bruce Simons > Information Modeller > Land and Water/ Environmental Information Infrastructures > E: [email protected] T: +61 3 9252 6514 M: +61 475 954 391 PO Box > 56, Highett, Victoria, 3190 > > -----Original Message----- > From: Simons, Bruce (L&W, Highett) > Sent: Monday, 13 April 2015 9:48 AM > To: 'Ben Caradoc-Davies'; [email protected] > Subject: RE: [Geoserver-users] GeoServer app-schema: No FID expression > found for type > > Hi Ben, > I'm not accessing app-schema feature types using "workspace-specific" service > URLs. > When the services work they will respond to "workspace-specific" service > URLs, but with the non-workspace aliases replaced with "null" (as per the > [GEOS-6014] note). > > When the configuration is only one Feature with no feature links it doesn't > seem to fail (although the maxFeatures=5 is slow), but adding a single > FEATURE_LINK can give (but not always) the FID error. > > I'm wondering if it could be related to the database rather than the > Geoserver configuration? > > Cheers > Bruce Simons > Information Modeller > Land and Water/ Environmental Information Infrastructures > E: [email protected] T: +61 3 9252 6514 M: +61 475 954 391 PO Box > 56, Highett, Victoria, 3190 > > -----Original Message----- > From: Ben Caradoc-Davies [mailto:[email protected]] > Sent: Monday, 13 April 2015 9:19 AM > To: Simons, Bruce (L&W, Highett); > [email protected] > Subject: Re: [Geoserver-users] GeoServer app-schema: No FID expression > found for type > > Bruce, > > are you accessing app-schema feature types using "workspace-specific" > service URLs or using base endpoints? We have seen namespace corruption: > > [GEOS-6014] app-schema workspace-specific service URL corrupts > namespaces of other workspaces > https://jira.codehaus.org/browse/GEOS-6014 > > ****** > > Accessing an app-schema data store via a workspace-specific service URL > causes namespaces of other workspaces to be encoded as null, even simple > feature namespaces. > > To reproduce: > > (1) Start with the geoserver release data directory (containing topp > workspace) and unpack the attached gsmlp.zip to create a single app-schema > type, and start GeoServer: > > (2) Access the app-schema type via its workspace-specific service URL: > http://localhost:8080/geoserver/gsmlp/ows?service=WFS&version=1.1.0&re > quest=GetFeature&typename=gsmlp:GeologicUnitView > > (the ows?service=WFS and wfs? form work the same) > > (3) Access topp:tasmania_roads by any means: > http://localhost:8080/geoserver/wfs?version=1.1.0&request=GetFeature&t > ypename=topp:tasmania_roads > http://localhost:8080/geoserver/topp/ows?service=WFS&version=1.1.0&req > uest=GetFeature&typename=topp:tasmania_roads > > Result: response containing: > > <gml:featureMember> > <null:tasmania_roads gml:id="tasmania_roads.1"> <null:the_geom> [...] > > This behaviour occurs if and only if the gsmlp layer is accessed first, > before the topp layer, and only if the gsmlp layer is accessed through its > workspace-specific service URL. Accessing the topp layer first or accessing > the gsmlp layer through a global URL do not cause the corruption: > http://localhost:8080/geoserver/ows?service=WFS&version=1.1.0&request= > GetFeature&typename=gsmlp:GeologicUnitView > > Looks like app-schema workspace-specific service URLs are corrupting the > namespaces of other workspaces. > > Workaround: do not use app-schema workspace-specific service URLs. > > ****** > > Kind regards, > Ben. > > On 13/04/15 09:59, [email protected] wrote: >> Hi Ben, >> - What version of GeoServer are you using? >> Geoserver 2.6.1 >> >> - How long does it take for a failure to occur? Are there intervening >> requests? >> Failure is straight away, with no other requests being made. >> >> - When you start and stop tomcat, does this make the configuration work >> immediately (you wrote "eventually)"? How long does it keep working? >> Stopping and starting Tomcat may get it to work. If it doesn't, then I keep >> stopping and starting Tomcat until I no longer get the FID error for that >> feature. However, one of the other features may now produce the error. Once >> the feature request is not giving the FID error it seems to continue working. >> >> I'll revisit the namespaces and check them all again. >> >> Thanks >> Bruce Simons >> Information Modeller >> Land and Water/ Environmental Information Infrastructures >> E: [email protected] T: +61 3 9252 6514 M: +61 475 954 391 PO Box >> 56, Highett, Victoria, 3190 >> >> -----Original Message----- >> From: [email protected] >> [mailto:[email protected]] >> Sent: Friday, 10 April 2015 6:30 PM >> To: [email protected] >> Subject: Geoserver-users Digest, Vol 107, Issue 26 >> >> Send Geoserver-users mailing list submissions to >> [email protected] >> >> To subscribe or unsubscribe via the World Wide Web, visit >> https://lists.sourceforge.net/lists/listinfo/geoserver-users >> or, via email, send a message with subject or body 'help' to >> [email protected] >> >> You can reach the person managing the list at >> [email protected] >> >> When replying, please edit your Subject line so it is more specific than >> "Re: Contents of Geoserver-users digest..." >> >> >> Today's Topics: >> >> 1. Re: GeoServer app-schema: No FID expression found for type >> (Ben Caradoc-Davies) >> 2. GeoServer Slowly Requests to Remote DB (Shadin) >> 3. Re: wfs 1.1.0 adds timezone to date attributes >> (Hochmeister Rudolf) >> 4. Re: wfs 1.1.0 adds timezone to date attributes >> (Rahkonen Jukka (MML)) >> >> >> --------------------------------------------------------------------- >> - >> >> Message: 1 >> Date: Fri, 10 Apr 2015 12:22:24 +1200 >> From: Ben Caradoc-Davies <[email protected]> >> Subject: Re: [Geoserver-users] GeoServer app-schema: No FID expression >> found for type >> To: [email protected], [email protected] >> Message-ID: <[email protected]> >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Hi Bruce, >> >> - What version of GeoServer are you using? >> >> - How long does it take for a failure to occur? Are there intervening >> requests? >> >> - When you start and stop tomcat, does this make the configuration work >> immediately (you wrote "eventually)"? How long does it keep working? >> >> This exception is thrown in GeoTools gt-app-schema >> UnmappingFilterVisitor:307 when it fails to translate an incoming request >> from properties and types in the application schema to source types >> generated from the database. >> >> One thing that might cause this unmapping to fail is a problem with >> namespaces. Please check that all your namespaces are correctly and >> consistently specified in your mapping files, workspaces, application >> schemas, and requests. >> >> Kind regards, >> Ben. >> >> On 10/04/15 10:17, [email protected] wrote: >>> Hi, >>> I'm getting an intermittent Geoserver app-schema error as a response to a >>> GetFeature request: >>> >>> java.lang.IllegalStateException: No FID expression found for type >>> [FeatureType]. Did you mean Expression.NIL? >>> No FID expression found for type [FeatureType]. Did you mean Expression.NIL? >>> >>> Where [FeatureType] depends on the feature being requested (e.g. >>> 'http://www.opengis.net/gwml-well/2.0:GW_Well'). >>> Stopping and starting TomCat (without changing any configuration files) >>> will eventually give a valid response for requests for that feature type, >>> but may now give the error for a different feature type. >>> >>> Reducing the number of properties and FEATURE_LINKs doesn't seem to >>> guarantee a working response. >>> GeoServer is running over a PostGres database. >>> Any ideas on where I should be looking to resolve the issue? >>> >>> Cheers >>> Bruce Simons >>> Information Modeller >>> Land and Water/ Environmental Information Infrastructures >>> E: [email protected]<mailto:[email protected]> T: +61 3 9252 >>> 6514 M: +61 475 954 391 PO Box 56, Highett, Victoria, 3190 -- Ben Caradoc-Davies <[email protected]> Director Transient Software Limited <http://transient.nz/> New Zealand ------------------------------------------------------------------------------ One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y _______________________________________________ Geoserver-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geoserver-users
