Пример #1
0
        public FederationVotingController(IFederationManager fedManager, ILoggerFactory loggerFactory, VotingManager votingManager, Network network)
        {
            this.fedManager    = fedManager;
            this.votingManager = votingManager;
            this.network       = network;

            this.logger = loggerFactory.CreateLogger(this.GetType().FullName);
        }
Пример #2
0
        public DefaultVotingController(IFederationManager fedManager, ILoggerFactory loggerFactory, VotingManager votingManager,
                                       IWhitelistedHashesRepository whitelistedHashesRepository, Network network, IPollResultExecutor pollExecutor)
        {
            this.fedManager    = fedManager;
            this.votingManager = votingManager;
            this.whitelistedHashesRepository = whitelistedHashesRepository;
            this.network      = network;
            this.pollExecutor = pollExecutor;

            this.logger = loggerFactory.CreateLogger(this.GetType().FullName);
        }
Пример #3
0
        public IdleFederationMembersKicker(ISignals signals, Network network, IKeyValueRepository keyValueRepository, IConsensusManager consensusManager,
                                           IFederationManager federationManager, ISlotsManager slotsManager, VotingManager votingManager, ILoggerFactory loggerFactory, IDateTimeProvider timeProvider)
        {
            this.signals            = signals;
            this.network            = network;
            this.keyValueRepository = keyValueRepository;
            this.consensusManager   = consensusManager;
            this.federationManager  = federationManager;
            this.slotsManager       = slotsManager;
            this.votingManager      = votingManager;
            this.timeProvider       = timeProvider;

            this.consensusFactory = this.network.Consensus.ConsensusFactory as PoAConsensusFactory;
            this.logger           = loggerFactory.CreateLogger(this.GetType().FullName);
            this.federationMemberMaxIdleTimeSeconds = ((PoAConsensusOptions)network.Consensus.Options).FederationMemberMaxIdleTimeSeconds;
        }