AppFabric for caching
It is possible to use app开发者_Go百科fabric for non web/asp.net caching ?
say instead of ncache/memcached etc.
AppFabric is application-agnostic - there's nothing to prevent you using it in WinForms/WPF/Windows Services applications, in fact I can see that it would lend itself quite well to a Windows Service.
I have successfully experimented with Microsoft's project "Velocity" for caching in a non-web application. Velocity was the code name for what became AppFabric caching. I have not tried AppFabric caching, because I only have access to Windows XP/Server 2003 systems, and AppFabric requires Vista/7/Server 2008. Looking at the AppFabric caching documentation, I don't see any reason why it would now only work for web applications.
In fact, you can store any CLR data in appfabric cache, so that is nothing bind the cache service with the web application.
If you want to compare Appfabric with other cache solution, I think you need consider other points. I think ncache/memcached can also be used in non web/asp.net applications.
But appfabric cache solution have some other limitations. For example, if you want to use it, you need have Enterprise Edition (or higher) of Windows Server 2008 or Windows Server 2008 R2. You know, enterprise edition is very expensive.
精彩评论