public PosMinting(ConsensusLoop consensusLoop, ConcurrentChain chain, Network network, ConnectionManager connection, IDateTimeProvider dateTimeProvider, AssemblerFactory blockAssemblerFactory, BlockRepository blockRepository, BlockStore.ChainBehavior.ChainState chainState, Signals signals, FullNode.CancellationProvider cancellationProvider, NodeSettings settings, CoinView coinView, StakeChain stakeChain) { this.consensusLoop = consensusLoop; this.chain = chain; this.network = network; this.connection = connection; this.dateTimeProvider = dateTimeProvider; this.blockAssemblerFactory = blockAssemblerFactory; this.blockRepository = blockRepository; this.chainState = chainState; this.signals = signals; this.cancellationProvider = cancellationProvider; this.settings = settings; this.coinView = coinView; this.stakeChain = stakeChain; this.minerSleep = 500; // GetArg("-minersleep", 500); this.lastCoinStakeSearchTime = Utils.DateTimeToUnixTime(this.dateTimeProvider.GetTimeOffset()); // startup timestamp this.reserveBalance = 0; // TOOD:settings.ReserveBalance this.minimumInputValue = 0; this.posConsensusValidator = consensusLoop.Validator as PosConsensusValidator; }
private readonly ConcurrentDictionary <uint256, uint256> blockHashesToAnnounce; // maybe replace with a task scheduler public BlockStoreSignaled(BlockStoreLoop storeLoop, ConcurrentChain chain, NodeSettings nodeArgs, BlockStore.ChainBehavior.ChainState chainState, ConnectionManager connection) { this.storeLoop = storeLoop; this.chain = chain; this.nodeArgs = nodeArgs; this.chainState = chainState; this.connection = connection; this.blockHashesToAnnounce = new ConcurrentDictionary <uint256, uint256>(); }
public BlockStoreManager(ConcurrentChain chain, ConnectionManager connection, BlockRepository blockRepository, IDateTimeProvider dateTimeProvider, NodeSettings nodeArgs, BlockStore.ChainBehavior.ChainState chainState, BlockStoreLoop blockStoreLoop) { this.chain = chain; this.connection = connection; this.BlockRepository = blockRepository; this.dateTimeProvider = dateTimeProvider; this.nodeArgs = nodeArgs; this.ChainState = chainState; this.BlockStoreLoop = blockStoreLoop; }
public BlockStoreLoop(ConcurrentChain chain, BlockRepository blockRepository, NodeSettings nodeArgs, BlockStore.ChainBehavior.ChainState chainState, StoreBlockPuller blockPuller) { this.chain = chain; this.BlockRepository = blockRepository; this.nodeArgs = nodeArgs; this.blockPuller = blockPuller; this.ChainState = chainState; PendingStorage = new ConcurrentDictionary <uint256, BlockPair>(); }
public MempoolBehavior(MempoolValidator validator, MempoolManager manager, MempoolOrphans orphans, ConnectionManager connectionManager, BlockStore.ChainBehavior.ChainState chainState) { this.validator = validator; this.manager = manager; this.orphans = orphans; this.connectionManager = connectionManager; this.chainState = chainState; this.inventoryTxToSend = new Dictionary <uint256, uint256>(); this.filterInventoryKnown = new Dictionary <uint256, uint256>(); }
public PowMining(ConsensusLoop consensusLoop, ConcurrentChain chain, Network network, IDateTimeProvider dateTimeProvider, AssemblerFactory blockAssemblerFactory, BlockRepository blockRepository, BlockStore.ChainBehavior.ChainState chainState, Signals signals, FullNode.CancellationProvider cancellationProvider) { this.consensusLoop = consensusLoop; this.chain = chain; this.network = network; this.dateTimeProvider = dateTimeProvider; this.blockAssemblerFactory = blockAssemblerFactory; this.blockRepository = blockRepository; this.chainState = chainState; this.signals = signals; this.cancellationProvider = cancellationProvider; }
public PowMining(ConsensusLoop consensusLoop, ConcurrentChain chain, Network network, IDateTimeProvider dateTimeProvider, AssemblerFactory blockAssemblerFactory, BlockRepository blockRepository, BlockStore.ChainBehavior.ChainState chainState, Signals signals, INodeLifetime nodeLifetime, IAsyncLoopFactory asyncLoopFactory) { this.consensusLoop = consensusLoop; this.chain = chain; this.network = network; this.dateTimeProvider = dateTimeProvider; this.blockAssemblerFactory = blockAssemblerFactory; this.blockRepository = blockRepository; this.chainState = chainState; this.signals = signals; this.nodeLifetime = nodeLifetime; this.asyncLoopFactory = asyncLoopFactory; }
public BlockStoreLoop(ConcurrentChain chain, BlockRepository blockRepository, NodeSettings nodeArgs, BlockStore.ChainBehavior.ChainState chainState, StoreBlockPuller blockPuller, BlockStoreCache cache, INodeLifetime nodeLifetime, IAsyncLoopFactory asyncLoopFactory) { this.chain = chain; this.BlockRepository = blockRepository; this.nodeArgs = nodeArgs; this.blockPuller = blockPuller; this.ChainState = chainState; this.blockStoreCache = cache; this.nodeLifetime = nodeLifetime; this.asyncLoopFactory = asyncLoopFactory; this.PendingStorage = new ConcurrentDictionary <uint256, BlockPair>(); this.blockStoreStats = new BlockStoreStats(this.BlockRepository, this.blockStoreCache); }