/Contribs/SharedCache/SharedCache.WinService/bin/Release/SharedCache.WinService.exe.config

http://aopcachingcomponents.codeplex.com · ASP.NET · 169 lines · 50 code · 0 blank · 119 comment · 0 complexity · 7080e1d55d3a553f9e00d30d36bc864c MD5 · raw file

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <configuration>
  3. <configSections>
  4. <section name="nlog" type="NLog.Config.ConfigSectionHandler, NLog" />
  5. <section name="replicatedSharedCache" type=" SharedCache.WinServiceCommon.Configuration.Server.IndexusServerProviderSection, &#xD;&#xA; SharedCache.WinServiceCommon" />
  6. </configSections>
  7. <appSettings>
  8. <add key="ClientSettingsProvider.ServiceUri" value="" />
  9. </appSettings>
  10. <replicatedSharedCache defaultProvider="ServerSharedCacheProvider">
  11. <serverSetting ServiceCacheIpAddress="127.0.0.1" ServiceCacheIpPort="48888" SharedCacheVersionNumber="3.0.5.0" LoggingEnable="1" ServiceFamilyMode="0" CacheAmountOfObjects="-1" CacheAmountFillFactorInPercentage="90" ServiceCacheCleanup="LRU" ServiceCacheCleanupThreadJob="3600000" TcpServerMaxThreadToSet="-1" TcpServerMinThreadToSet="-1" />
  12. <replicatedServers>
  13. <add key="SrvZh02" ipaddress="192.168.212.37" port="48888" />
  14. <!-- DO NOT DEFINE THE INSTANCE ITSELF !!! IT WILL BE AUTOMATICALLY REMOVED BY RUNTIME -->
  15. <!--
  16. ONLY CONFIGURE THIS IF YOU SET FAMILY MODE TO 1
  17. <add key="SrvZh03" ipaddress="127.0.0.1" port="48888" />
  18. <add key="SrvZh02" ipaddress="192.168.212.37" port="48888" />
  19. <add key="SrvZh04" ipaddress="192.168.212.11" port="48888" />
  20. <add key="SrvZh05db" ipaddress="192.168.212.12" port="48888" />
  21. -->
  22. </replicatedServers>
  23. <providers>
  24. <add name="ServerSharedCacheProvider" type="SharedCache.WinServiceCommon.Provider.Server.IndexusServerSharedCacheProvider, SharedCache.WinServiceCommon">
  25. </add>
  26. </providers>
  27. </replicatedSharedCache>
  28. <nlog autoReload="true" throwExceptions="true">
  29. <targets async="true">
  30. <target name="shared_cache_general" type="File" layout="${longdate}|${level:uppercase=true}|${aspnet-request:item=logSession}|${message}" filename="C:\temp\logs\server\${date:format=yyyy-MM-dd}_shared_cache_general_log.txt" />
  31. <target name="shared_cache_traffic" type="File" layout="${longdate}|${level:uppercase=true}|${aspnet-request:item=logSession}|${message}" filename="C:\temp\logs\server\${date:format=yyyy-MM-dd}_shared_cache_traffic_log.txt" />
  32. <target name="shared_cache_tracking" type="File" layout="${longdate}|${level:uppercase=true}|${aspnet-request:item=logSession}|${message}" filename="C:\temp\logs\server\${date:format=yyyy-MM-dd}_shared_cache_tracking_log.txt" />
  33. <target name="shared_cache_sync" type="File" layout="${longdate}|${level:uppercase=true}|${aspnet-request:item=logSession}|${message}" filename="C:\temp\logs\server\${date:format=yyyy-MM-dd}_shared_cache_sync_log.txt" />
  34. <target name="shared_cache_memory" type="File" layout="${longdate}|${level:uppercase=true}|${aspnet-request:item=logSession}|${message}" filename="C:\temp\logs\server\${date:format=yyyy-MM-dd}_shared_cache_memory_log.txt" />
  35. </targets>
  36. <rules>
  37. <logger name="General" minlevel="Debug" writeTo="shared_cache_general" final="true" />
  38. <logger name="Traffic" minlevel="Debug" writeTo="shared_cache_traffic" final="true" />
  39. <logger name="Tracking" minlevel="Debug" writeTo="shared_cache_tracking" final="true" />
  40. <logger name="Sync" minlevel="Debug" writeTo="shared_cache_sync" final="true" />
  41. <logger name="Memory" minlevel="Debug" writeTo="shared_cache_memory" final="true" />
  42. <logger name="*" minlevel="Debug" writeTo="shared_cache_general" />
  43. <logger name="*" minlevel="Info" writeTo="shared_cache_general" />
  44. </rules>
  45. </nlog>
  46. <!--Version Number, same like in assemblies-->
  47. <!--Should information be logged-->
  48. <!--Location of Cache Service-->
  49. <!--Location of Cache Service, the port number-->
  50. <!--
  51. 1 - Enabled
  52. 0 - Disabled
  53. remember to configure the section of replicatedSharedCache.
  54. -->
  55. <!--
  56. The maximum size of the objects in the Cache in MB.
  57. To make it unlimited, use value -1 which is the default
  58. in case of -1 you can receive OutOfMemoryException when the server is
  59. not able anymore to receive data.
  60. -->
  61. <!--
  62. If the cache received the fillfactor it will start to throw away unused items from the cache
  63. suggested is a value between: 85% - 95%
  64. Default value is 90%
  65. !!!This logic just apply in case CacheAmountOfObjects is different then -1!!!
  66. -->
  67. <!--
  68. - CacheItemPriority: A new option will be created where objects which are added to the cache receives a priority attribute.
  69. - LRU: Least Recent Used: The objects with the oldest request's will be deleted
  70. - LFU: Least Frequently Used: Means the object's witch are used less will be deleted from the cache / if all objects are used in same frequency the objects will be used in a randomized order
  71. - Timebased: The objects with the smallest time left in the cache will be deleted, in case all objects are used with max time, they will be deleted randomized
  72. - SIZE: Delete always biggest objects until it received the size of FillFactor
  73. - Lowest-Latency-First [LLF]: Delete smallest objects until configured FillFactor reached
  74. - Hybrid: Makes a combination between several parameters: TimeTaken, Amount of Requests, Size, Cache Life Time each parameter receives a number between 1 - n and those with the highest / lowest numbers will be deleted until configured FillFactory reached.
  75. Keys you can use: "CACHEITEMPRIORITY", "LRU", "LFU", "TIMEBASED", "SIZE", "LLF", "HYBRID"
  76. -->
  77. <!--
  78. Expire thread interval, if the cache contains data which expires
  79. this background thread cleans the cache up [milliseconds].
  80. 1 sec -> 1000
  81. 30 sec -> 30000
  82. 1 min -> 60000
  83. 1 hour -> 3600000
  84. 1 day -> 86400000
  85. -> do not define a bigger value then this, the system will fail to read it - its an int 32 value
  86. -> In case -1 is configured the Thread will be killed after startup.
  87. -->
  88. <!--
  89. version pre_release_1.0.2.132 and upper.
  90. Value: -1 means it will be ignored - which in most cases is suggested, if nothing is configured
  91. it will take the default value which is provided by the system [e.g: min. 3 max. 25]
  92. -->
  93. <!--<system.diagnostics>
  94. <sources>
  95. <source name="System.Net" tracemode="includehex" maxdatasize="1024">
  96. <listeners>
  97. <add name="System.Net"/>
  98. </listeners>
  99. </source>
  100. <source name="System.Net.Sockets">
  101. <listeners>
  102. <add name="System.Net"/>
  103. </listeners>
  104. </source>
  105. <source name="System.Net.Cache">
  106. <listeners>
  107. <add name="System.Net"/>
  108. </listeners>
  109. </source>
  110. </sources>
  111. <switches>
  112. <add name="System.Net" value="Verbose"/>
  113. <add name="System.Net.Sockets" value="Verbose"/>
  114. <add name="System.Net.Cache" value="Verbose"/>
  115. </switches>
  116. <sharedListeners>
  117. <add name="System.Net"
  118. type="System.Diagnostics.TextWriterTraceListener"
  119. initializeData="network.log"
  120. />
  121. </sharedListeners>
  122. <trace autoflush="true"/>
  123. </system.diagnostics>-->
  124. <!--<system.diagnostics>
  125. <sources>
  126. <source name="System.Net.Cache">
  127. <listeners>
  128. <add name="Cache"/>
  129. </listeners>
  130. </source>
  131. </sources>
  132. <switches>
  133. <add name="System.Net.Cache" value="31" />
  134. </switches>
  135. <sharedListeners>
  136. <add name="Cache" traceOutputOptions="ThreadId" type="System.Diagnostics.TextWriterTraceListener" initializeData="Cache.log"/>
  137. </sharedListeners>
  138. <trace autoflush="true" />
  139. </system.diagnostics>-->
  140. <!--<system.diagnostics>
  141. <sources>
  142. <source name="System.Net.Sockets">
  143. <listeners>
  144. <add name="Sockets"/>
  145. </listeners>
  146. </source>
  147. </sources>
  148. <switches>
  149. <add name="System.Net.Sockets" value="31" />
  150. </switches>
  151. <sharedListeners>
  152. <add name="Sockets" traceOutputOptions="ThreadId" type="System.Diagnostics.TextWriterTraceListener" initializeData="Sockets.log"/>
  153. </sharedListeners>
  154. <trace autoflush="true" />
  155. </system.diagnostics>-->
  156. <system.web>
  157. <membership defaultProvider="ClientAuthenticationMembershipProvider">
  158. <providers>
  159. <add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
  160. </providers>
  161. </membership>
  162. <roleManager defaultProvider="ClientRoleProvider" enabled="true">
  163. <providers>
  164. <add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
  165. </providers>
  166. </roleManager>
  167. </system.web>
  168. </configuration>