public PoAMiner(
            IConsensusManager consensusManager,
            IDateTimeProvider dateTimeProvider,
            Network network,
            INodeLifetime nodeLifetime,
            ILoggerFactory loggerFactory,
            IInitialBlockDownloadState ibdState,
            BlockDefinition blockDefinition,
            SlotsManager slotsManager,
            IConnectionManager connectionManager,
            PoABlockHeaderValidator poaHeaderValidator,
            FederationManager federationManager,
            IIntegrityValidator integrityValidator,
            IWalletManager walletManager,
            INodeStats nodeStats)
        {
            this.consensusManager   = consensusManager;
            this.dateTimeProvider   = dateTimeProvider;
            this.network            = network as PoANetwork;
            this.ibdState           = ibdState;
            this.blockDefinition    = blockDefinition;
            this.slotsManager       = slotsManager;
            this.connectionManager  = connectionManager;
            this.poaHeaderValidator = poaHeaderValidator;
            this.federationManager  = federationManager;
            this.integrityValidator = integrityValidator;
            this.walletManager      = walletManager;

            this.logger       = loggerFactory.CreateLogger(this.GetType().FullName);
            this.cancellation = CancellationTokenSource.CreateLinkedTokenSource(new[] { nodeLifetime.ApplicationStopping });

            nodeStats.RegisterStats(this.AddComponentStats, StatsType.Component);
        }
Exemple #2
0
        public SlotsManager(Network network, FederationManager federationManager, ILoggerFactory loggerFactory)
        {
            Guard.NotNull(network, nameof(network));
            this.federationManager = Guard.NotNull(federationManager, nameof(federationManager));

            this.consensusOptions = (network as PoANetwork).ConsensusOptions;
            this.logger           = loggerFactory.CreateLogger("Impleum.Bitcoin.FullNode");
        }
        public SlotsManager(Network network, FederationManager federationManager, ILoggerFactory loggerFactory)
        {
            Guard.NotNull(network, nameof(network));
            this.federationManager = Guard.NotNull(federationManager, nameof(federationManager));

            this.consensusOptions = (network as PoANetwork).ConsensusOptions;
            this.logger           = loggerFactory.CreateLogger(this.GetType().FullName);
        }
 public PoAConsensusRuleEngine(Network network, ILoggerFactory loggerFactory, IDateTimeProvider dateTimeProvider, ChainIndexer chainIndexer,
                               NodeDeployments nodeDeployments, ConsensusSettings consensusSettings, ICheckpoints checkpoints, ICoinView utxoSet, IChainState chainState,
                               IInvalidBlockHashStore invalidBlockHashStore, INodeStats nodeStats, SlotsManager slotsManager, PoABlockHeaderValidator poaHeaderValidator,
                               VotingManager votingManager, FederationManager federationManager)
     : base(network, loggerFactory, dateTimeProvider, chainIndexer, nodeDeployments, consensusSettings, checkpoints, utxoSet, chainState, invalidBlockHashStore, nodeStats)
 {
     this.SlotsManager       = slotsManager;
     this.PoaHeaderValidator = poaHeaderValidator;
     this.VotingManager      = votingManager;
     this.FederationManager  = federationManager;
 }
        public PoAFeature(FederationManager federationManager, PayloadProvider payloadProvider, IConnectionManager connectionManager, ConcurrentChain chain,
                          IInitialBlockDownloadState initialBlockDownloadState, IConsensusManager consensusManager, IPeerBanning peerBanning, ILoggerFactory loggerFactory,
                          IPoAMiner miner)
        {
            this.federationManager         = federationManager;
            this.connectionManager         = connectionManager;
            this.chain                     = chain;
            this.initialBlockDownloadState = initialBlockDownloadState;
            this.consensusManager          = consensusManager;
            this.peerBanning               = peerBanning;
            this.loggerFactory             = loggerFactory;
            this.miner                     = miner;

            payloadProvider.DiscoverPayloads(this.GetType().Assembly);
        }
        public PoAFeature(FederationManager federationManager, PayloadProvider payloadProvider, IConnectionManager connectionManager, ConcurrentChain chain,
                          IInitialBlockDownloadState initialBlockDownloadState, IConsensusManager consensusManager, IPeerBanning peerBanning, ILoggerFactory loggerFactory,
                          IPoAMiner miner, VotingManager votingManager, Network network, WhitelistedHashesRepository whitelistedHashesRepository)
        {
            this.federationManager           = federationManager;
            this.connectionManager           = connectionManager;
            this.chain                       = chain;
            this.initialBlockDownloadState   = initialBlockDownloadState;
            this.consensusManager            = consensusManager;
            this.peerBanning                 = peerBanning;
            this.loggerFactory               = loggerFactory;
            this.miner                       = miner;
            this.votingManager               = votingManager;
            this.whitelistedHashesRepository = whitelistedHashesRepository;
            this.network                     = network;

            payloadProvider.DiscoverPayloads(this.GetType().Assembly);
        }
Exemple #7
0
            public PoAFeature(FederationManager federationManager, PayloadProvider payloadProvider)
            {
                this.federationManager = federationManager;

                payloadProvider.DiscoverPayloads(this.GetType().Assembly);
            }