Why use shared cache?
There is no more efficient way to increase the scalable performance of applications then the use caching to unload deeper layers.
>> Shared Cache>> Shared Cache Config>> Configuration Server>> Replicated Caching
Server configuration for replicated caching
In Shared Cache Topology section we have listed advanteges of replicated caching. Lets assume we have 3 IIS WebServers in the same zone and we want to configure them for replicated caching where on each server an instance of indeXus.Net Shared Cache Server is installed.
Server details:
|
Server no. 1
|
Server no. 2
|
Server no. 3
|
-
Name: WebSrv20
-
IP: 192.168.1.20
|
-
Name: WebSrv30
-
IP: 192.168.1.30
|
-
Name: WebSrv40
-
IP: 192.168.1.40
|
Example of a replicated server configuration file
The following configuration fits for server no: 1.
Notice: The most important thing is that you add your server nodes and set ServiceFamiliyMode="1" to enable replication. If you only configure the replicatedServers will be not enough and will not work without to enable familiy mode.
<replicatedSharedCache defaultProvider="ServerSharedCacheProvider">
<serverSetting
ServiceCacheIpAddress="127.0.0.1"
ServiceCacheIpPort="48888"
SharedCacheVersionNumber="2.0.3.268"
LoggingEnable="1"
ServiceFamilyMode="1"
CacheAmountOfObjects="200"
CacheAmountFillFactorInPercentage="90"
ServiceCacheCleanup="LRU"
ServiceCacheCleanupThreadJob="1"
TcpServerMaxThreadToSet="-1"
TcpServerMinThreadToSet="-1"
/>
<replicatedServers>
<add key="WebSrv30" ipaddress="192.168.1.30" port="48888" />
<add key="WebSrv40" ipaddress="192.168.1.40" port="48888" />
</replicatedServers>
<providers>
<add
name="ServerSharedCacheProvider"
type=">
MergeSystem.Indexus.WinServiceCommon.Provider.
Server.IndexusServerSharedCacheProvider,
MergeSystem.Indexus.WinServiceCommon"
</add>
</providers>
</replicatedSharedCache>
|
For the other 2 server nodes you alwasy take the 2 other servers which you add to replicatedServers.
Server node no. 2:
<replicatedServers>
<add key="WebSrv20" ipaddress="192.168.1.20" port="48888" />
<add key="WebSrv40" ipaddress="192.168.1.40" port="48888" />
</replicatedServers>
|
Server node no. 3:
<replicatedServers>
<add key="WebSrv20" ipaddress="192.168.1.20" port="48888" />
<add key="WebSrv30" ipaddress="192.168.1.30" port="48888" />
</replicatedServers>
|