[Qgis-developer] [Server] performance questions
Neumann, Andreas
a.neumann at carto.net
Tue Feb 23 07:39:46 PST 2016
Hi Régis,
QGIS server is single-threaded. You can't simply turn on multi-threaded
rendering in QGIS server. The other issue is that each Apache FCGI
process has it's own set of cache. So if you have 5-10 parallel Apache
threads or processes each thread/process has it's own cache. If your
client hits a thread that has the cache unititialized you will have wait
longer until this cache is fillled.
I once asked Marco whether one could
a) have a shared cache for all Apache threads or processes
b) support multi-threaded rendering
But he said it would be very complicated to implement a) and b), if not
impossible. Maybe other devs have other views. Note that was about 2
years ago, when I last discussed this with Marco.
---------------------
Nevertheless I believe there would be room for performance improvements
in QGIS server - if interested parties share their efforts (be it dev
time or financial resources).
BTW:
did you switch of QGIS server python plugins? If you don't need them, I
recommend you switch them off - both for security reasons, but also
there was a huge performance problem with QGIS server Python plugins
just recently. See http://hub.qgis.org/issues/13919 - luckily this was
fixed just recently. Depending on the version you use, this may have a
negative impact on your installation.
Andreas
On 2016-02-23 15:20, Régis Haubourg wrote:
> Hi all,
> we are working on using qgis server here and we face some performance issues
> on big data sets. Cache is not an option for those layers that will be
> edited by users. Currently performances are not acceptable for production
> uses. Here is a couple of questions that I could not answer by myself on
> the net:
>
> 1- Clarifying multithread on server side vs multithread on desktop:
>
> We use qgis 2.12 server from qgis repository for debian on a 4 core Xeon
> (2.1Ghz) + 16Go RAM.
>
> We configured apache2 with MPM worker and we have a pool of 10
> qgis_mapserv.fcgi waiting for client request.
> The behaviour here is that one client will only consume one fcgid process,
> when desktop can use several processes to make some parallel rendering of
> project layers.
> When having QGIS desktop using only one thread, I have similar rendering
> time. The difference is purely proportionnal to CPU speed difference.
> Did we miss something in configuration process or is that the intended
> behavior? I did try to use QGIS_OPTION_PATH on a QGIS2.ini but I really
> can't be sure it is really being used.
> Do QGIS packages miss the multithread option on compile cmake options?
> If this is expected, does the web architecture would allow to have fcgid do
> parallel rendering like desktop? Would that be a big work (I could partly
> fund that)?
>
> 2- Overhead on first request with postgres complex view compared to
> shapefiles
>
> We have almost only postgis views being used as QGIS layers. Qgis server
> builds get capabilities and requests views to get extent and primary keys.
> There is a severe overhead for the first wms request by a client session.
> When generating the image takes about 7s, the first request can take from 24
> to 30s. Desktop multihreaded will get the image in about 3s (same postgres
> server, same network).
> That overhead starts to become annoying on desktop side too, but it's only
> qgs loading time, once in a work session. Does someone have any idea that
> one day postgis could collect such metadata on views so that QGIS do not
> have to scan all rows when data are in views? Direct access to tables, or
> same project with shp datasources do not show that overhead on server nor in
> desktop.
>
> Thanks for your hints,
> Cheers
>
> Régis
>
> --
> View this message in context: http://osgeo-org.1560.x6.nabble.com/Server-performance-questions-tp5252233.html
> Sent from the Quantum GIS - Developer mailing list archive at Nabble.com.
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> List info: http://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-developer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20160223/2f61a433/attachment.html>
More information about the Qgis-developer
mailing list