Open 9ls1 opened 4 months ago
If you enable INFO logging in qgis server:
qwc-qgis-server:
environment:
QGIS_SERVER_LOG_LEVEL: 0
do you see in the qwc-qgis-server-log
the following log entry?
qwc-qgis-server_1 | 09:05:19 INFO Server[73]: Server plugin split_categorized loaded!
@manisandro Thanks, I enabled INFO-logging, but I'm not able to find/see qwc-qgis-server-log? However, I have located /var/lib/docker/containers and had a look in the qwc-qgis-server container (xxxx-json.log, finding the contianer id xxxx with sudo docker ps
), and can't find any string containing 'split'. Not a good sign, I assume. (I have INFO Server[72] and INFO Server[109 ] - if this means anything.)
You can see the log via docker-compose logs -f qwc-qgis-server
@manisandro Thanks for the command making log-retrieving much easier. However, no sign of split in the log log_qgis_server_20240207_01.txt
So the plugin probably isn't mounted correctly, or the docker container not recreated with the new configuration. Did you recreate the server container with docker-compose up qwc-qgis-server
after changing the configuration in the compose file?
@manisandro Yes, I have tried several things like restarting docker, stopping docker and starting docker, recreating the server container, but without any luck in seeing "Server plugin split_categorized loaded!" nor splitted layers in QWC2. The split_categorized.py is placed in /xxx/xxx/qwc-docker/volumes/qgis-server-plugins/split_categorized corresponding to the instructions: ...
volumes:
-./volumes/qgis-server-plugins/split_categorized:/usr/share/qgis/python/plugins/split_categorized:ro
... Not sure how else to mount the plugin.
Last idea would be to docker-compose exec qwc-qgis-server bash
and then check within the docker container that the plugin files are indeed there as expected and readable.
@manisandro Thanks for you time and help. Yes, I do find the plugin in expected(?) folder:
www-data@e3409b73647a:/usr/share/qgis/python/plugins/split_categorized$ ls -l total 8 -rwxr-xr-x 1 root root 6938 Feb 7 12:57 split_categorized.py www-data@e3409b73647a:/usr/share/qgis/python/plugins/split_categorized$
Originally it was user and group like 1003 and 1005 respectively - no luck. It was then changed to root root - didn't help. In the log I see:
... qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Plugin PATH: /usr/lib/qgis/plugins qwc-qgis-server-1 | 11:38:31 INFO Server[72]: PkgData PATH: /usr/share/qgis qwc-qgis-server-1 | 11:38:31 INFO Server[72]: User DB PATH: /etc/qgis.db qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Auth DB PATH: /var/lib/qgis/qgis-auth.db qwc-qgis-server-1 | 11:38:31 INFO Server[72]: SVG PATHS: /usr/share/qgis/svg/:/etc/svg/ qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/libdummy.so" qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service SampleService 1.0 qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/liblandingpage.so" qwc-qgis-server-1 | 11:38:31 INFO [72]: Adding API Landing Page qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/libwcs.so" qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service WCS 1.0.0 qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/libwfs.so" qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service WFS 1.1.0 qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service WFS 1.0.0 qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/libwfs3.so" qwc-qgis-server-1 | 11:38:31 INFO [72]: Adding API OGC WFS3 (Draft) qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/libwms.so" qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service WMS 1.3.0 qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service WMS 1.1.1 qwc-qgis-server-1 | "Loading native module /usr/lib/qgis/server/libwmts.so" qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Adding service WMTS 1.0.0 qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Initializing 'filesystem' cache strategy qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Server initialized qwc-qgis-server-1 | 11:38:31 INFO ./src/server/qgsserverplugins.cpp[72]: load library /usr/lib/qgispython (3.28.15) qwc-qgis-server-1 | 11:38:31 INFO ./src/server/qgsserverplugins.cpp[72]: Python support library loaded successfully. qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Server plugin ClearCapabilities loaded! qwc-qgis-server-1 | 11:38:31 INFO Server[72]: Server python plugins loaded qwc-qgis-server-1 | 11:38:31 INFO Server[72]: **** New request *** ...
I note Plugin PATH: /usr/lib/qgis/plugins (and not /usr/share/qgis/plugins) and the only "loaded!" I find is "Server plugin ClearCapabilities loaded!".
Must the owner of the folder qgis-server-plugins (/xxx/xxx/qwc-docker/volumes/qgis-server-plugins) be root?
I'm using qwc-docker generating themes from qwc-admin-gui.![image](https://github.com/qgis/qwc2-demo-app/assets/10632163/25347387-a8df-4810-8d12-c749c566ddc9)
Despite following the instructions from Split categorized layers , the layer is not splitted (categorized) in QWC2 as it is in QGIS.
QGIS![image](https://github.com/qgis/qwc2-demo-app/assets/10632163/4ff793ad-6403-4677-a4c8-a7dc2cc58468)
QWC2![image](https://github.com/qgis/qwc2-demo-app/assets/10632163/5320d1d2-c55d-486d-9c39-bff6ae8e2258)
split_categorized.py is downloaded and saved in volumes/qgis-server-plugins/split_categorized![image](https://github.com/qgis/qwc2-demo-app/assets/10632163/ef481e58-8a96-4ca0-8ed5-703aa50845a8)
qwc-qgis-server container is configured:
The layer has a variable convert_categorized_layer true.![image](https://github.com/qgis/qwc2-demo-app/assets/10632163/7738344b-f798-4297-8dc2-181353778bd1)
Then I successfully generate themes configuration. However, the layer is not splitted (see images above).
Any idea where I go wrong?