You can not configure a map on the client side. You should configure myMap
and itsMapLoader/MapStore
on Hazelcast node. MapStore/MapLoader operations are executed by Hazelcast node that owns the data, not by client.
Hazelcast Node
<hz:config>
...
<hz:map name="myMap" backup-count="1" max-size="0">
<hz:map-store enabled="true" implementation="myMapLoader" />
</hz:map>
...
</hz:config>
-OR- using hazelcast.xml
<map name="myMap">
<backup-count>1</backup-count>
<time-to-live-seconds>0</time-to-live-seconds>
<max-idle-seconds>0</max-idle-seconds>
<map-store enabled="true">
<class-name>foo.bar.MyMapLoader</class-name>
<write-delay-seconds>0</write-delay-seconds>
</map-store>
</map>
On client side just instantiate myMap
;
<hz:map id="myMap" instance-ref="hazelcastClient" name="myMap" />
When client puts to / gets from that map, the node handles client's request will call MapLoader/MapStore.
ps: just copied the answer here that I have posted to your stackoverflow question.
http://stackoverflow.com/questions/10603254/using-a-maploader-for-a-hazelcast-distributed-map-within-a-client/
--
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.