[Xapian-discuss] another DatabaseModifiedError issue

Andreas Marienborg andreas at startsiden.no
Wed May 28 11:07:41 BST 2008

On May 28, 2008, at 11:33 AM, Markus Wörle wrote:

> Hello,
> I use xapian-core-1.0.6 with the corresponding perl bindings. I run a
> 1 writer/N reader setup on 5 databases, that is the writer as well as
> each reader holds 5 open db handles at a time. Since I use the perl-
> bindings and am therefore not able to catch a DatabaseModifiedError, I
> do reopen() a database-handle before every query.
> Nevertheless I casually get  DatabaseModifiedErrors.
> They occur, if my writer (manually) flush()es two databases with
> little cached changes consecutively while having high load on the
> searchers.
> I know that DatabaseModifiedErrors get thrown if a database version
> get incremented at least two times while a search is running. In fact
> there *are* two very fast db updates in this case, and there *are*
> queries that might easily exceed the runtime of those updates. But my
> updates are on different databases.
> It feels to me, like my reader processes mixing up the version
> information of the different databases or something like that?
> My workaround does a 1-second sleep() after each (manual) flush(),
> which gives the readers enough time to finish before the next flush()
> occurs. This works.
> Unfortunately, I was not able to reproduce the issue with a simple
> test-case so far, but i think that in fact there has to be a bug in
> xapian to display this behaviour? Or is it a misunderstanding by me
> concerning database versions?
> Any ideas?
> Regards,
> mrks


This may not apply cleanly to 1.0.6, as I last updated it for 1.0.5.

- andreas

More information about the Xapian-discuss mailing list