appfabric

Detect and Delete Orphaned Queues, Topics, or Subscriptions on Azure Service Bus

让人想犯罪 __ 提交于 2019-12-01 05:35:10
问题 If there are no longer any publishers or subscribers reading nor writing to a Queue, Topic, or Subscription, because of crashes or other abnormal terminations (instance restart, etc.), is that Queue/Topic/Subscription effectively orphaned? I tested this by creating a few Queues, and then terminating the applications. Those Queues were still on the Service Bus a long time later. It seems that they will just stay there forever. That would be wonderful if we WANTED that behavior, but in this

AppFabric Caching - Can I specify serialization style used for all objects?

[亡魂溺海] 提交于 2019-12-01 00:47:42
问题 An object which implements some custom serialization can be serialized and deserialized to different formats, for example to Xml or byte[]. I have run into a problem where when I put to cache, AppFabric runs the IXmlSerializable implementation on a class when I would rather force it to go with binary. AppFabric Caching - What are its serialization and deserialization requirements for an object? Can I configure this? (At the moment the workaround is to serialize the object programatically to a

AppFabric get named cache object count

怎甘沉沦 提交于 2019-11-30 17:48:21
问题 I have a named cache and simply want to return (programmatically) its object count. I have a DataCache object: cache = factory.GetCache("cacheName"); I'm currently trying the following: cache.GetObjectsInRegion("cacheName").Count(); I realize that a region is different than a named cache, but I don't see any other methods that would allow me to achieve this (although I'm sure there are). Any thoughts? 回答1: This isn't as straightforward as you might have expected - but it is do-able. When an

NHibernate 2nd level caching with AppFabric

瘦欲@ 提交于 2019-11-30 14:43:09
Has anyone used AppFabric for their second level caching? I know it's to follow the same api as for Velocity ( nhibernate.caches.velocity ) but wanted to know if anyone already had some production experience of using it and if they knew of any particular tips or problems? PhilPursglove The only problem I'm currently aware of is what was covered in this question , that the references in the Velocity cache code are out of date and need updating to the AppFabric v1 release assemblies. I haven't used AppFabric as second level cache but I've used NCache as second level cache for Nhibernate and

SQLCacheDependency and AppFabric Server

徘徊边缘 提交于 2019-11-30 13:49:12
I have a situation where I need to replace our current file based cache dependency system with a new one. What I am looking at is moving towards using AppFabric for caching. I was wondering if the SQLDependencyCaching technique where the table notifies the application of data updates works with AppFabric as it does with ASP.NET built in caching? There is no support within AppFabric caching for the SqlCacheDependency mechanism (or in fact for any kind of dependency). However, AppFabric 1.1 introduces the DataCacheStoreProvider class, which can be used to ensure that the cache is always in sync

Starting AppFabric Cache Cluster automatically

一世执手 提交于 2019-11-30 12:48:36
Is there a way to start the cache cluster automatically on system startup? I'm running it on a remote PC and when it gets restarted I have to remote into it and restart the cache cluster from Powershell using Start-CacheCluster, and would like to not have to do this. Thanks, James PhilPursglove Yes - if you change the startup mode of the AppFabric Caching Service from Manual to Automatic, then the service will start once the server has finished booting. (source: philippursglove.com ) I suspect that as AppFabric starts to move into production clusters, this will become a 'best practice' thing

Should a Repository return IEnumerable<T> , IQueryable<T> or List<T>?

好久不见. 提交于 2019-11-30 11:38:30
I'd like to make my application as flexible as possible, but not dig myself into a hole by making my Interface too specific. What is the best object type for a repository? IEnumerable, IQueryable, or List? The technologies I'm considering using are Azure App Fabric Caching Entity Framework 4.1 Possibly Windows Server AppFabric I would say build your DAL using IQueryable, and pass it around, make sure your object contects lifetime is the request. This way you will get benefit of delayed execution, but are exposed to the risk of inefficient querying of database. Then make sure you performance

AppFabric vs System.Runtime.Caching

那年仲夏 提交于 2019-11-30 08:44:21
问题 TLDR version: For caching many small database tables that rarely change in my .NET4 WCF service. Which technology will be easiest to implement, easiest to maintain, and best to perform and why? Long version: I'm starting to work on a caching strategy for a new project. It used to be simple because there were fewer pre-packaged options (Enterprise Library for starters), but now with the .NET 4 framework and AppFabric being available, I'm having a harder time deciding on a solution. Basically,

ASP.Net AppFabric Cache missing Flush/Clear and Count/GetCount methods?

心不动则不痛 提交于 2019-11-30 04:50:51
问题 I am trying to convert a solution using EntLib into using AppFabric caching. By help of a few extension methods this is a fairly pain-free process. Extension methods I use: public static bool Contains(this DataCache dataCache, string key) { return dataCache.Get(key) != null; } public static object GetData(this DataCache dataCache, string key) { return dataCache.Get(key); } But there are two features of EntLib I find difficult to convert. Namely "Count" (counting number of keys in cache) and

AppFabric Caching - Proper use of DataCacheFactory and DataCache

谁说胖子不能爱 提交于 2019-11-29 20:26:13
I am looking for the most performant way to arrange usage of the datacache and datacache factory for AppFabric caching calls, for between 400 and 700 cache gets per page load (and barely any puts). It seems that using a single static DataCacheFactory (or possibly a couple in a round-robin setup) is the way to go. Do I call GetCache("cacheName") for every DataCache object request, or do I make one static at the time DataCache factory is initialized and use that for all calls? Do I have to handle exceptions, check for fail codes and attempt retries? Do I have to consider contention when more