Google Groups

Re: When/where does MapStore.store()/storeAll() get called?


Luca Garulli Apr 28, 2010 3:44 PM
Posted in group: Hazelcast
I made some tests using Orient Key/Value Serve that uses Hazelcast to store entries. In effects when a node dies the backup node starts the migration and invoke the store for all the instances owned by the died node.

http://www.orientechnologies.com/orient-kv.htm

There is also a live demo: http://95.110.224.203:8020

bye,
Luca Garulli

On 29 April 2010 00:39, Vivek Pandey <vivek....@gmail.com> wrote:
On Wed, Apr 28, 2010 at 3:13 PM, Luca Garulli <l.ga...@gmail.com> wrote:
Hi,
the store() is called only against the owner node. The backup nodes mantains entries only in RAM until someone became the owner (in case of crash for example).


Thats exactly what I am trying to achieve. If the primary node dies, I want to have new persistence saved to the next node (new owner). I this how its supposed to work? What I see is that the current behavior assumes there is centralized store, hence AbstractMapStore.init/destroy is per hazelcast instance!
 
You have experienced the store() on different nodes because the keys was different and hazelcast has distributed among the nodes using its Distributed Hash Table algorithm.

I See. 

thanks,

-vivek. 

bye,
Luca Garulli


On 28 April 2010 23:41, Vivek Pandey <vivek....@gmail.com> wrote:
Lets assume, I have 3 hazelcast nodes and each node has persistence enabled. If only the first(only one) node is writing to the map, I was expecting that MapStore.store/storeAll event is sent to all 3 nodes. Infact I see kind of random behavior. store() gets called on node1 (which is calling IMap.put()) but after certain number of entries I see node2's mapStore.store() is getting called and then after sometime node1's store is called.

Is there any configuration that I can use to control which node's mapstore get called? I am trying to make sure that each node's MapStore.store/storeAll get called so that I can create a local (to each node) persistence store, kind of distributed persistence store. Is it possible?

-vivek.

--
You received this message because you are subscribed to the Google Groups "Hazelcast" group.
To post to this group, send email to haze...@googlegroups.com.
To unsubscribe from this group, send email to hazelcast+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/hazelcast?hl=en.

--
You received this message because you are subscribed to the Google Groups "Hazelcast" group.
To post to this group, send email to haze...@googlegroups.com.
To unsubscribe from this group, send email to hazelcast+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/hazelcast?hl=en.

--
You received this message because you are subscribed to the Google Groups "Hazelcast" group.
To post to this group, send email to haze...@googlegroups.com.
To unsubscribe from this group, send email to hazelcast+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/hazelcast?hl=en.

--
You received this message because you are subscribed to the Google Groups "Hazelcast" group.
To post to this group, send email to haze...@googlegroups.com.
To unsubscribe from this group, send email to hazelcast+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/hazelcast?hl=en.