I’ve been trying to write the section on WFS cascading in my training course today but I’m unable to get any WFS (including a local GeoServer on another port) to work, Has anyone else seen this? When ever I try to create a layer it bombs out with
a root cause of
Caused by: java.lang.RuntimeException: Failed to resolve http://giswebservices.massgis.state.ma.us/geoserver/wfs?NAMESPACE=xmlns%28massgis%3Dhttp%3A%2F%2Fmassgis.state.ma.us%2Ffeaturetype%29&TYPENAME=massgis%3AAFREEMAN.AUDUBON_BIRD_S_V&REQUEST=DescribeFeatureType&VERSION=2.0.0&SERVICE=WFS at org.geotools.xml.resolver.SchemaResolver.resolve(SchemaResolver.java:207) at org.geotools.data.complex.config.EmfComplexFeatureReader.findSchemaNamespace(EmfComplexFeatureReader.java:138) at org.geotools.data.complex.config.EmfComplexFeatureReader.parse(EmfComplexFeatureReader.java:120) at org.geotools.data.wfs.impl.WFSContentDataAccess.getSchema(WFSContentDataAccess.java:197) at org.geotools.data.wfs.impl.WFSContentComplexFeatureSource.getSchema(WFSContentComplexFeatureSource.java:211) at org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:347) at org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:329) at org.geoserver.web.data.layer.NewLayerPage.buildLayerInfo(NewLayerPage.java:349)
If you paste that URL into a browser it works fine, so I’m not sure what the issue is, though I seem to recall a discussion about schemas a while back.
Anyone got some idea before I raise an issue and start digging?
cheers
Ian
···
Ian Turton
Ian,
this is the complex feature WFS client in gt-wfs-ng!
https://github.com/geotools/geotools/wiki/ComplexFeature-Parsing-and-Building-Support
Did you set your WFSDataStoreFactory:GML_COMPLIANCE_LEVEL to something greater than 0?
This is the AFAIK the OGC Simple Features Profile compliance level. SF-0 means simple features, and SF-1 or or SF-2 means complex features. Anything greater than zero should cause the simple feature client to be ignored.
Setting WFSDataStoreFactory:GML_COMPLIANCE_LEVEL to 0 seemed to allow me to add this service as a data store (but I did not try to publish anything).
Kind regards,
Ben.
On 12/02/16 06:04, Ian Turton wrote:
I've been trying to write the section on WFS cascading in my training
course today but I'm unable to get any WFS (including a local GeoServer on
another port) to work, Has anyone else seen this? When ever I try to create
a layer it bombs out with
a root cause of
Caused by: java.lang.RuntimeException: Failed to resolve
http://giswebservices.massgis.state.ma.us/geoserver/wfs?NAMESPACE=xmlns(massgis%3Dhttp%3A%2F%2Fmassgis.state.ma.us%2Ffeaturetype)&TYPENAME=massgis%3AAFREEMAN.AUDUBON_BIRD_S_V&REQUEST=DescribeFeatureType&VERSION=2.0.0&SERVICE=WFS
at
org.geotools.xml.resolver.SchemaResolver.resolve(SchemaResolver.java:207)
at
org.geotools.data.complex.config.EmfComplexFeatureReader.findSchemaNamespace(EmfComplexFeatureReader.java:138)
at
org.geotools.data.complex.config.EmfComplexFeatureReader.parse(EmfComplexFeatureReader.java:120)
at
org.geotools.data.wfs.impl.WFSContentDataAccess.getSchema(WFSContentDataAccess.java:197)
at
org.geotools.data.wfs.impl.WFSContentComplexFeatureSource.getSchema(WFSContentComplexFeatureSource.java:211)
at
org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:347)
at
org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:329)
at
org.geoserver.web.data.layer.NewLayerPage.buildLayerInfo(NewLayerPage.java:349)
If you paste that URL into a browser it works fine, so I'm not sure what
the issue is, though I seem to recall a discussion about schemas a while
back.
Anyone got some idea before I raise an issue and start digging?
cheers
Ian
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
I left all the other settings as default, so I’m fairly sure the gml level stayed as 0.
Ian
On 11 Feb 2016 19:13, “Ben Caradoc-Davies” <ben@anonymised.com> wrote:
Ian,
this is the complex feature WFS client in gt-wfs-ng!
https://github.com/geotools/geotools/wiki/ComplexFeature-Parsing-and-Building-Support
Did you set your WFSDataStoreFactory:GML_COMPLIANCE_LEVEL to something greater than 0?
This is the AFAIK the OGC Simple Features Profile compliance level. SF-0 means simple features, and SF-1 or or SF-2 means complex features. Anything greater than zero should cause the simple feature client to be ignored.
Setting WFSDataStoreFactory:GML_COMPLIANCE_LEVEL to 0 seemed to allow me to add this service as a data store (but I did not try to publish anything).
Kind regards,
Ben.
On 12/02/16 06:04, Ian Turton wrote:
I’ve been trying to write the section on WFS cascading in my training
course today but I’m unable to get any WFS (including a local GeoServer on
another port) to work, Has anyone else seen this? When ever I try to create
a layer it bombs out with
a root cause of
Caused by: java.lang.RuntimeException: Failed to resolve
http://giswebservices.massgis.state.ma.us/geoserver/wfs?NAMESPACE=xmlns%28massgis%3Dhttp%3A%2F%2Fmassgis.state.ma.us%2Ffeaturetype%29&TYPENAME=massgis%3AAFREEMAN.AUDUBON_BIRD_S_V&REQUEST=DescribeFeatureType&VERSION=2.0.0&SERVICE=WFS
at
org.geotools.xml.resolver.SchemaResolver.resolve(SchemaResolver.java:207)
at
org.geotools.data.complex.config.EmfComplexFeatureReader.findSchemaNamespace(EmfComplexFeatureReader.java:138)
at
org.geotools.data.complex.config.EmfComplexFeatureReader.parse(EmfComplexFeatureReader.java:120)
at
org.geotools.data.wfs.impl.WFSContentDataAccess.getSchema(WFSContentDataAccess.java:197)
at
org.geotools.data.wfs.impl.WFSContentComplexFeatureSource.getSchema(WFSContentComplexFeatureSource.java:211)
at
org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:347)
at
org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:329)
at
org.geoserver.web.data.layer.NewLayerPage.buildLayerInfo(NewLayerPage.java:349)
If you paste that URL into a browser it works fine, so I’m not sure what
the issue is, though I seem to recall a discussion about schemas a while
back.
Anyone got some idea before I raise an issue and start digging?
cheers
Ian
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
–
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
Ian,
I think this may be a bug caused by SPI classpath discovery order and the lack of a mechanism to choose between the simple and complex client. The first factory to match will be chosen to service your request to add a WFS data store. The order is undefined. Looking in the complex client SPI provider code (WFSDataAccessFactory), I see nothing that would stop it from attempting to service a simple feature endpoint; this makes sense because it should be happy with SF-0 services.
I am guessing that in this context, the complex client has not been configured to use a schema cache, and so will not resolve the capabilities document, and fails. This client is bleeding edge and should not be used for supported GeoServer functionality. I do not think this was ever intended. I have never got it to work against a live service, even in a GeoTools standalone test:
https://github.com/bencaradocdavies/geotools/commit/9e8d9c22d1f3ddfd0b180f7f53dae17457be9786
Try removing /META-INF/services/org.geotools.data.DataAccessFactory from the gt-jdbc-ng jar file to disable this provider, or use a 2.7.x release which all lack the complex feature client (first released in GeoTools 14-M0).
This must be fixed for 2.9.0 and 2.8.3. Perhaps disabling the complex client for WFSDataStoreFactory:GML_COMPLIANCE_LEVEL < 1?
Kind regards,
Ben.
On 12/02/16 09:37, Ian Turton wrote:
I left all the other settings as default, so I'm fairly sure the gml level
stayed as 0.
Ian
On 11 Feb 2016 19:13, "Ben Caradoc-Davies" <ben@anonymised.com> wrote:
Ian,
this is the complex feature WFS client in gt-wfs-ng!
https://github.com/geotools/geotools/wiki/ComplexFeature-Parsing-and-Building-Support
Did you set your WFSDataStoreFactory:GML_COMPLIANCE_LEVEL to something
greater than 0?
This is the AFAIK the OGC Simple Features Profile compliance level. SF-0
means simple features, and SF-1 or or SF-2 means complex features. Anything
greater than zero should cause the simple feature client to be ignored.
Setting WFSDataStoreFactory:GML_COMPLIANCE_LEVEL to 0 seemed to allow me
to add this service as a data store (but I did not try to publish anything).
Kind regards,
Ben.
On 12/02/16 06:04, Ian Turton wrote:
I've been trying to write the section on WFS cascading in my training
course today but I'm unable to get any WFS (including a local GeoServer on
another port) to work, Has anyone else seen this? When ever I try to
create
a layer it bombs out with
a root cause of
Caused by: java.lang.RuntimeException: Failed to resolve
http://giswebservices.massgis.state.ma.us/geoserver/wfs?NAMESPACE=xmlns(massgis%3Dhttp%3A%2F%2Fmassgis.state.ma.us%2Ffeaturetype)&TYPENAME=massgis%3AAFREEMAN.AUDUBON_BIRD_S_V&REQUEST=DescribeFeatureType&VERSION=2.0.0&SERVICE=WFS
at
org.geotools.xml.resolver.SchemaResolver.resolve(SchemaResolver.java:207)
at
org.geotools.data.complex.config.EmfComplexFeatureReader.findSchemaNamespace(EmfComplexFeatureReader.java:138)
at
org.geotools.data.complex.config.EmfComplexFeatureReader.parse(EmfComplexFeatureReader.java:120)
at
org.geotools.data.wfs.impl.WFSContentDataAccess.getSchema(WFSContentDataAccess.java:197)
at
org.geotools.data.wfs.impl.WFSContentComplexFeatureSource.getSchema(WFSContentComplexFeatureSource.java:211)
at
org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:347)
at
org.geoserver.catalog.CatalogBuilder.buildFeatureType(CatalogBuilder.java:329)
at
org.geoserver.web.data.layer.NewLayerPage.buildLayerInfo(NewLayerPage.java:349)
If you paste that URL into a browser it works fine, so I'm not sure what
the issue is, though I seem to recall a discussion about schemas a while
back.
Anyone got some idea before I raise an issue and start digging?
cheers
Ian
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
Ian, I am testing a fix for GeoTools master that implements this behaviour. I will also backport it to 2.8.x if it works for you.
On 12/02/16 10:39, Ben Caradoc-Davies wrote:
Perhaps disabling the complex client for
WFSDataStoreFactory:GML_COMPLIANCE_LEVEL < 1?
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
Ian,
I also needed to set the data source to WFS 1.1.0 before I could see something in OpenLayers, that is, this GetCapabilities URL:
http://giswebservices.massgis.state.ma.us/geoserver/wfs?service=WFS&version=1.1.0&request=GetCapabilities
This is IIRC WFS 1.1.0 is the maximum WFS version supported by the simple feature client.
I have attached a single-image WMS from the layer preview for
massgis_AFREEMAN.AUDUBON_BIRD_S_V made with:
http://localhost:8080/geoserver/sf/wms?service=WMS&version=1.1.0&request=GetMap&layers=sf:massgis_AFREEMAN.AUDUBON_BIRD_S_V&styles=&bbox=29632.757361911965,772120.2117686863,339334.73455686856,974345.1220567727&width=768&height=501&srs=EPSG:26986&format=image%2Fpng
You must also remove /META-INF/services/org.geotools.data.DataAccessFactory from the gt-jdbc-ng jar file to disable the complex feature client. See:
[GEOT-5361] Complex feature WFS client breaks GeoServer external WFS data store
https://osgeo-org.atlassian.net/browse/GEOT-5361
Kind regards,
Ben
On 12/02/16 11:04, Ben Caradoc-Davies wrote:
Ian, I am testing a fix for GeoTools master that implements this
behaviour. I will also backport it to 2.8.x if it works for you.
On 12/02/16 10:39, Ben Caradoc-Davies wrote:
Perhaps disabling the complex client for
WFSDataStoreFactory:GML_COMPLIANCE_LEVEL < 1?
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
(attachments)

Ian,
I have pushed a fix disabling the SPI provider for the complex WFS client to GeoTools master and 14.x. Please pull and build from source or try the next GeoServer master or 2.8.x nightly and report back
Kind regards,
Ben.
On 12/02/16 13:07, Ben Caradoc-Davies wrote:
[GEOT-5361] Complex feature WFS client breaks GeoServer external WFS
data store
https://osgeo-org.atlassian.net/browse/GEOT-5361
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
I can confirm this now works on 2.8.x nightly, I’ll try to test on latest later on today.
Thanks for your help Ben.
Cheers
Ian
···
On 12 February 2016 at 00:37, Ben Caradoc-Davies <ben@anonymised.com> wrote:
Ian,
I have pushed a fix disabling the SPI provider for the complex WFS client to GeoTools master and 14.x. Please pull and build from source or try the next GeoServer master or 2.8.x nightly and report back
Kind regards,
Ben.
On 12/02/16 13:07, Ben Caradoc-Davies wrote:
[GEOT-5361] Complex feature WFS client breaks GeoServer external WFS
data store
https://osgeo-org.atlassian.net/browse/GEOT-5361
–
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
–
Ian Turton
Thanks for the confirmation, Ian. Please let me know if latest also works.
Kind regards,
Ben.
On 15/02/16 23:58, Ian Turton wrote:
I can confirm this now works on 2.8.x nightly, I'll try to test on latest
later on today.
Thanks for your help Ben.
Cheers
Ian
On 12 February 2016 at 00:37, Ben Caradoc-Davies <ben@anonymised.com> wrote:
Ian,
I have pushed a fix disabling the SPI provider for the complex WFS client
to GeoTools master and 14.x. Please pull and build from source or try the
next GeoServer master or 2.8.x nightly and report back
Kind regards,
Ben.
On 12/02/16 13:07, Ben Caradoc-Davies wrote:
[GEOT-5361] Complex feature WFS client breaks GeoServer external WFS
data store
https://osgeo-org.atlassian.net/browse/GEOT-5361
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
Hi Ben,
just thinking out loud here, so don’t mind me too much, but… would’nt it make more sense
to have a single factory that instantiates the right store depending on the configuration,
and/or a check of the remote server contents?
Cheers
Andrea
···
On Mon, Feb 15, 2016 at 12:00 PM, Ben Caradoc-Davies <ben@anonymised.com> wrote:
Thanks for the confirmation, Ian. Please let me know if latest also works.
Kind regards,
Ben.
On 15/02/16 23:58, Ian Turton wrote:
I can confirm this now works on 2.8.x nightly, I’ll try to test on latest
later on today.
Thanks for your help Ben.
Cheers
Ian
On 12 February 2016 at 00:37, Ben Caradoc-Davies <ben@anonymised.com> wrote:
Ian,
I have pushed a fix disabling the SPI provider for the complex WFS client
to GeoTools master and 14.x. Please pull and build from source or try the
next GeoServer master or 2.8.x nightly and report back
Kind regards,
Ben.
On 12/02/16 13:07, Ben Caradoc-Davies wrote:
[GEOT-5361] Complex feature WFS client breaks GeoServer external WFS
data store
https://osgeo-org.atlassian.net/browse/GEOT-5361
–
Ben Caradoc-Davies <ben@anonymised.com91…>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
–
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
Geoserver-devel mailing list
Geoserver-devel@anonymised.comsts.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
–
==
GeoServer Professional Services from the experts! Visit
http://goo.gl/it488V for more information.
Ing. Andrea Aime
@geowolf
Technical Lead
GeoSolutions S.A.S.
Via di Montramito 3/A
55054 Massarosa (LU)
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
AVVERTENZE AI SENSI DEL D.Lgs. 196/2003
Le informazioni contenute in questo messaggio di posta elettronica e/o nel/i file/s allegato/i sono da considerarsi strettamente riservate. Il loro utilizzo è consentito esclusivamente al destinatario del messaggio, per le finalità indicate nel messaggio stesso. Qualora riceviate questo messaggio senza esserne il destinatario, Vi preghiamo cortesemente di darcene notizia via e-mail e di procedere alla distruzione del messaggio stesso, cancellandolo dal Vostro sistema. Conservare il messaggio stesso, divulgarlo anche in parte, distribuirlo ad altri soggetti, copiarlo, od utilizzarlo per finalità diverse, costituisce comportamento contrario ai principi dettati dal D.Lgs. 196/2003.
The information in this message and/or attachments, is intended solely for the attention and use of the named addressee(s) and may be confidential or proprietary in nature or covered by the provisions of privacy act (Legislative Decree June, 30 2003, no.196 - Italy’s New Data Protection Code).Any use not in accord with its purpose, any disclosure, reproduction, copying, distribution, or either dissemination, either whole or partial, is strictly forbidden except previous formal approval of the named addressee(s). If you are not the intended recipient, please contact immediately the sender by telephone, fax or e-mail and delete the information in this message that has been received in error. The sender does not give any warranty or accept liability as the content, accuracy or completeness of sent messages and accepts no responsibility for changes made after they were sent or for other risks which arise as a result of e-mail transmission, viruses, etc.
Sure. I recommend using the GML_COMPLIANCE_LEVEL option that is already included. Anything more than zero should use the complex client, and the default value of zero should use the simple client. The two factories already use the same configuration keys and should combined into one. I do not see it as a big task, but it should be done on master and the broken code had to be disabled on stable. Note that I have not yet seen the complex client working against any WFS server.
The goal of my fix was to disable SPI for the experimental complex WFS client to restore a working simple WFS client for Ian and for the GeoServer 2.9-beta release.
Kind regards,
Ben.
On 16/02/16 00:17, Andrea Aime wrote:
Hi Ben,
just thinking out loud here, so don't mind me too much, but... would'nt it
make more sense
to have a single factory that instantiates the right store depending on the
configuration,
and/or a check of the remote server contents?
Cheers
Andrea
--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/>
New Zealand