Bug report #8401

QGIS not able to access WMTS (GeoServer specific?)

Added by Jonathan Moules over 11 years ago. Updated almost 11 years ago.

Status:Closed
Priority:Normal
Assignee:-
Category:-
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:fixed/implemented
Crashes QGIS or corrupts data:No Copied to github as #:17173

Description

QGIS can't seem to access my WMTS (GeoServer 2.3.4). I can see it has made the request in the access logs, and the same URL works fine in the browser (and ArcMap can access it fine too), so I'm concluding it's a QGIS issue.

When I click "connect" it swaps to the "server search" tab. But there's nothing listed. I didn't tick any of the boxes for the connection.

My GeoServer isn't publicly available (security approval required - ongoing). I can't get my QGIS to access the internet either (it doesn't like our proxy) so can't test other WMTS'.

Attached is the GetCapabilities.

wmts-getcapabilities.xml Magnifier (59.1 KB) Jonathan Moules, 2013-08-02 05:30 AM

Associated revisions

Revision c321f597
Added by Jürgen Fischer almost 11 years ago

wmts: add a default style entry if the server doesn't provide any (fixes #8401)

History

#1 Updated by Jonathan Moules about 11 years ago

Turns out this is different to #8406

Further to that bug report I've expanded the URL but it hasn't fixed the issue.
This URL works fine in the browser and returns the previously attached file.

http://wppgeog3:8082/geoserver/gwc/service/wmts?SERVICE=WMTS&REQUEST=GetCapabilities

#2 Updated by Moreno Comelli almost 11 years ago

Found the same problem (QGIS 2.1 on WinXP 64): WMTS provided by default Mapcache 'demo' page works on QGIS 1.8 and 2.0, not on master version.
The map extension is correct, but the WMS log reports 'image is NULL' and:

Download of GetLegendGraphic failed: Error downloading http://192.168.122.128/mapcache/?SERVICE=WMS&VERSION=1.1.1&SLD_VERSION=1.1.0&REQUEST=GetLegendGraphic&LAYER=test&STYLE=default&SCALE=235105735.596957&FORMAT=image/png - server replied: Method Not Implemented

#3 Updated by Richard Duivenvoorde almost 11 years ago

#9066 has a public url to test

#4 Updated by Jürgen Fischer almost 11 years ago

  • Resolution set to fixed/implemented
  • Status changed from Open to Closed

fixed in 836e1a8

#5 Updated by Jürgen Fischer almost 11 years ago

Jürgen Fischer wrote:

fixed in 836e1a8

Um, might actually be something different. That fixes the problems after GetLegendGraphic failed. Feel free to reopen.

#6 Updated by Jonathan Moules almost 11 years ago

  • Status changed from Closed to Reopened

Would this be in the build weekly QGIS-OSGeo4W-2.1.0-46-Setup-x86_64.exe - 18-Nov-2013 20:22 - number e882e47 from - http://qgis.org/downloads/weekly/?

Because if it is, this bug isn't fixed - I'm still getting the exact same behaviour.

#8 Updated by Jürgen Fischer almost 11 years ago

  • Status changed from Reopened to Closed

#9 Updated by Jonathan Moules almost 11 years ago

Thanks! I guess that'll be in tonight's weekly build?

#10 Updated by Richard Duivenvoorde almost 11 years ago

Hi Jonathan, looking into the fix of jurgen, it seems there is was a missing default style.

So I thought to check the validity of the capabilities (using xmllint) and as you can see below it is just not valid against it's schema (it is missing a Style element :-) )

So maybe try to create a style for that layer (maybe that helps)? Or otherwise issue a bug against the software (Geowebcache/Geoserver?)?

If I take one of the national dutch wmts services (also running geowebcache I think...), these are validating:
http://geodata.nationaalgeoregister.nl/tiles/service/wmts/aan?VERSION=1.0.0&request=GetCapabilities

Below the command for the validation of your service:

richard@kwik:/tmp$ xmllint --noout --schema http://schemas.opengis.net/wmts/1.0/wmtsGetCapabilities_response.xsd wmts-getcapabilities.xml 
wmts-getcapabilities.xml:60: element Format: Schemas validity error : Element '{http://www.opengis.net/wmts/1.0}Format': This element is not expected. Expected is one of ( {http://www.opengis.net/ows/1.1}BoundingBox, {http://www.opengis.net/ows/1.1}WGS84BoundingBox, {http://www.opengis.net/ows/1.1}Metadata, {http://www.opengis.net/ows/1.1}DatasetDescriptionSummary, {http://www.opengis.net/wmts/1.0}Layer, {http://www.opengis.net/wmts/1.0}Style ).
wmts-getcapabilities.xml:185: element Format: Schemas validity error : Element '{http://www.opengis.net/wmts/1.0}Format': This element is not expected. Expected is one of ( {http://www.opengis.net/ows/1.1}BoundingBox, {http://www.opengis.net/ows/1.1}WGS84BoundingBox, {http://www.opengis.net/ows/1.1}Metadata, {http://www.opengis.net/ows/1.1}DatasetDescriptionSummary, {http://www.opengis.net/wmts/1.0}Layer, {http://www.opengis.net/wmts/1.0}Style ).
wmts-getcapabilities.xml:306: element Format: Schemas validity error : Element '{http://www.opengis.net/wmts/1.0}Format': This element is not expected. Expected is one of ( {http://www.opengis.net/ows/1.1}BoundingBox, {http://www.opengis.net/ows/1.1}WGS84BoundingBox, {http://www.opengis.net/ows/1.1}Metadata, {http://www.opengis.net/ows/1.1}DatasetDescriptionSummary, {http://www.opengis.net/wmts/1.0}Layer, {http://www.opengis.net/wmts/1.0}Style ).

#11 Updated by Jonathan Moules almost 11 years ago

That's fixed it.
And wow, this is awesome. Compare it to the ArcGIS WMTS implementation which is utterly awful and totally unusable. Go QGIS! :-)

Oh, and GeoServer ticket opened and acknowledged as a bug - https://jira.codehaus.org/browse/GEOS-6190

Also available in: Atom PDF