[QGIS-Developer] effectiveness of PostgreSQL provider cache
Sandro Santilli
strk at kbt.io
Thu Feb 17 04:21:36 PST 2022
I've been trying to understand why PostgreSQL connections
are NOT reused while the code in the provider implements
a connection "cache".
Background: https://github.com/qgis/QGIS/issues/47391
The connections are (when "shareable"),
from QgsPostgresConn object,
put in a cache (two caches exist: "read-only"
and "read-write") but then are removed from the
cache when unreferenced.
Now the question is: why are them removed from the cache
on last unreference ? Doesn't that make the cache completely
useless ? In which case is a connection then kept alive ?
--strk;
Libre GIS consultant/developer
https://strk.kbt.io/services.html
More information about the QGIS-Developer
mailing list