[Qgis-developer] SpatiaLite very slow with QGIS 1.7

a.furieri at lqt.it a.furieri at lqt.it
Sun Mar 20 06:09:56 EDT 2011


On Thu, 17 Mar 2011 17:08:43 -0500, Cline, Royce L. wrote
> Did further testing. The problem is a power function of the number 
> of layers.
> 
> QGIS 1.7 r15529M. 
> # layers        load time       quit time
> 40 			2.3s 		1.6s
> 60			3.6s 		3.4 s
> 68			4.8s			5.3s
> 76			6.2s			8.9s
> 84			7.9s			19.6s
> 92			10.9		36.7s
> 100			14.1s		57.7s
> 108			18.8s		82.2s
> 
> QGIS 1.6
> # layers        load time       quit time
> 108			3.6s		instantaneous
> 

Hi List,

while debugging the above issue noticed by Royce,
I casually discovered a major issue affecting
any recent (1.7.0) QGIS version.

Please note well: such issue affects any operating
system, and isn't at all specifically related to 
SpatiaLite: it's a much more general flaw affecting 
Map Canvas and Map Layer Registry handling. 

I've prepared a very small test suite you can use to
reproduce this issue in the easiest way: 
http://www.gaia-gis.it/merano_shp.zip

----------------------
shortly said: the test suite contains a SpatiaLite
DB storing some 110+ layers; anyway each single
layer simply contains one or two features only, 
so it is an ultra-light weighted dataset.
and I've included Shapefiles as well, exactly
corresponding to DB layers.

the same identical slowness affects both SpatiaLite
and Shapefiles (and I strongly suspect, any other vector
datasource): it looks like an exponentially increasing 
time is required to add (or remove) any further layer.
so adding very few layers requires a quite unnoticeable
time: but adding several tenths (or hundredths) layers
at the same time requires an intolerable time.

please note: the number of features actually stored into 
each single layer has very little effect.

I'll inform you about any further advancement. 

bye Sandro


More information about the Qgis-developer mailing list