[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] locking artirepos && performance

On Tue, Jul 12, 2011 at 11:09 AM, Haigermoser, Helmut <Helmut.Haigermoser@xxxxxxxxxxxxx> wrote:

Ciao @ll :
Just debugged a huge performance problem in my installer over here.

Calculating the required disk space (~2gig) took 120 seconds, rather than the usual < 2 seconds.

 

Recently adopting 3.7 made my suspect new features to maybe be used incorrectly in my code, started debugging in that mind set…

 

Turns out the big performance bottleneck is the simple arti repo. What it does is reread artifacts.xml each time a single call to “getArtifactDescriptors” or like methods is made. My location is read only (network share) and somewhat slow, so that explains why this bug was exposed  in such a drastic fashion…

It should do an 'up-to-date' check and only re-load the file if it has changed.  Maybe across a network share this is not the case (timestamps maybe?).

(See SimpleArtifactRepository#doLoad()).
 

 

This seems like a really huge problem to me, can you guys fix this even on the 3.7 stream? I’m of course willing to contribute to the fix, by filing a bugzilla or whatever you guys want me to do, but I wanted to publish the problem here as well since I saw a bunch of locking-related messages before and thought maybe there was something I could do different in my code to work around the problem (-Declipse.p2.internal.simple.artifact.repository.locking=false did not work since that is only used in one of the two constructors of the simple arti repo)…


The -Declipse.p2.internal.simple.artifact.repository.locking=false instructs p2 whether to 'lock' or 'not lock' the repository when writing. That is separate (but related) to cache invalidation.  The fact that you are not reusing the cache seems like the real problem.

I'm pretty sure, we can do something for 3.7.1. Please file a bug and CC me.  

Cheers,
Ian
 


TIA,

Ciao, hh


_______________________________________________
p2-dev mailing list
p2-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/p2-dev




--
R. Ian Bull | EclipseSource Victoria | +1 250 477 7484
http://eclipsesource.com | http://twitter.com/eclipsesource