[QGIS-Developer] Project loader profiler Postgres Layers

Julien Cabieces julien.cabieces at oslandia.com
Wed Nov 16 00:55:13 PST 2022


Hi Remi,

Which profiler are you talking about ?

Did you try to use the the new Debugging/Developement tool ? It's new
since QGIS 3.26 and will give you the list of requests and the time
spent for each one when loading a project/layer or opening the attribute
table.

Regards,
Julien



> Hi,
>
>  
>
> I’m profiling large project loading, I think this mailing list doesn’t support images, so I won’t post any. 
>
> I’m posting in the dev mailing list since I dived into the code and found nothing 😅.
>
>  
>
> When you load a Postgres layer, the profiler list 3 steps:
>
> * Read layer metadata
>
> * Read layer fields
>
> * Create postgres provider
>
>  
>
> This “Create postgres provider” takes a while on some table (I have ‘use estimated table metadata’. In the connection.) 
>
>  
>
> I `git greped` the code and cannot found where this “span” happened and what requests are made to the server, I could look out on the server logs, sadly I don’t have access to it :-/
>
>  
>
> I already saw some weird behavior on 3.28 where QGIS launch ~25 SQL requests when loading a new layer, but I’d like to have solid fact before posting an issue on github.
>
>  
>
> Thx, Rémi.   



More information about the QGIS-Developer mailing list