Monday, October 28, 2013

Coherence 3.6 FAQ

coherence Command line console is also a full member of the cluster
If you want to just query, not to join the cluster as a member, then use coherence-extend or 3.7 has REST API client

if request efects more than 20% of cluter members, unicast is used Otherwise multicasr is used.
ACcknowledgement is always unicast.
TCMP = unicast + multicast
unicast is based on destination address
multicasr is no destination, broadcast

two requirements for objects to be put in cache:
java beans
some form of serialization

3 args should match for all cluster members
-Dtangosol.coherence.ttl=0
-Dtangosol.coherence.cluster=XYZCluster
-Dtangosol.coherence.clusterport=7009

local_storage = false means, the member joins the cluster as a non-storage memeber. It does not store any data but stil can put and get data..

Implement PortableObject interface for cross-platform communication

I got class sizes of 339, 93 and 75 for default, ExternalizableLite and PortableObject.

LocalCache
- No fault tolerance
- exists along with application heap
- instant read and writes


replicated cache
- writes are a problem because cache.put() returns only when all caches are synced with the write (put is blocking or synchronous call)
- provides zero latency reads
- since cache is replicated, it provides high availability
- suited for read only or read mostly (data loaded during initialization)

partitioned cache
- data is assigned to certain buckets and these buckets are assigned to each partition
- synchronously maintains backup of partitions on other machines
- we always know the mapping between data key and partition owner so reads are always 1 network hop, writes
are 2 (one for write and one for backup write)
- number of partitions are always prime number

Near cache
-Holds frequently used data from partition
-If some other member updates data, it is possible to update it in near cache by using synchronization strategy
-if the local client asks for a data item existing in near cache that changed on remote partition, remote partition will first remove the data item from near cache to invalidate it. Then, this data item is read from remote partition.
- Use to defined above 

No comments: