Sunday, June 15, 2008

Some info about Project Velocity CTP-1

Named caches are universal across the cluster.

Regions are local to any cache host.It may limiti the scalibility to the cache cluster.

There are three ports.
1- Cluster Port
2- Aribitration port
3- Cache port

Your application must implement the Cache Aside pattern. i.e. it may support its operation even if data is not available in the cluster or even if any server is not available.It should be able to access data directly from database.

There are two types of clients.
1- Simple:
2- Routing

A simple client has no routing capabilities. It also can not track where each cached object is stored.It can request data from only one cache host. If that host does not hold the data. It gets data from other cache host (if available) and presents it to the client.


Each client also has the option to store cached data locally.This feature is called Local Cache.The type of client is configured in the configuration file.


The configuration in the application, so that clients may access the cluster, is maintained in Application Configuration file (app.config)

The configuration of cluster is maintained in ClusterConfig.xml file. This file presents a single point of failure in Velocity which is not yet taken care of (Till CTP1)


Objects are serialized before they are stored on cache host. Before it is used by the client, it must be deserialized. So it is recommended to have a local cache.

Concurrency Model:
Velocity supports the following concurrency models.
1- Optimistic
2- Pessimistic

Cache Expiration and Eviction:
The expiration is configured on named cache level in ClusterConfig.xml file. A TTL (Time to Live) may be associated with an object at the time of "Put".

Eviction is done by using LRU (Least Recently Used) algorithm.

1 comment:

Sarah On Distributed Caching said...

Although Velocity has made progress from CTP1 to CTP2, it still leaves much to be desired. It will be some time before they provide all the important features in a distributed cache and even longer before it is tested in the market. I wish them good luck.

In the meantime, NCache already provides all CTP2 & V1, and many more features. NCache is the first, the most mature, and the most feature-rich distributed cache in the .NET space. NCache is an enterprise level in-memory distributed cache for .NET and also provides a distributed ASP.NET Session State. Check it out at http://www.alachisoft.com.

NCache Express is a totally free version of NCache. Check it out at http://www.alachisoft.com/rp.php?dest=/ncache/ncache_express.html.

All the best,

Sarah.