有许多服务器的路由模式 [英] Routing mode with many servers

查看:72
本文介绍了有许多服务器的路由模式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在使用路由模式与CacheCluster机器进行通信。我们在CacheCluster中有2台机器,我可以假设,在生产中,我们的整体系统将更加强大(如果一台CacheCluster机器关闭),如果
我们将两台服务器分配给AppFabric配置?见下文:

Hi, we are using Routing mode to communicate with CacheCluster machines. We have 2 machines in the CacheCluster, am I right to assume that, in production, our overall system will be more robust (in case one CacheCluster machine is down) if we assign both servers to the AppFabric configuration? See below:

var configuration =
new DataCacheFactoryConfiguration ();

var configuration = new DataCacheFactoryConfiguration();

var servers =
DataCacheServerEndpoint [2];

var servers = new DataCacheServerEndpoint[2];

servers [0] =
new DataCacheServerEndpoint (cacheHostName0,cachePort0);

servers[0] = new DataCacheServerEndpoint(cacheHostName0, cachePort0);

servers [1] =
new DataCacheServerEndpoint (cacheHostName1,cachePort1);

servers[1] = new DataCacheServerEndpoint(cacheHostName1, cachePort1);

configuration.Servers = servers;

configuration.Servers = servers;

 

configuration.LocalCacheProperties =
new DataCacheLocalCacheProperties int 。MaxValue,expirationTime,
DataCacheLocalCacheInvalidationPolicy .TimeoutBased);

configuration.LocalCacheProperties = new DataCacheLocalCacheProperties(int.MaxValue, expirationTime, DataCacheLocalCacheInvalidationPolicy.TimeoutBased);

var factory =
new DataCacheFactory (配置);

var factory = new DataCacheFactory(configuration);

realCache = factory.GetCache(cacheName);

 

 

推荐答案

您好。在这种情况下,您的系统应该更加强大,因为如果一个缓存主机关闭,应用程序仍然可以连接到缓存集群使用来自第二个缓存主机的信息。这假设您使用SQL Server作为
提供程序。如果您使用的是XML,那么您必须运行大多数主机主机。机器群集,这意味着两台机器必须始终启动。如果您使用SQL Server作为缓存群集配置存储提供程序,那么一台机器
可能会关闭,群集将继续运行。

Hello. Your system should be more robust in this case, because if one cache host is down, the application will still be able to connect to the cache cluster using the information from the second cache host. This assumes that you are using SQL Server as the provider. If you are using XML, then you have to have a majority of lead hosts running. In a 2-machine cluster, this means that both machines must always be up. If you are using SQL Server for the cache cluster configuration store provider, then one machine could go down and the cluster would remain running.

Jason Roth

Jason Roth


这篇关于有许多服务器的路由模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆