public DistributedContentStoreFactory(DistributedCacheServiceArguments arguments) { _logger = arguments.Logger; _arguments = arguments; _redisContentSecretNames = arguments.Configuration.DistributedContentSettings.GetRedisConnectionSecretNames(arguments.HostInfo.StampId); _distributedSettings = arguments.Configuration.DistributedContentSettings; _keySpace = string.IsNullOrWhiteSpace(_arguments.Keyspace) ? RedisContentLocationStoreFactory.DefaultKeySpace : _arguments.Keyspace; _fileSystem = new PassThroughFileSystem(_logger); _secretRetriever = new DistributedCacheSecretRetriever(arguments); var bandwidthCheckedCopier = new BandwidthCheckedCopier(_arguments.Copier, BandwidthChecker.Configuration.FromDistributedContentSettings(_distributedSettings), _logger); _orderedResolvedCacheSettings = ResolveCacheSettingsInPrecedenceOrder(arguments); Contract.Assert(_orderedResolvedCacheSettings.Count != 0); RedisContentLocationStoreConfiguration = CreateRedisConfiguration(); _distributedContentStoreSettings = CreateDistributedStoreSettings(_arguments, RedisContentLocationStoreConfiguration); _copier = new DistributedContentCopier <AbsolutePath>( _distributedContentStoreSettings, _fileSystem, fileCopier: bandwidthCheckedCopier, fileExistenceChecker: _arguments.Copier, _arguments.CopyRequester, _arguments.PathTransformer, _arguments.Overrides.Clock ); _redisMemoizationStoreFactory = new Lazy <RedisMemoizationStoreFactory>(() => CreateRedisCacheFactory()); }
public DistributedContentStoreFactory(DistributedCacheServiceArguments arguments) { _logger = arguments.Logger; _arguments = arguments; _redisContentSecretNames = arguments.Configuration.DistributedContentSettings.GetRedisConnectionSecretNames(arguments.HostInfo.StampId); _distributedSettings = arguments.Configuration.DistributedContentSettings; _keySpace = string.IsNullOrWhiteSpace(_arguments.Keyspace) ? RedisContentLocationStoreFactory.DefaultKeySpace : _arguments.Keyspace; _fileSystem = new PassThroughFileSystem(_logger); _secretRetriever = new DistributedCacheSecretRetriever(arguments); }
public DistributedContentStoreFactory( DistributedCacheServiceArguments arguments, RedisContentSecretNames redisContentSecretNames) { _logger = arguments.Logger; _arguments = arguments; _redisContentSecretNames = redisContentSecretNames; _distributedSettings = arguments.Configuration.DistributedContentSettings; _keySpace = string.IsNullOrWhiteSpace(_arguments.Keyspace) ? RedisContentLocationStoreFactory.DefaultKeySpace : _arguments.Keyspace; _fileSystem = new PassThroughFileSystem(_logger); }