jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martijn Hendriks" <marti...@gx.nl>
Subject Database connections & queries
Date Wed, 22 Aug 2007 09:34:01 GMT
Hi all,

Recently we discovered that our server application needs to be restarted
if Jackrabbit looses its database connection (which was already
documented in JCR-940). We really need the reconnection logic and
created a patch (feedback much appreciated :)). As a side effect of this
we also noticed the following w.r.t. the query system: The current
implementation of the LazyScoreNodeIterator is such to ignore all
RepositoryExceptions that might be thrown while loading the nodes in the
result set, as required by the javax.jcr.NodeIterator spec. For the use
case where the database connection is lost, the iterator thus gives an
incomplete result: only the nodes that are currently cached are
returned.

The incomplete search result that is due to a lost connection is bad for
us as our app caches search results which we know to be stable. This can
be solved by letting the persistence managers block while there's no
database connection available. (The patch for JCR-940 does not do this,
however). Of course this has its advantages and disadvantages; maybe the
PMs behaviour w.r.t. a lost connection should be configurable via the
repository.xml?

Best regards,

Martijn

--

Martijn Hendriks
<GX> creative online development B.V.
 
t: 024 - 3888 261
f: 024 - 3888 621
e: martijnh@gx.nl
 
Wijchenseweg 111
6538 SW Nijmegen
http://www.gx.nl/ 

Mime
View raw message