jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lujie <lj...@126.com>
Subject Re: Extends SharedItemstateManager for special application?
Date Tue, 06 Jan 2009 12:48:10 GMT

   this is fragments from post
   To summarise what we're seeing, potential bottlenecks we think we're
and how we worked around them. Please note I'm not 100% familiar with the
JackRabbit design so some conclusions may be wrong:

 1) application uses Session to read a Node Property
 2) SessionImpl delegates to ItemManager
 3) ItemManager synch on a itemCache (Contention Point 1: Session Wide)
 4) On cache miss, ItemManager ultimately delegates to an SISM
 5) SISM synchs on ISMLocking (Contention Point 2: Global or per item
depending on DefaultISM or FineGrainedISM implementation)
 6) On cache miss, SISM delegates to persistence manager
 7) AbstractBundlePersistenceManager synchs on itself (Contention Point 3:
On persistence Manager)

In some cases our web application will read 2,000 or 3,000 Node properties
to deliver a single page request.

Initially we saw 7) as a bottleneck:
 - can JackRabbit leverage multiple database connections if its synched on a
single persistence manager?
 - we resolved this by configuring a large BundleCache

We then saw 5) as a bottleneck:
 - it seems as each node property is an item every property read contends on
ISMLocking. Is that correct? Is there scope for reading properties/lazy
loading in bulk for item?
 - we partly resolved this by moving from an "pooled session per view"
pattern to a "shared session per view" pattern

We now see contention occasionally on 3). 

I just see three synchronized methods:
1. synchronized(cache) in sharedItemStateManager
2. synchronized ismlocking.
3. synchronzed in persistencemanager

All for consistency in jackrabbit's cache.
If i do not want to use JR's cache, then the three synchronized methods can
be make non-sync,and the ismlocking is not a must.
Any ideas.

View this message in context: http://www.nabble.com/Extends-SharedItemstateManager-for-special-application--tp21309023p21309717.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.

View raw message