Dash Core Source Documentation (0.16.0.1)
Find detailed information regarding the Dash Core source code.
quorums_dkgsessionhandler.h
Go to the documentation of this file.
67 std::vector<std::pair<NodeId, std::shared_ptr<Message>>> PopAndDeserializeMessages(size_t maxCount)
122 CDKGSessionHandler(const Consensus::LLMQParams& _params, CBLSWorker& blsWorker, CDKGSessionManager& _dkgManager);
126 void ProcessMessage(CNode* pfrom, const std::string& strCommand, CDataStream& vRecv, CConnman& connman);
138 void WaitForNextPhase(QuorumPhase curPhase, QuorumPhase nextPhase, const uint256& expectedQuorumHash, const WhileWaitFunc& runWhileWaiting);
140 void SleepBeforePhase(QuorumPhase curPhase, const uint256& expectedQuorumHash, double randomSleepFactor, const WhileWaitFunc& runWhileWaiting);
141 void HandlePhase(QuorumPhase curPhase, QuorumPhase nextPhase, const uint256& expectedQuorumHash, double randomSleepFactor, const StartPhaseFunc& startPhaseFunc, const WhileWaitFunc& runWhileWaiting);
Acts as a FIFO queue for incoming DKG messages.
Definition: quorums_dkgsessionhandler.h:36
CDKGPendingMessages pendingComplaints
Definition: quorums_dkgsessionhandler.h:117
CDKGPendingMessages pendingContributions
Definition: quorums_dkgsessionhandler.h:116
void PushPendingMessage(NodeId from, CDataStream &vRecv)
Definition: quorums_dkgsessionhandler.cpp:27
std::set< uint256 > seenMessages
Definition: quorums_dkgsessionhandler.h:47
void ProcessMessage(CNode *pfrom, const std::string &strCommand, CDataStream &vRecv, CConnman &connman)
Definition: quorums_dkgsessionhandler.cpp:129
void PushPendingMessage(NodeId from, Message &msg)
Definition: quorums_dkgsessionhandler.h:58
std::function< void()> StartPhaseFunc
Definition: quorums_dkgsessionhandler.h:136
bool HasSeen(const uint256 &hash) const
Definition: quorums_dkgsessionhandler.cpp:72
Definition: bls_worker.h:21
std::vector< std::pair< NodeId, std::shared_ptr< Message > > > PopAndDeserializeMessages(size_t maxCount)
Definition: quorums_dkgsessionhandler.h:67
std::function< bool()> WhileWaitFunc
Definition: quorums_dkgsessionhandler.h:137
Double ended buffer combining vector and stream-like interfaces.
Definition: streams.h:103
Definition: deterministicmns.h:26
size_t maxMessagesPerNode
Definition: quorums_dkgsessionhandler.h:44
void StartThread()
Definition: quorums_dkgsessionhandler.cpp:143
void WaitForNextPhase(QuorumPhase curPhase, QuorumPhase nextPhase, const uint256 &expectedQuorumHash, const WhileWaitFunc &runWhileWaiting)
Definition: quorums_dkgsessionhandler.cpp:192
std::map< NodeId, size_t > messagesPerNode
Definition: quorums_dkgsessionhandler.h:46
CDKGPendingMessages pendingJustifications
Definition: quorums_dkgsessionhandler.h:118
void SleepBeforePhase(QuorumPhase curPhase, const uint256 &expectedQuorumHash, double randomSleepFactor, const WhileWaitFunc &runWhileWaiting)
Definition: quorums_dkgsessionhandler.cpp:254
std::pair< NodeId, std::shared_ptr< CDataStream > > BinaryMessage
Definition: quorums_dkgsessionhandler.h:39
void WaitForNewQuorum(const uint256 &oldQuorumHash)
Definition: quorums_dkgsessionhandler.cpp:234
bool InitNewQuorum(const CBlockIndex *pindexQuorum)
Definition: quorums_dkgsessionhandler.cpp:161
void PhaseHandlerThread()
Definition: quorums_dkgsessionhandler.cpp:593
void UpdatedBlockTip(const CBlockIndex *pindexNew)
Definition: quorums_dkgsessionhandler.cpp:107
Definition: params.h:65
std::list< BinaryMessage > pendingMessages
Definition: quorums_dkgsessionhandler.h:45
void HandleDKGRound()
Definition: quorums_dkgsessionhandler.cpp:509
std::shared_ptr< CDKGSession > curSession
Definition: quorums_dkgsessionhandler.h:113
CBLSWorker & blsWorker
Definition: quorums_dkgsessionhandler.h:106
std::thread phaseHandlerThread
Definition: quorums_dkgsessionhandler.h:114
The block chain is a tree shaped structure starting with the genesis block at the root...
Definition: chain.h:170
void HandlePhase(QuorumPhase curPhase, QuorumPhase nextPhase, const uint256 &expectedQuorumHash, double randomSleepFactor, const StartPhaseFunc &startPhaseFunc, const WhileWaitFunc &runWhileWaiting)
Definition: quorums_dkgsessionhandler.cpp:321
~CDKGSessionHandler()
Definition: quorums_dkgsessionhandler.cpp:103
std::list< BinaryMessage > PopPendingMessages(size_t maxCount)
Definition: quorums_dkgsessionhandler.cpp:59
std::atomic< bool > stopRequested
Definition: quorums_dkgsessionhandler.h:103
CDKGSessionHandler(const Consensus::LLMQParams &_params, CBLSWorker &blsWorker, CDKGSessionManager &_dkgManager)
Definition: quorums_dkgsessionhandler.cpp:88
Handles multiple sequential sessions of one specific LLMQ type.
Definition: quorums_dkgsessionhandler.h:96
CDKGSessionManager & dkgManager
Definition: quorums_dkgsessionhandler.h:107
CDKGPendingMessages pendingPrematureCommitments
Definition: quorums_dkgsessionhandler.h:119
std::pair< QuorumPhase, uint256 > GetPhaseAndQuorumHash() const
Definition: quorums_dkgsessionhandler.cpp:183
Definition: serialize.h:160
const Consensus::LLMQParams & params
Definition: quorums_dkgsessionhandler.h:105
Wrapped mutex: supports recursive locking, but no waiting TODO: We should move away from using the re...
Definition: sync.h:94
CDKGPendingMessages(size_t _maxMessagesPerNode, int _invType)
Definition: quorums_dkgsessionhandler.cpp:21