Exemplo n.º 1
0
 private ClientContext(string name, DFSClient.Conf conf)
 {
     this.name              = name;
     this.confString        = ConfAsString(conf);
     this.shortCircuitCache = new ShortCircuitCache(conf.shortCircuitStreamsCacheSize,
                                                    conf.shortCircuitStreamsCacheExpiryMs, conf.shortCircuitMmapCacheSize, conf.shortCircuitMmapCacheExpiryMs
                                                    , conf.shortCircuitMmapCacheRetryTimeout, conf.shortCircuitCacheStaleThresholdMs
                                                    , conf.shortCircuitSharedMemoryWatcherInterruptCheckMs);
     this.peerCache                 = new PeerCache(conf.socketCacheCapacity, conf.socketCacheExpiry);
     this.keyProviderCache          = new KeyProviderCache(conf.keyProviderCacheExpiryMs);
     this.useLegacyBlockReaderLocal = conf.useLegacyBlockReaderLocal;
     this.domainSocketFactory       = new DomainSocketFactory(conf);
     this.byteArrayManager          = ByteArrayManager.NewInstance(conf.writeByteArrayManagerConf
                                                                   );
 }