且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

几个问题

更新时间:2023-12-03 14:46:10


您好,

Hi,

我对AppFabric服务有几个问题:

I had a few questions about AppFabric service:

1。我想配置启用了本地缓存的缓存客户端。但是,我希望缓存集群中存在的所有信息都存在于本地缓存中。我怎样才能做到这一点?如果客户有足够的内存就足够了吗?

1. I want to configure cache client with local cache enabled. However I want ALL the information present in the cache cluster to be present in the local cache. How can I do this? Is it sufficient if the client has enough memory?

2。无论如何,如果密钥未知,是否还要从缓存中检索对象?

2. Is there anyway to retrieve objects from the cache if the key is not known?

谢谢。


本地缓存包含对象之前已从分布式缓存中检索到的,并且未按每个同步设置和/或通知进行无效。如果您已经检索了整个数据,那么是的,所有数据都将在您的
本地缓存中。但是,如果您打算执行批量操作(按区域或按标记),您应该知道从不使用本地缓存 - 所有批量操作都是针对分布式缓存执行的。 



至于检索没有键的对象,如果你使用标签和/或区域,是的,你可以在不知道其密钥的情况下检索一个对象。否则,没有。 

The local cache contains objects that have been previously retrieved from the distributed cache, and have not been invalidated per sync settings and/or notifications. If you have retrieved the entire population of your data, then yes, all of it will be in your local cache. However, if you're intending to perform bulk operations (by region or by tag) you should be aware that the local cache is never used -- all bulk operations are performed against the distributed cache. 

As far as retrieving objects without keys, if you use tags and/or regions, yes, you could retrieve an object without knowing its key. Otherwise, no.