jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brian Thompson" <elephant...@gmail.com>
Subject Re: Does jackrabbit suffer from n+1 SQL SELECT queries?
Date Tue, 14 Aug 2007 15:56:33 GMT
Would it be viable to add an option to retrieve everything in a given
NodeIterator as a single DB query when a DB persistence manager is used?  It
seems to me that such an option would help out a lot for cases like
retrieving search results, getting all children of a node, etc.

-Brian



On 8/14/07, Marcel Reutegger <marcel.reutegger@gmx.net> wrote:
>
> Phillip Rhodes wrote:
> > Does jackrabbit issue a select statement in order to retrieve all the
> > properties and their values for a node?  If so, wouldn't jackrabbit have
> the
> > problem of issuing 400 different select statements as it iterates over
> 400
> > nodes?
>
> if none of the nodes are present in the cache, then jackrabbit will
> execute
> individual select statements to retrieve nodes. using the
> SimpleDbPersistenceManager it will even execute 400 + (400 *
> numberOfPropertiesPerNode). The BundleDbPersistenceManager circumvents
> this by
> loading all properties in a single SQL statement.
>
> regards
>   marcel
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message