[hibernate-dev] Re: improving Search
Sanne Grinovero
sanne.grinovero at gmail.com
Thu Jun 12 06:00:46 EDT 2008
>
>
>> >> Does it somehow involve not having cluster changes (ie intra VM policy
>> rather than inter VM?)
>> I don't really understand what you're asking; I hope previous example
>> contains an answer; it just means you don't need
>> to lock the index to make a "hotcopy" to anywhere.
>>
>
>
> My question is does it somehow involve interacting with the IndexWriter so
> that it does not do stuffs it would do otherwise.
> ie if I run indexing on VM1 and VM2, will copying files "from VM1" be
> affected by indexWriter operations from VM2
My proposal to use Index snapshots is to avoid the DP lock when needing to
copy somewhere, so indexing can go on without
having to wait for file transfers: currently the FSMasterDirectoryProvider
could take the lock for a long time.
This would be useful in the Master-Slave configuration, where the Lock I
want to release eagerly is VM-local as the master
is the sole VM writing to the index; so I don't see how I could introduce a
multiple-VM problem.
Is it possible to combine cluster configurations described in reference
2.2.1 and 2.2.2?
I mean are we meant to support a configuration having 2+ VMs acting as
Master for the same JMS topic and using the same filesystem index?
But I see your point, I'm going to verify if an IndexWriter holding a
snapshot will keep it's file-level locks or not, even when being closed
in the workspace.
>
>
>>
>> >> Not if it's updated in a cluster, right?
>> >> Plus seeing the contention lock we have experienced (on IndexReader) in
>> the recent test case, I want to be sure it's actually faster than opening
>> every time.
>> Why not? don't you update by using delete+insert in cluster too?
>>
>
> In a cluster, you open the IW do what you have to do protected by the
> global lock, then close the IW (and release the global lock) which means the
> IW on a other machine of the cluster can then have it.
> Does it work the same if you keep the IW opened? Does it release the global
> lock? Does it cope with other IWs updating the file system?
So is Map<DirectoryProvider, ReentrantLock> getLockableDirectoryProviders()
in SearchFactoryImpl returning distributed locks?
Or are you telling me about Lucene's locks on the index?
thanks for all help,
Sanne
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/hibernate-dev/attachments/20080612/72dff452/attachment.html
More information about the hibernate-dev
mailing list