Distributed Cache for .NET
Microsoft adds velocity to data-driven apps.
Microsoft has unveiled a distributed in-memory application cache platform it says will boost the performance and scalability of .NET apps. The company describes the server -- dubbed Project "Velocity" -- as the latest component of its Data Platform vision for developers, joining other key technologies such as SQL Server, LINQ, ADO.NET Data Services and the ADO.NET Entity Data Framework.
Velocity will let developers provide access to data from multiple tiers of enterprise and Web application infrastructures from any client system, whether that system is connected or offline. An in-memory application cache will serve to ease the development of high-performance applications.
Key to boosting performance in Velocity is an ASP.NET session provider object, which allows objects to be stored in the cache rather than requiring that they be written into a database management system, according to Microsoft. When a shop has a very large number of ADO.NET applications -- such as ASP.NET applications -- reading the same SQL Server, that leads to bottlenecks, which makes it difficult to scale the state of a session.
"The way we solve this is to use a distributed cache: You keep the session state in the cache, and it can provide a really large-scale place to really hold that session cache," explains Anil Nori, a distinguished engineer in Microsoft's SQL Server group. "Then you can provide better performance and scale."
Microsoft released a community technology preview (CTP) in June and described this new tier of Microsoft's application stack as a platform that scales from tens to hundreds of systems. Currently the company hasn't decided, or at least disclosed, its plans to productize Velocity.
Velocity provides common cache configurations that allow applications to dynamically scale as more nodes are added, and ultimately will provide high availability by offering automatic load balancing.
Microsoft says developers can configure Velocity to run as a network service or embed it within an application. Velocity is based on an architecture Microsoft calls "Explicit Caching," meaning developers must determine specifically which objects to put in or remove from an app. Velocity does not automatically synchronize with source databases, at least in the current CTP.
The CTP includes a set of APIs that developers can use to build caching services into their .NET applications. Velocity caches any serial Common Language Runtime (CLR) object and provides access to that data via the API set. The three primary programming interfaces are core, item and level APIs, which allow developers to implement a get, put or remove into a data-driven procedure, explains Nori. The other APIs let developers program put-related objects.
"Let's say you have some related objects and that you want them to be together physically on the same memory," says Nori. "You can put them into a region, then you can actually go in and we have a bunch of APIs that operate on the regions. You can go in and enumerate all of the items within a region, remove a region or add a region."
The APIs allow developers to "tag" objects. If a developer has a document object and wants to tag it as a contact document, the tag will classify those elements accordingly.
"As long as you have these tags you can basically do tag-based querying, tag-based retrieval and then tag-based organization," Nori says.
Case for Caching
Microsoft's current thinking is that more and more individuals are accessing data from mobile devices and PCs, and that content typically consists of objects that don't need to be pulled from a database. Velocity brings together memory across multiple systems providing a common cache for applications, which can store serial CLR objects without regard for where they're stored.
Using caches, organizations can scale by simply adding more hardware. A number of vendors have been doing this for some time, including GemStone Systems Inc., GigaSpaces Technologies Inc., ScaleOut Software Inc. and Tangersol, which was acquired by Oracle Corp. last year and is being integrated in the company's Java-based Fusion middleware app stack. All of the major suppliers of system software are expected to jump on the caching bandwagon.
Coming in CTP 2
While the current CTP allows developers to create clusters and supports scalability and performance, Nori says it doesn't support any availability. A second, more fully featured CTP is expected to have more functionality, and it will round out all of the utilities necessary for loading the caches, high availability and better integration for manageability, according to Nori.
Microsoft is targeting CTP 2 to be released at the Professional Developers Conference in Los Angeles this October, followed by a commercial release in the second half of next year.
It's unclear how Microsoft will productize Project Velocity -- whether it will be an OEM-only product for hardware suppliers, a standalone offering or bundled with other Microsoft software.
"We haven't figured out what is a long-term set of facilities, but one thing we feel strongly is that it's aligned with the .NET stack rather than SQL Server," Nori says.
Jeffrey Schwartz is editor of Redmond magazine and also covers cloud computing for Virtualization Review's Cloud Report. In addition, he writes the Channeling the Cloud column for Redmond Channel Partner. Follow him on Twitter @JeffreySchwartz.