[QGIS-Developer] no collections displayed in wfs3

Paul van Genuchten paul.vangenuchten at geocat.net
Fri Jun 18 12:26:24 PDT 2021


Yet another RTFM. Thank you for that pointer Allessandro, you saved my day!

Have a good weekend, ciao Paul.



> On 18 Jun 2021, at 11:42, Alessandro Pasotti <apasotti at gmail.com> wrote:
> 
> 
> Maybe a stupid question: does /etc/qgisserver/project.qgs  has any WFS enabled layer?
> 
> 
> On Fri, Jun 18, 2021 at 11:40 AM Paul van Genuchten <paul.vangenuchten at geocat.net <mailto:paul.vangenuchten at geocat.net>> wrote:
> Hi Allessandro, i just tried with the 3.10 image also, but got similar results.
> 
> If i enforce an error in one of the layers, those errors are actually logged, but still I don’t see any collections (in html and or json encoding). 
> 
> My log is here:
> 
> ```
> 49686 - 172.19.0.12 - - [18/Jun/2021:09:33:56 +0000] "GET /qgis/wfs3/static/style.css HTTP/1.1" 200 633 "http://localhost:8000/qgis/wfs3/collections? <http://localhost:8000/qgis/wfs3/collections?>" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.77 Safari/537.36"
> 09:33:56 INFO Server[74]: ******************** New request ***************
> 09:33:56 INFO Server[74]: Request URL: http://localhost:8000/qgis/wfs3/static/jsonFormatter.min.js? <http://localhost:8000/qgis/wfs3/static/jsonFormatter.min.js?>
> 09:33:56 INFO Server[74]: Environment:
> 09:33:56 INFO Server[74]: ------------------------------------------------
> 09:33:56 INFO Server[74]: SERVER_NAME: localhost
> 09:33:56 INFO Server[74]: REQUEST_URI: /qgis/wfs3/static/jsonFormatter.min.js
> 09:33:56 INFO Server[74]: SCRIPT_NAME: /qgis/wfs3/static/jsonFormatter.min.js
> 09:33:56 INFO Server[74]: REMOTE_ADDR: 172.19.0.12
> 09:33:56 INFO Server[74]: SERVER_PORT: 8000
> 09:33:56 INFO Server[74]: QUERY_STRING: 
> 09:33:56 INFO Server[74]: REQUEST_METHOD: GET
> 09:33:56 INFO Server[74]: HTTP_ACCEPT: */*
> 09:33:56 INFO Server[74]: HTTP_USER_AGENT: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.77 Safari/537.36
> 09:33:56 INFO Server[74]: QGIS_PROJECT_FILE: /etc/qgisserver/project.qgs
> 09:33:56 INFO Server[74]: Trying URL path: /qgis/wfs3/static/jsonFormatter.min.js for /wfs3
> 09:33:56 INFO Server[74]: API OGC WFS3 (Draft) accepts the URL path /qgis/wfs3/static/jsonFormatter.min.js 
> 09:33:56 INFO Server[74]: Checking API path /qgis/wfs3/static/jsonFormatter.min.js for /collections/(?<collectionId>[^/]+)/items(\.geojson|\.json|\.html)?$ 
> 09:33:56 INFO Server[74]: Checking API path /qgis/wfs3/static/jsonFormatter.min.js for /collections/(?<collectionId>[^/]+)/items/(?<featureId>[^/]+?)(\.json|\.geojson|\.html)?$ 
> 09:33:56 INFO Server[74]: Checking API path /qgis/wfs3/static/jsonFormatter.min.js for /collections(\.json|\.html)?$ 
> 09:33:56 INFO Server[74]: Checking API path /qgis/wfs3/static/jsonFormatter.min.js for /collections/(?<collectionId>[^/]+?)(\.json|\.html)?$ 
> 09:33:56 INFO Server[74]: Checking API path /qgis/wfs3/static/jsonFormatter.min.js for /conformance 
> 09:33:56 INFO Server[74]: Checking API path /qgis/wfs3/static/jsonFormatter.min.js for /static/(?<staticFilePath>.*)$ 
> 09:33:56 INFO Server[74]: Found API handler static
> 09:33:56 INFO Server[74]: Request finished in 2 ms
> ```
> 
> Any ideas?
> 
> 
>> On 18 Jun 2021, at 10:17, Alessandro Pasotti <apasotti at gmail.com <mailto:apasotti at gmail.com>> wrote:
>> 
>> 
>> 
>> On Fri, Jun 18, 2021 at 9:57 AM Paul van Genuchten <paul.vangenuchten at geocat.net <mailto:paul.vangenuchten at geocat.net>> wrote:
>> Hi list, At Geonovum (netherlands) we’re operating an environment to study a number of OGC API Features implementations.
>> 
>> We’ve aded qgis server from 3.18 and 3.16 docker image maintained by camp to camp (https://github.com/camptocamp/docker-qgis-server <https://github.com/camptocamp/docker-qgis-server>). In both cases we noticed the /wfs3/collections endpoint did not display any collections, but the wms-capabilities showed the layers of our project without problems. The log didn’t show any warnings. 
>> 
>> Do you have some hints on how i could debug the situation?
>> 
>> The logs should definitely show something.
>> 
>> Anyway, the problem is probably caused by QGIS_PROJECT_FILE not being correctly set. 
>> 
>> How do you pass it to the server? 
>> 
>> Note that MAP=/path is not allowed by the OAPIF standard (QGIS should parse it correctly though).
>> 
>> 
>> -- 
>> Alessandro Pasotti
>> QCooperative:  www.qcooperative.net <https://www.qcooperative.net/>
>> ItOpen:   www.itopen.it <http://www.itopen.it/>
> 
> 
> -- 
> Alessandro Pasotti
> QCooperative:  www.qcooperative.net <https://www.qcooperative.net/>
> ItOpen:   www.itopen.it <http://www.itopen.it/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20210618/63c2e3e7/attachment.html>


More information about the QGIS-Developer mailing list