Evaluating App Fabric as a Data Store (Part-II)
As discussed previously in Part-I of the AppFabric series, we understood the basics of the AppFabric, what it is and which all different features it provides.
This article will cover:
- Caching and Database synchronization
- Alternatives to AppFabric
Caching and Database synchronization
AppFabric does not provide out of the box support for the Synchronization with Data Sources. But, by writing an external component and handling the necessary events it is still achievable.
To implement this external wrapper, we have to take following
approach:
AppFabric + Entity Framework + EF cache providers + MS Sql Server
As AppFabric does
not support Third Party Integrations to Entity Framework,
this implementation will require huge development effort.
That pops up an important question, if not AppFabric, then what else?
To suit your needs, there are 2 alternatives, which you can consider:
- nCache
- Redis
nCache
- Low cost servers
- Easy data replication
- Cluster updates
- Reduces close to 75% of traffic from your web applications, microservices
- Supports caching of app data, sessions, states, response and message based response caching
Redis
- Has dedicated cluster manager for tackling failures and auto-failover
- Master and Slave structure using in-memory replication
- Easily scalable
- Performance is extremely good for small files, data
AppFabric vs nCache
Feature Area
|
AppFabric
|
nCache
|
Performance & Scalability
|
Have performance and scalability
issues that are due to WCF as the transport layer and lack of advanced
performance optimizations features. |
Extremely fast and scalable due to
a light-weight socket-level protocol for transport layer. And many advanced
performance optimization features provided to further speed things up. |
Cache Elasticity
|
No peer-to-peer architecture.
Something resembling master/slave architecture employed. If some of the “lead
nodes” or the configuration file server goes down, the entire cache could
potentially go down. |
Highly elastic with 100% uptime.
Peer to peer cluster architecture. Connection failover support, dynamic
configuration, and “Hot Apply” feature. |
Cache Topologies
|
Local cache, partitioned cache,
and limited partitioned-replicated cache. Async replication not supported and
due to these operations slow down. |
Rich options. Local, Mirrored,
Replicated, Partitioned, Partition-Replica, and Client Caches. Highly dynamic
and intelligent replication provided without compromising performance or
scalability. |
Cache Administration
|
Very basic cache admin GUI tool.
No dedicated cache monitoring tool. PowerShell based Cmdlets provided. |
Very powerful GUI tools. nCache
Manager for cache admin, and nCache Monitor for cache monitoring. PerfMon
counters and command line tools provided. |
Security & Encryption
|
No encryption provided for data
in the cache. Authentication/authorization provided. |
Powerful 3DES/256AES data encryption
in the cache provided as a config option. |
Synchronization with
|
No support for it. |
SqlDependency, OracleDependency,
DbDependency, & CLR Stored Procedures for database synchronization. File
based and Custom dependency for non-relational data sources. |
Runtime Data Sharing
|
Very limited support.
Publish/subscribe events not supported. Continuous Query not provided. Only
item level and cache. |
Powerful publish/subscribe event
supported. Continuous Query, .NET/Java portable binary data, and more. Use nCache
for publisher/consumer data sharing between .NET/.NET or .NET/Java apps. |
Search Cache (SQL-Like)
|
No support for it. |
Object Query Language (OQL) and
LINQ. Search cache on object attributes, Tags, and Named Tags with SQL-like
query. |
ASP.NET Support
|
Basic ASP.NET Session State support.
Session replication has performance and scalability issues. ASP.NET ViewState
support is very basic. ASP.NET Output Cache supported. |
Powerful ASP.NET Session State,
ASP.NET View State, ASP.NET Output Cache. Replication for sessions, view
state, and page output. Link view state with sessions for auto expiry and
much more. |
Third Party Integrations
|
No official support for
NHibernate, Entity Framework, and EntLib Caching Application Block. |
NHibernate Second Level Cache, |
Comments
Post a Comment