Пример #1
0
        protected BlockStoreLoopStep(BlockStoreLoop blockStoreLoop, ILoggerFactory loggerFactory)
        {
            Guard.NotNull(blockStoreLoop, nameof(blockStoreLoop));

            this.loggerFactory  = loggerFactory;
            this.BlockStoreLoop = blockStoreLoop;
        }
Пример #2
0
 public BlockStoreFeature(
     ConcurrentChain chain,
     IConnectionManager connectionManager,
     Signals.Signals signals,
     IBlockRepository blockRepository,
     IBlockStoreCache blockStoreCache,
     StoreBlockPuller blockPuller,
     BlockStoreLoop blockStoreLoop,
     BlockStoreManager blockStoreManager,
     BlockStoreSignaled blockStoreSignaled,
     INodeLifetime nodeLifetime,
     NodeSettings nodeSettings,
     ILoggerFactory loggerFactory,
     StoreSettings storeSettings,
     string name = "BlockStore")
 {
     this.name               = name;
     this.chain              = chain;
     this.signals            = signals;
     this.blockRepository    = blockRepository;
     this.blockStoreCache    = blockStoreCache;
     this.blockPuller        = blockPuller;
     this.blockStoreLoop     = blockStoreLoop;
     this.blockStoreManager  = blockStoreManager;
     this.blockStoreSignaled = blockStoreSignaled;
     this.nodeLifetime       = nodeLifetime;
     this.connectionManager  = connectionManager;
     this.nodeSettings       = nodeSettings;
     this.logger             = loggerFactory.CreateLogger(this.GetType().FullName);
     this.loggerFactory      = loggerFactory;
     storeSettings.Load(nodeSettings);
     this.storeSettings = storeSettings;
 }
Пример #3
0
 public BlockStoreSignaled(
     BlockStoreLoop blockStoreLoop,
     ConcurrentChain chain,
     StoreSettings storeSettings,
     ChainState chainState,
     IConnectionManager connection,
     INodeLifetime nodeLifetime,
     IAsyncLoopFactory asyncLoopFactory,
     ILoggerFactory loggerFactory,
     IBlockStoreCache blockStoreCache,
     string name = "BlockStore")
 {
     this.asyncLoopFactory = asyncLoopFactory;
     this.blocksToAnnounce = new ConcurrentQueue <ChainedBlock>();
     this.blockStoreLoop   = blockStoreLoop;
     this.chain            = chain;
     this.chainState       = chainState;
     this.connection       = connection;
     this.name             = name;
     this.nodeLifetime     = nodeLifetime;
     this.logger           = loggerFactory.CreateLogger(this.GetType().FullName);
     this.storeSettings    = storeSettings;
     this.blockStoreCache  = blockStoreCache;
 }
Пример #4
0
 public BlockStoreManager(IBlockRepository blockRepository, ChainState chainState, BlockStoreLoop blockStoreLoop)
 {
     this.BlockRepository = blockRepository;
     this.ChainState      = chainState;
     this.BlockStoreLoop  = blockStoreLoop;
 }