Re: [hibernate-dev] [infinispan-dev] Resetting Lucene lock at Directory initialization

2009-10-19 Thread Manik Surtani
I would think you need a separate tx for the lifecycle of the lock. On 19 Oct 2009, at 12:22, Sanne Grinovero wrote: > Sorry I'll try to explain myself better, I think there's some > confusion about what my problem is. > > Javadoc for LockFactory.clearLock - which the interface of what we > have

Re: [hibernate-dev] [infinispan-dev] Resetting Lucene lock at Directory initialization

2009-10-19 Thread Sanne Grinovero
Sorry I'll try to explain myself better, I think there's some confusion about what my problem is. Javadoc for LockFactory.clearLock - which the interface of what we have to implement - is about an explicit force-cleanup: /** * Attempt to clear (forcefully unlock and remove) the * specified l

Re: [hibernate-dev] [infinispan-dev] Resetting Lucene lock at Directory initialization

2009-10-19 Thread Manik Surtani
On 19 Oct 2009, at 08:16, Emmanuel Bernard wrote: > On the Lucene side, it seems to me that manually asking for a lock > clear is cleaner / safer than this automagic approach. Yeah, I agree with Emmanuel - a more explicit form would work better IMO. Perhaps what you could do is something like

Re: [hibernate-dev] [infinispan-dev] Resetting Lucene lock at Directory initialization

2009-10-19 Thread Manik Surtani
On 16 Oct 2009, at 15:50, Sanne Grinovero wrote: > Hello, > Lucene does - in default LockManager implementation - a sort of "lock > cleanup" at index creation: if it detects a lock on the index at > startup, this is cleared. > > Ɓukasz translated the exact same semantic on the Infinispan > Dire