@@ -23,6 +23,7 @@ use crate::external_snark_worker::ExternalSnarkWorkerAction;
2323use crate :: ledger:: read:: LedgerReadAction ;
2424use crate :: ledger:: write:: LedgerWriteAction ;
2525use crate :: ledger:: LedgerAction ;
26+ use crate :: p2p:: callbacks:: P2pCallbacksAction ;
2627use crate :: p2p:: channels:: best_tip:: P2pChannelsBestTipAction ;
2728use crate :: p2p:: channels:: best_tip_effectful:: P2pChannelsBestTipEffectfulAction ;
2829use crate :: p2p:: channels:: rpc:: P2pChannelsRpcAction ;
@@ -147,6 +148,7 @@ pub enum ActionKind {
147148 ConsensusBlockSnarkVerifySuccess ,
148149 ConsensusDetectForkRange ,
149150 ConsensusLongRangeForkResolve ,
151+ ConsensusP2pBestTipUpdate ,
150152 ConsensusPrune ,
151153 ConsensusShortRangeForkResolve ,
152154 EventSourceNewEvent ,
@@ -174,6 +176,13 @@ pub enum ActionKind {
174176 LedgerWriteInit ,
175177 LedgerWritePending ,
176178 LedgerWriteSuccess ,
179+ P2pCallbacksP2pChannelsRpcReady ,
180+ P2pCallbacksP2pChannelsRpcRequestReceived ,
181+ P2pCallbacksP2pChannelsRpcResponseReceived ,
182+ P2pCallbacksP2pChannelsRpcTimeout ,
183+ P2pCallbacksP2pChannelsStreamingRpcReady ,
184+ P2pCallbacksP2pChannelsStreamingRpcResponseReceived ,
185+ P2pCallbacksP2pChannelsStreamingRpcTimeout ,
177186 P2pChannelsBestTipInit ,
178187 P2pChannelsBestTipPending ,
179188 P2pChannelsBestTipReady ,
@@ -427,6 +436,7 @@ pub enum ActionKind {
427436 RpcLedgerAccountsGetPending ,
428437 RpcLedgerAccountsGetSuccess ,
429438 RpcMessageProgressGet ,
439+ RpcP2pConnectionIncomingAnswerReady ,
430440 RpcP2pConnectionIncomingError ,
431441 RpcP2pConnectionIncomingInit ,
432442 RpcP2pConnectionIncomingPending ,
@@ -510,6 +520,7 @@ pub enum ActionKind {
510520 TransactionPoolVerifyError ,
511521 TransactionPoolEffectfulFetchAccounts ,
512522 TransitionFrontierGenesisInject ,
523+ TransitionFrontierRpcRespondBestTip ,
513524 TransitionFrontierSyncFailed ,
514525 TransitionFrontierSynced ,
515526 TransitionFrontierGenesisLedgerLoadInit ,
@@ -559,6 +570,7 @@ pub enum ActionKind {
559570 TransitionFrontierSyncLedgerSnarkedNumAccountsReceived ,
560571 TransitionFrontierSyncLedgerSnarkedNumAccountsRejected ,
561572 TransitionFrontierSyncLedgerSnarkedNumAccountsSuccess ,
573+ TransitionFrontierSyncLedgerSnarkedP2pDisconnection ,
562574 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressError ,
563575 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressInit ,
564576 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressPending ,
@@ -599,7 +611,7 @@ pub enum ActionKind {
599611}
600612
601613impl ActionKind {
602- pub const COUNT : u16 = 493 ;
614+ pub const COUNT : u16 = 504 ;
603615}
604616
605617impl std:: fmt:: Display for ActionKind {
@@ -614,6 +626,7 @@ impl ActionKindGet for Action {
614626 Self :: CheckTimeouts ( a) => a. kind ( ) ,
615627 Self :: EventSource ( a) => a. kind ( ) ,
616628 Self :: P2p ( a) => a. kind ( ) ,
629+ Self :: P2pCallbacks ( a) => a. kind ( ) ,
617630 Self :: Ledger ( a) => a. kind ( ) ,
618631 Self :: Snark ( a) => a. kind ( ) ,
619632 Self :: Consensus ( a) => a. kind ( ) ,
@@ -664,6 +677,30 @@ impl ActionKindGet for P2pAction {
664677 }
665678}
666679
680+ impl ActionKindGet for P2pCallbacksAction {
681+ fn kind ( & self ) -> ActionKind {
682+ match self {
683+ Self :: P2pChannelsRpcReady { .. } => ActionKind :: P2pCallbacksP2pChannelsRpcReady ,
684+ Self :: P2pChannelsRpcTimeout { .. } => ActionKind :: P2pCallbacksP2pChannelsRpcTimeout ,
685+ Self :: P2pChannelsRpcResponseReceived { .. } => {
686+ ActionKind :: P2pCallbacksP2pChannelsRpcResponseReceived
687+ }
688+ Self :: P2pChannelsRpcRequestReceived { .. } => {
689+ ActionKind :: P2pCallbacksP2pChannelsRpcRequestReceived
690+ }
691+ Self :: P2pChannelsStreamingRpcReady => {
692+ ActionKind :: P2pCallbacksP2pChannelsStreamingRpcReady
693+ }
694+ Self :: P2pChannelsStreamingRpcTimeout { .. } => {
695+ ActionKind :: P2pCallbacksP2pChannelsStreamingRpcTimeout
696+ }
697+ Self :: P2pChannelsStreamingRpcResponseReceived { .. } => {
698+ ActionKind :: P2pCallbacksP2pChannelsStreamingRpcResponseReceived
699+ }
700+ }
701+ }
702+ }
703+
667704impl ActionKindGet for LedgerAction {
668705 fn kind ( & self ) -> ActionKind {
669706 match self {
@@ -698,6 +735,7 @@ impl ActionKindGet for ConsensusAction {
698735 Self :: ShortRangeForkResolve { .. } => ActionKind :: ConsensusShortRangeForkResolve ,
699736 Self :: LongRangeForkResolve { .. } => ActionKind :: ConsensusLongRangeForkResolve ,
700737 Self :: BestTipUpdate { .. } => ActionKind :: ConsensusBestTipUpdate ,
738+ Self :: P2pBestTipUpdate { .. } => ActionKind :: ConsensusP2pBestTipUpdate ,
701739 Self :: Prune => ActionKind :: ConsensusPrune ,
702740 }
703741 }
@@ -712,6 +750,7 @@ impl ActionKindGet for TransitionFrontierAction {
712750 Self :: GenesisInject => ActionKind :: TransitionFrontierGenesisInject ,
713751 Self :: Synced { .. } => ActionKind :: TransitionFrontierSynced ,
714752 Self :: SyncFailed { .. } => ActionKind :: TransitionFrontierSyncFailed ,
753+ Self :: RpcRespondBestTip { .. } => ActionKind :: TransitionFrontierRpcRespondBestTip ,
715754 }
716755 }
717756}
@@ -857,6 +896,9 @@ impl ActionKindGet for RpcAction {
857896 Self :: P2pConnectionIncomingRespond { .. } => {
858897 ActionKind :: RpcP2pConnectionIncomingRespond
859898 }
899+ Self :: P2pConnectionIncomingAnswerReady { .. } => {
900+ ActionKind :: RpcP2pConnectionIncomingAnswerReady
901+ }
860902 Self :: P2pConnectionIncomingError { .. } => ActionKind :: RpcP2pConnectionIncomingError ,
861903 Self :: P2pConnectionIncomingSuccess { .. } => {
862904 ActionKind :: RpcP2pConnectionIncomingSuccess
@@ -1880,6 +1922,9 @@ impl ActionKindGet for TransitionFrontierSyncLedgerSnarkedAction {
18801922 ActionKind :: TransitionFrontierSyncLedgerSnarkedMerkleTreeSyncSuccess
18811923 }
18821924 Self :: Success => ActionKind :: TransitionFrontierSyncLedgerSnarkedSuccess ,
1925+ Self :: P2pDisconnection { .. } => {
1926+ ActionKind :: TransitionFrontierSyncLedgerSnarkedP2pDisconnection
1927+ }
18831928 }
18841929 }
18851930}
0 commit comments