public RepairingHandler(Guid localUuid, NearCache nearCache, PartitionService partitionService, int maxToleratedMissCount) { _localUuid = localUuid; _nearCache = nearCache; _partitionService = partitionService; _partitionCount = partitionService.GetPartitionCount(); _metaDataContainers = CreateMetadataContainers(_partitionCount); _maxToleratedMissCount = maxToleratedMissCount; }
public RepairingHandler(string localUuid, NearCache nearCache, IClientPartitionService partitionService) { _localUuid = localUuid; _nearCache = nearCache; _partitionService = partitionService; _partitionCount = partitionService.GetPartitionCount(); _metaDataContainers = CreateMetadataContainers(_partitionCount); _maxToleratedMissCount = NearCacheManager.GetMaxToleratedMissCount(); }
public BaseNearCache GetOrCreateNearCache(string mapName) { var nearCacheConfig = _client.ClientConfig.GetNearCacheConfig(mapName); return(nearCacheConfig == null ? null : _caches.GetOrAdd(mapName, newMapName => { var nearCache = new NearCache(newMapName, _client, nearCacheConfig); InitNearCache(nearCache); return nearCache; })); }
public BaseNearCache GetOrCreateNearCache(string mapName) { var nearCacheConfig = _client.GetClientConfig().GetNearCacheConfig(mapName); return(nearCacheConfig == null ? null : _caches.GetOrAdd(mapName, newMapName => { BaseNearCache nearCache; if (SupportsRepairableNearCache()) { nearCache = new NearCache(newMapName, _client, nearCacheConfig); } else { nearCache = new NearCachePre38(newMapName, _client, nearCacheConfig); } InitNearCache(nearCache); return nearCache; })); }