Hi,
I keep getting locking errors when updating my index which puzzles me
since only one process is supposed to be accessing the index at a
time (at least in development mode).
I’m using Ferret with Rails (NOT acts_as_ferret, though) and employed
an observer to add a new document to the index when a new
ActiveRecord is created. I’m not sure if this has any impact on the
concurrency issues, but I thought I mention it.
Find attached the verbatim error message and the relevant part of the
stack trace.
Any ideas?
Cheers,
Andreas
–
Ferret::Store::LockError (Lock Error occured at <except.c>:103
in xpop_context
Error occured in index.c:5368 - iw_open
Couldn’t obtain write lock when opening IndexWriter
):
/usr/lib/ruby/gems/1.8/gems/ferret-0.10.13/lib/ferret/index.rb:
664:in initialize' /usr/lib/ruby/gems/1.8/gems/ferret-0.10.13/lib/ferret/index.rb: 664:in
ensure_writer_open’
/usr/lib/ruby/gems/1.8/gems/ferret-0.10.13/lib/ferret/index.rb:
276:in <<' /usr/lib/ruby/1.8/monitor.rb:229:in
synchronize’
/usr/lib/ruby/gems/1.8/gems/ferret-0.10.13/lib/ferret/index.rb:
254:in <<' /app/models/index.rb:105:in
add’
/app/models/index.rb:20:in after_create' /usr/lib/ruby/gems/1.8/gems/activerecord-1.14.4.5263/lib/ active_record/observer.rb:154:in
update’
/usr/lib/ruby/1.8/observer.rb:185:in `notify_observers’
[…]