3liz / py-qgis-server

QGIS embbeded WMS/WFS/WCS asynchronous scalable http server
https://docs.3liz.org/py-qgis-server
Mozilla Public License 2.0
68 stars 16 forks source link

handler: Set 'X-Map-Location' header if provided #67

Closed ptitjano closed 1 year ago

ptitjano commented 1 year ago

'X-Map-Location' can contain the QGIS project file url. It is then used in QgsRequestHandler::handle_message().

dmarteau commented 1 year ago

You don't need this: there is already the 'X-Qgis-Project' header that exists for the same purpose and conforms better to Qgis headers naming convention (and X-Map-Location exists only for internal use and will be removed at some point...)

See https://github.com/3liz/py-qgis-server/blob/master/pyqgisserver/qgsworker.py#L401

ptitjano commented 1 year ago

You don't need this: there is already the 'X-Qgis-Project' header that exists for the same purpose and conforms better to Qgis headers naming convention (and X-Map-Location exists only for internal use and will be removed at some point...)

See https://github.com/3liz/py-qgis-server/blob/master/pyqgisserver/qgsworker.py#L401

Indeed, I was missing the fact that copy_handlers in asynchandler.py already copies all X-QGIS-* headers. This is not needed.