1use num_enum::TryFromPrimitive;
15use serde::{Deserialize, Serialize};
16use strum_macros::VariantArray;
17
18use crate::{
19 block_producer::{vrf_evaluator::BlockProducerVrfEvaluatorAction, BlockProducerAction},
20 block_producer_effectful::{
21 vrf_evaluator_effectful::BlockProducerVrfEvaluatorEffectfulAction,
22 BlockProducerEffectfulAction,
23 },
24 event_source::EventSourceAction,
25 external_snark_worker::ExternalSnarkWorkerAction,
26 external_snark_worker_effectful::ExternalSnarkWorkerEffectfulAction,
27 ledger::{read::LedgerReadAction, write::LedgerWriteAction, LedgerAction},
28 ledger_effectful::LedgerEffectfulAction,
29 p2p::{
30 callbacks::P2pCallbacksAction,
31 channels::{
32 best_tip::P2pChannelsBestTipAction,
33 rpc::P2pChannelsRpcAction,
34 signaling::{
35 discovery::P2pChannelsSignalingDiscoveryAction,
36 exchange::P2pChannelsSignalingExchangeAction,
37 },
38 snark::P2pChannelsSnarkAction,
39 snark_job_commitment::P2pChannelsSnarkJobCommitmentAction,
40 streaming_rpc::P2pChannelsStreamingRpcAction,
41 transaction::P2pChannelsTransactionAction,
42 P2pChannelsAction, P2pChannelsEffectfulAction, P2pChannelsMessageReceivedAction,
43 },
44 connection::{
45 incoming::P2pConnectionIncomingAction,
46 incoming_effectful::P2pConnectionIncomingEffectfulAction,
47 outgoing::P2pConnectionOutgoingAction,
48 outgoing_effectful::P2pConnectionOutgoingEffectfulAction, P2pConnectionAction,
49 P2pConnectionEffectfulAction,
50 },
51 disconnection::P2pDisconnectionAction,
52 disconnection_effectful::P2pDisconnectionEffectfulAction,
53 identify::P2pIdentifyAction,
54 network::{
55 identify::{
56 stream::P2pNetworkIdentifyStreamAction,
57 stream_effectful::P2pNetworkIdentifyStreamEffectfulAction,
58 P2pNetworkIdentifyAction, P2pNetworkIdentifyEffectfulAction,
59 },
60 kad::{
61 bootstrap::P2pNetworkKadBootstrapAction,
62 kad_effectful::P2pNetworkKadEffectfulAction, request::P2pNetworkKadRequestAction,
63 stream::P2pNetworkKademliaStreamAction, P2pNetworkKadAction,
64 P2pNetworkKademliaAction,
65 },
66 noise::P2pNetworkNoiseAction,
67 pnet::P2pNetworkPnetAction,
68 pnet_effectful::P2pNetworkPnetEffectfulAction,
69 pubsub::{pubsub_effectful::P2pNetworkPubsubEffectfulAction, P2pNetworkPubsubAction},
70 rpc::P2pNetworkRpcAction,
71 scheduler::P2pNetworkSchedulerAction,
72 scheduler_effectful::P2pNetworkSchedulerEffectfulAction,
73 select::P2pNetworkSelectAction,
74 yamux::P2pNetworkYamuxAction,
75 P2pNetworkAction, P2pNetworkEffectfulAction,
76 },
77 peer::P2pPeerAction,
78 P2pAction, P2pEffectfulAction, P2pInitializeAction,
79 },
80 rpc::RpcAction,
81 rpc_effectful::RpcEffectfulAction,
82 snark::{
83 block_verify::SnarkBlockVerifyAction,
84 block_verify_effectful::SnarkBlockVerifyEffectfulAction,
85 user_command_verify::SnarkUserCommandVerifyAction,
86 user_command_verify_effectful::SnarkUserCommandVerifyEffectfulAction,
87 work_verify::SnarkWorkVerifyAction, work_verify_effectful::SnarkWorkVerifyEffectfulAction,
88 SnarkAction,
89 },
90 snark_pool::{candidate::SnarkPoolCandidateAction, SnarkPoolAction, SnarkPoolEffectfulAction},
91 transaction_pool::{
92 candidate::TransactionPoolCandidateAction, TransactionPoolAction,
93 TransactionPoolEffectfulAction,
94 },
95 transition_frontier::{
96 candidate::TransitionFrontierCandidateAction,
97 genesis::TransitionFrontierGenesisAction,
98 genesis_effectful::TransitionFrontierGenesisEffectfulAction,
99 sync::{
100 ledger::{
101 snarked::TransitionFrontierSyncLedgerSnarkedAction,
102 staged::TransitionFrontierSyncLedgerStagedAction,
103 TransitionFrontierSyncLedgerAction,
104 },
105 TransitionFrontierSyncAction,
106 },
107 TransitionFrontierAction,
108 },
109 watched_accounts::WatchedAccountsAction,
110 Action, ActionKindGet, CheckInvalidPeersAction, CheckTimeoutsAction,
111};
112
113#[derive(
115 Serialize,
116 Deserialize,
117 VariantArray,
118 TryFromPrimitive,
119 Debug,
120 Ord,
121 PartialOrd,
122 Eq,
123 PartialEq,
124 Clone,
125 Copy,
126)]
127#[repr(u16)]
128pub enum ActionKind {
129 None,
130 BlockProducerBestTipUpdate,
131 BlockProducerBlockInject,
132 BlockProducerBlockInjected,
133 BlockProducerBlockProduced,
134 BlockProducerBlockProveInit,
135 BlockProducerBlockProvePending,
136 BlockProducerBlockProveSuccess,
137 BlockProducerBlockUnprovenBuild,
138 BlockProducerStagedLedgerDiffCreateInit,
139 BlockProducerStagedLedgerDiffCreatePending,
140 BlockProducerStagedLedgerDiffCreateSuccess,
141 BlockProducerWonSlot,
142 BlockProducerWonSlotDiscard,
143 BlockProducerWonSlotProduceInit,
144 BlockProducerWonSlotSearch,
145 BlockProducerWonSlotTransactionsGet,
146 BlockProducerWonSlotTransactionsSuccess,
147 BlockProducerWonSlotWait,
148 BlockProducerEffectfulBlockProduced,
149 BlockProducerEffectfulBlockProveInit,
150 BlockProducerEffectfulBlockProveSuccess,
151 BlockProducerEffectfulBlockUnprovenBuild,
152 BlockProducerEffectfulStagedLedgerDiffCreateInit,
153 BlockProducerEffectfulStagedLedgerDiffCreateSuccess,
154 BlockProducerEffectfulWonSlot,
155 BlockProducerEffectfulWonSlotDiscard,
156 BlockProducerVrfEvaluatorBeginDelegatorTableConstruction,
157 BlockProducerVrfEvaluatorBeginEpochEvaluation,
158 BlockProducerVrfEvaluatorCheckEpochBounds,
159 BlockProducerVrfEvaluatorCheckEpochEvaluability,
160 BlockProducerVrfEvaluatorCleanupOldSlots,
161 BlockProducerVrfEvaluatorContinueEpochEvaluation,
162 BlockProducerVrfEvaluatorEvaluateSlot,
163 BlockProducerVrfEvaluatorFinalizeDelegatorTableConstruction,
164 BlockProducerVrfEvaluatorFinalizeEvaluatorInitialization,
165 BlockProducerVrfEvaluatorFinishEpochEvaluation,
166 BlockProducerVrfEvaluatorInitializeEpochEvaluation,
167 BlockProducerVrfEvaluatorInitializeEvaluator,
168 BlockProducerVrfEvaluatorInterruptEpochEvaluation,
169 BlockProducerVrfEvaluatorProcessSlotEvaluationSuccess,
170 BlockProducerVrfEvaluatorSelectInitialSlot,
171 BlockProducerVrfEvaluatorWaitForNextEvaluation,
172 BlockProducerVrfEvaluatorEffectfulEvaluateSlot,
173 BlockProducerVrfEvaluatorEffectfulInitializeStats,
174 BlockProducerVrfEvaluatorEffectfulSlotEvaluated,
175 CheckInvalidPeers,
176 CheckTimeouts,
177 EventSourceNewEvent,
178 EventSourceProcessEvents,
179 EventSourceWaitForEvents,
180 EventSourceWaitTimeout,
181 ExternalSnarkWorkerCancelWork,
182 ExternalSnarkWorkerError,
183 ExternalSnarkWorkerKill,
184 ExternalSnarkWorkerKilled,
185 ExternalSnarkWorkerPruneWork,
186 ExternalSnarkWorkerStart,
187 ExternalSnarkWorkerStartTimeout,
188 ExternalSnarkWorkerStarted,
189 ExternalSnarkWorkerSubmitWork,
190 ExternalSnarkWorkerWorkCancelled,
191 ExternalSnarkWorkerWorkError,
192 ExternalSnarkWorkerWorkResult,
193 ExternalSnarkWorkerWorkTimeout,
194 ExternalSnarkWorkerEffectfulCancelWork,
195 ExternalSnarkWorkerEffectfulKill,
196 ExternalSnarkWorkerEffectfulStart,
197 ExternalSnarkWorkerEffectfulSubmitWork,
198 LedgerEffectfulReadInit,
199 LedgerEffectfulWriteInit,
200 LedgerReadFindTodos,
201 LedgerReadInit,
202 LedgerReadPending,
203 LedgerReadPrune,
204 LedgerReadSuccess,
205 LedgerWriteInit,
206 LedgerWritePending,
207 LedgerWriteSuccess,
208 P2pCallbacksP2pChannelsRpcReady,
209 P2pCallbacksP2pChannelsRpcRequestReceived,
210 P2pCallbacksP2pChannelsRpcResponseReceived,
211 P2pCallbacksP2pChannelsRpcTimeout,
212 P2pCallbacksP2pChannelsStreamingRpcReady,
213 P2pCallbacksP2pChannelsStreamingRpcResponseReceived,
214 P2pCallbacksP2pChannelsStreamingRpcTimeout,
215 P2pCallbacksP2pDisconnection,
216 P2pCallbacksP2pPubsubValidateMessage,
217 P2pCallbacksRpcRespondBestTip,
218 P2pChannelsBestTipInit,
219 P2pChannelsBestTipPending,
220 P2pChannelsBestTipReady,
221 P2pChannelsBestTipReceived,
222 P2pChannelsBestTipRequestReceived,
223 P2pChannelsBestTipRequestSend,
224 P2pChannelsBestTipResponseSend,
225 P2pChannelsEffectfulInitChannel,
226 P2pChannelsEffectfulMessageSend,
227 P2pChannelsEffectfulSignalingDiscoveryAnswerDecrypt,
228 P2pChannelsEffectfulSignalingDiscoveryOfferEncryptAndSend,
229 P2pChannelsEffectfulSignalingExchangeAnswerEncryptAndSend,
230 P2pChannelsEffectfulSignalingExchangeOfferDecrypt,
231 P2pChannelsMessageReceived,
232 P2pChannelsRpcInit,
233 P2pChannelsRpcPending,
234 P2pChannelsRpcReady,
235 P2pChannelsRpcRequestReceived,
236 P2pChannelsRpcRequestSend,
237 P2pChannelsRpcResponsePending,
238 P2pChannelsRpcResponseReceived,
239 P2pChannelsRpcResponseSend,
240 P2pChannelsRpcTimeout,
241 P2pChannelsSignalingDiscoveryAnswerDecrypted,
242 P2pChannelsSignalingDiscoveryAnswerReceived,
243 P2pChannelsSignalingDiscoveryAnswerSend,
244 P2pChannelsSignalingDiscoveryDiscoveredAccept,
245 P2pChannelsSignalingDiscoveryDiscoveredAcceptReceived,
246 P2pChannelsSignalingDiscoveryDiscoveredReceived,
247 P2pChannelsSignalingDiscoveryDiscoveredReject,
248 P2pChannelsSignalingDiscoveryDiscoveredRejectReceived,
249 P2pChannelsSignalingDiscoveryDiscoveredSend,
250 P2pChannelsSignalingDiscoveryDiscoveryRequestReceived,
251 P2pChannelsSignalingDiscoveryDiscoveryRequestSend,
252 P2pChannelsSignalingDiscoveryInit,
253 P2pChannelsSignalingDiscoveryPending,
254 P2pChannelsSignalingDiscoveryReady,
255 P2pChannelsSignalingDiscoveryRequestReceived,
256 P2pChannelsSignalingDiscoveryRequestSend,
257 P2pChannelsSignalingExchangeAnswerReceived,
258 P2pChannelsSignalingExchangeAnswerSend,
259 P2pChannelsSignalingExchangeInit,
260 P2pChannelsSignalingExchangeOfferDecryptError,
261 P2pChannelsSignalingExchangeOfferDecryptSuccess,
262 P2pChannelsSignalingExchangeOfferReceived,
263 P2pChannelsSignalingExchangeOfferSend,
264 P2pChannelsSignalingExchangePending,
265 P2pChannelsSignalingExchangeReady,
266 P2pChannelsSignalingExchangeRequestReceived,
267 P2pChannelsSignalingExchangeRequestSend,
268 P2pChannelsSnarkInit,
269 P2pChannelsSnarkLibp2pBroadcast,
270 P2pChannelsSnarkLibp2pReceived,
271 P2pChannelsSnarkPending,
272 P2pChannelsSnarkPromiseReceived,
273 P2pChannelsSnarkReady,
274 P2pChannelsSnarkReceived,
275 P2pChannelsSnarkRequestReceived,
276 P2pChannelsSnarkRequestSend,
277 P2pChannelsSnarkResponseSend,
278 P2pChannelsSnarkJobCommitmentInit,
279 P2pChannelsSnarkJobCommitmentPending,
280 P2pChannelsSnarkJobCommitmentPromiseReceived,
281 P2pChannelsSnarkJobCommitmentReady,
282 P2pChannelsSnarkJobCommitmentReceived,
283 P2pChannelsSnarkJobCommitmentRequestReceived,
284 P2pChannelsSnarkJobCommitmentRequestSend,
285 P2pChannelsSnarkJobCommitmentResponseSend,
286 P2pChannelsStreamingRpcInit,
287 P2pChannelsStreamingRpcPending,
288 P2pChannelsStreamingRpcReady,
289 P2pChannelsStreamingRpcRequestReceived,
290 P2pChannelsStreamingRpcRequestSend,
291 P2pChannelsStreamingRpcResponseNextPartGet,
292 P2pChannelsStreamingRpcResponsePartNextSend,
293 P2pChannelsStreamingRpcResponsePartReceived,
294 P2pChannelsStreamingRpcResponsePartSend,
295 P2pChannelsStreamingRpcResponsePending,
296 P2pChannelsStreamingRpcResponseReceived,
297 P2pChannelsStreamingRpcResponseSendInit,
298 P2pChannelsStreamingRpcResponseSent,
299 P2pChannelsStreamingRpcTimeout,
300 P2pChannelsTransactionInit,
301 P2pChannelsTransactionLibp2pBroadcast,
302 P2pChannelsTransactionLibp2pReceived,
303 P2pChannelsTransactionPending,
304 P2pChannelsTransactionPromiseReceived,
305 P2pChannelsTransactionReady,
306 P2pChannelsTransactionReceived,
307 P2pChannelsTransactionRequestReceived,
308 P2pChannelsTransactionRequestSend,
309 P2pChannelsTransactionResponseSend,
310 P2pConnectionIncomingAnswerReady,
311 P2pConnectionIncomingAnswerSdpCreateError,
312 P2pConnectionIncomingAnswerSdpCreatePending,
313 P2pConnectionIncomingAnswerSdpCreateSuccess,
314 P2pConnectionIncomingAnswerSendSuccess,
315 P2pConnectionIncomingError,
316 P2pConnectionIncomingFinalizeError,
317 P2pConnectionIncomingFinalizePending,
318 P2pConnectionIncomingFinalizePendingLibp2p,
319 P2pConnectionIncomingFinalizeSuccess,
320 P2pConnectionIncomingInit,
321 P2pConnectionIncomingLibp2pReceived,
322 P2pConnectionIncomingSuccess,
323 P2pConnectionIncomingTimeout,
324 P2pConnectionIncomingEffectfulConnectionAuthorizationDecryptAndCheck,
325 P2pConnectionIncomingEffectfulConnectionAuthorizationEncryptAndSend,
326 P2pConnectionIncomingEffectfulInit,
327 P2pConnectionOutgoingAnswerRecvError,
328 P2pConnectionOutgoingAnswerRecvPending,
329 P2pConnectionOutgoingAnswerRecvSuccess,
330 P2pConnectionOutgoingError,
331 P2pConnectionOutgoingFinalizeError,
332 P2pConnectionOutgoingFinalizePending,
333 P2pConnectionOutgoingFinalizeSuccess,
334 P2pConnectionOutgoingInit,
335 P2pConnectionOutgoingOfferReady,
336 P2pConnectionOutgoingOfferSdpCreateError,
337 P2pConnectionOutgoingOfferSdpCreatePending,
338 P2pConnectionOutgoingOfferSdpCreateSuccess,
339 P2pConnectionOutgoingOfferSendSuccess,
340 P2pConnectionOutgoingRandomInit,
341 P2pConnectionOutgoingReconnect,
342 P2pConnectionOutgoingSuccess,
343 P2pConnectionOutgoingTimeout,
344 P2pConnectionOutgoingEffectfulAnswerSet,
345 P2pConnectionOutgoingEffectfulConnectionAuthorizationDecryptAndCheck,
346 P2pConnectionOutgoingEffectfulConnectionAuthorizationEncryptAndSend,
347 P2pConnectionOutgoingEffectfulInit,
348 P2pConnectionOutgoingEffectfulOfferSend,
349 P2pConnectionOutgoingEffectfulRandomInit,
350 P2pDisconnectionFailedCleanup,
351 P2pDisconnectionFinish,
352 P2pDisconnectionInit,
353 P2pDisconnectionPeerClosed,
354 P2pDisconnectionRandomTry,
355 P2pDisconnectionEffectfulInit,
356 P2pEffectfulInitialize,
357 P2pIdentifyNewRequest,
358 P2pIdentifyUpdatePeerInformation,
359 P2pInitializeInitialize,
360 P2pNetworkIdentifyStreamClose,
361 P2pNetworkIdentifyStreamIncomingData,
362 P2pNetworkIdentifyStreamNew,
363 P2pNetworkIdentifyStreamPrune,
364 P2pNetworkIdentifyStreamRemoteClose,
365 P2pNetworkIdentifyStreamSendIdentify,
366 P2pNetworkIdentifyStreamEffectfulGetListenAddresses,
367 P2pNetworkKadBootstrapAppendRequest,
368 P2pNetworkKadBootstrapCreateRequests,
369 P2pNetworkKadBootstrapFinalizeRequests,
370 P2pNetworkKadBootstrapRequestDone,
371 P2pNetworkKadBootstrapRequestError,
372 P2pNetworkKadEffectfulDiscovered,
373 P2pNetworkKadEffectfulMakeRequest,
374 P2pNetworkKadRequestError,
375 P2pNetworkKadRequestMuxReady,
376 P2pNetworkKadRequestNew,
377 P2pNetworkKadRequestPeerIsConnecting,
378 P2pNetworkKadRequestPrune,
379 P2pNetworkKadRequestReplyReceived,
380 P2pNetworkKadRequestRequestSent,
381 P2pNetworkKadRequestStreamIsCreating,
382 P2pNetworkKadRequestStreamReady,
383 P2pNetworkKademliaAnswerFindNodeRequest,
384 P2pNetworkKademliaBootstrapFinished,
385 P2pNetworkKademliaStartBootstrap,
386 P2pNetworkKademliaUpdateFindNodeRequest,
387 P2pNetworkKademliaUpdateRoutingTable,
388 P2pNetworkKademliaStreamClose,
389 P2pNetworkKademliaStreamIncomingData,
390 P2pNetworkKademliaStreamNew,
391 P2pNetworkKademliaStreamOutgoingDataReady,
392 P2pNetworkKademliaStreamPrune,
393 P2pNetworkKademliaStreamRemoteClose,
394 P2pNetworkKademliaStreamSendRequest,
395 P2pNetworkKademliaStreamSendResponse,
396 P2pNetworkKademliaStreamWaitIncoming,
397 P2pNetworkKademliaStreamWaitOutgoing,
398 P2pNetworkNoiseDecryptedData,
399 P2pNetworkNoiseHandshakeDone,
400 P2pNetworkNoiseIncomingChunk,
401 P2pNetworkNoiseIncomingData,
402 P2pNetworkNoiseInit,
403 P2pNetworkNoiseOutgoingChunk,
404 P2pNetworkNoiseOutgoingChunkSelectMux,
405 P2pNetworkNoiseOutgoingData,
406 P2pNetworkNoiseOutgoingDataSelectMux,
407 P2pNetworkPnetIncomingData,
408 P2pNetworkPnetOutgoingData,
409 P2pNetworkPnetSetupNonce,
410 P2pNetworkPnetTimeout,
411 P2pNetworkPnetEffectfulOutgoingData,
412 P2pNetworkPnetEffectfulSetupNonce,
413 P2pNetworkPubsubBroadcast,
414 P2pNetworkPubsubBroadcastSigned,
415 P2pNetworkPubsubBroadcastValidatedMessage,
416 P2pNetworkPubsubGraft,
417 P2pNetworkPubsubHandleIncomingMessage,
418 P2pNetworkPubsubIgnoreMessage,
419 P2pNetworkPubsubIncomingData,
420 P2pNetworkPubsubIncomingMessage,
421 P2pNetworkPubsubIncomingMessageCleanup,
422 P2pNetworkPubsubNewStream,
423 P2pNetworkPubsubOutgoingData,
424 P2pNetworkPubsubOutgoingMessage,
425 P2pNetworkPubsubOutgoingMessageClear,
426 P2pNetworkPubsubOutgoingMessageError,
427 P2pNetworkPubsubPrune,
428 P2pNetworkPubsubPruneMessages,
429 P2pNetworkPubsubRejectMessage,
430 P2pNetworkPubsubSign,
431 P2pNetworkPubsubSignError,
432 P2pNetworkPubsubValidateIncomingMessage,
433 P2pNetworkPubsubValidateIncomingMessages,
434 P2pNetworkPubsubWebRtcRebroadcast,
435 P2pNetworkPubsubEffectfulSign,
436 P2pNetworkPubsubEffectfulValidateIncomingMessages,
437 P2pNetworkRpcHeartbeatSend,
438 P2pNetworkRpcIncomingData,
439 P2pNetworkRpcIncomingMessage,
440 P2pNetworkRpcInit,
441 P2pNetworkRpcOutgoingData,
442 P2pNetworkRpcOutgoingQuery,
443 P2pNetworkRpcOutgoingResponse,
444 P2pNetworkRpcPrunePending,
445 P2pNetworkSchedulerDisconnect,
446 P2pNetworkSchedulerDisconnected,
447 P2pNetworkSchedulerError,
448 P2pNetworkSchedulerIncomingConnectionIsReady,
449 P2pNetworkSchedulerIncomingDataDidReceive,
450 P2pNetworkSchedulerIncomingDataIsReady,
451 P2pNetworkSchedulerIncomingDidAccept,
452 P2pNetworkSchedulerInterfaceDetected,
453 P2pNetworkSchedulerInterfaceExpired,
454 P2pNetworkSchedulerListenerError,
455 P2pNetworkSchedulerListenerReady,
456 P2pNetworkSchedulerOutgoingConnect,
457 P2pNetworkSchedulerOutgoingDidConnect,
458 P2pNetworkSchedulerPrune,
459 P2pNetworkSchedulerPruneStream,
460 P2pNetworkSchedulerSelectDone,
461 P2pNetworkSchedulerSelectError,
462 P2pNetworkSchedulerYamuxDidInit,
463 P2pNetworkSchedulerEffectfulDisconnect,
464 P2pNetworkSchedulerEffectfulIncomingConnectionIsReady,
465 P2pNetworkSchedulerEffectfulIncomingDataIsReady,
466 P2pNetworkSchedulerEffectfulIncomingDidAccept,
467 P2pNetworkSchedulerEffectfulInterfaceDetected,
468 P2pNetworkSchedulerEffectfulNoiseSelectDone,
469 P2pNetworkSchedulerEffectfulOutgoingConnect,
470 P2pNetworkSchedulerEffectfulOutgoingDidConnect,
471 P2pNetworkSelectIncomingData,
472 P2pNetworkSelectIncomingDataAuth,
473 P2pNetworkSelectIncomingDataMux,
474 P2pNetworkSelectIncomingPayload,
475 P2pNetworkSelectIncomingPayloadAuth,
476 P2pNetworkSelectIncomingPayloadMux,
477 P2pNetworkSelectIncomingToken,
478 P2pNetworkSelectInit,
479 P2pNetworkSelectOutgoingTokens,
480 P2pNetworkSelectTimeout,
481 P2pNetworkYamuxIncomingData,
482 P2pNetworkYamuxIncomingFrame,
483 P2pNetworkYamuxOpenStream,
484 P2pNetworkYamuxOutgoingData,
485 P2pNetworkYamuxOutgoingFrame,
486 P2pNetworkYamuxPingStream,
487 P2pPeerBestTipUpdate,
488 P2pPeerDiscovered,
489 P2pPeerReady,
490 P2pPeerRemove,
491 RpcActionStatsGet,
492 RpcBestChain,
493 RpcBlockGet,
494 RpcBlockProducerStatsGet,
495 RpcConsensusConstantsGet,
496 RpcConsensusTimeGet,
497 RpcDiscoveryBoostrapStats,
498 RpcDiscoveryRoutingTable,
499 RpcFinish,
500 RpcGenesisBlock,
501 RpcGlobalStateGet,
502 RpcHealthCheck,
503 RpcHeartbeatGet,
504 RpcLedgerAccountDelegatorsGetInit,
505 RpcLedgerAccountDelegatorsGetPending,
506 RpcLedgerAccountDelegatorsGetSuccess,
507 RpcLedgerAccountsGetInit,
508 RpcLedgerAccountsGetPending,
509 RpcLedgerAccountsGetSuccess,
510 RpcLedgerStatusGetInit,
511 RpcLedgerStatusGetPending,
512 RpcLedgerStatusGetSuccess,
513 RpcMessageProgressGet,
514 RpcP2pConnectionIncomingAnswerReady,
515 RpcP2pConnectionIncomingError,
516 RpcP2pConnectionIncomingInit,
517 RpcP2pConnectionIncomingPending,
518 RpcP2pConnectionIncomingRespond,
519 RpcP2pConnectionIncomingSuccess,
520 RpcP2pConnectionOutgoingError,
521 RpcP2pConnectionOutgoingInit,
522 RpcP2pConnectionOutgoingPending,
523 RpcP2pConnectionOutgoingSuccess,
524 RpcPeersGet,
525 RpcPooledUserCommands,
526 RpcPooledZkappCommands,
527 RpcReadinessCheck,
528 RpcScanStateSummaryGetInit,
529 RpcScanStateSummaryGetPending,
530 RpcScanStateSummaryGetSuccess,
531 RpcScanStateSummaryLedgerGetInit,
532 RpcSnarkPoolAvailableJobsGet,
533 RpcSnarkPoolCompletedJobsGet,
534 RpcSnarkPoolJobGet,
535 RpcSnarkPoolPendingJobsGet,
536 RpcSnarkerConfigGet,
537 RpcSnarkerJobCommit,
538 RpcSnarkerJobSpec,
539 RpcSnarkerWorkersGet,
540 RpcStatusGet,
541 RpcSyncStatsGet,
542 RpcTransactionInjectFailure,
543 RpcTransactionInjectInit,
544 RpcTransactionInjectPending,
545 RpcTransactionInjectRejected,
546 RpcTransactionInjectSuccess,
547 RpcTransactionPool,
548 RpcTransactionStatusGet,
549 RpcTransitionFrontierUserCommandsGet,
550 RpcEffectfulActionStatsGet,
551 RpcEffectfulBestChain,
552 RpcEffectfulBlockGet,
553 RpcEffectfulBlockProducerStatsGet,
554 RpcEffectfulConsensusConstantsGet,
555 RpcEffectfulConsensusTimeGet,
556 RpcEffectfulDiscoveryBoostrapStats,
557 RpcEffectfulDiscoveryRoutingTable,
558 RpcEffectfulGenesisBlock,
559 RpcEffectfulGlobalStateGet,
560 RpcEffectfulHealthCheck,
561 RpcEffectfulHeartbeatGet,
562 RpcEffectfulLedgerAccountDelegatorsGetSuccess,
563 RpcEffectfulLedgerAccountsGetSuccess,
564 RpcEffectfulLedgerStatusGetSuccess,
565 RpcEffectfulMessageProgressGet,
566 RpcEffectfulP2pConnectionIncomingError,
567 RpcEffectfulP2pConnectionIncomingRespond,
568 RpcEffectfulP2pConnectionIncomingSuccess,
569 RpcEffectfulP2pConnectionOutgoingError,
570 RpcEffectfulP2pConnectionOutgoingSuccess,
571 RpcEffectfulPeersGet,
572 RpcEffectfulPooledUserCommands,
573 RpcEffectfulPooledZkappCommands,
574 RpcEffectfulReadinessCheck,
575 RpcEffectfulScanStateSummaryGetSuccess,
576 RpcEffectfulSnarkPoolAvailableJobsGet,
577 RpcEffectfulSnarkPoolCompletedJobsGet,
578 RpcEffectfulSnarkPoolJobGet,
579 RpcEffectfulSnarkPoolPendingJobsGet,
580 RpcEffectfulSnarkerConfigGet,
581 RpcEffectfulSnarkerJobCommit,
582 RpcEffectfulSnarkerJobSpec,
583 RpcEffectfulSnarkerWorkersGet,
584 RpcEffectfulStatusGet,
585 RpcEffectfulSyncStatsGet,
586 RpcEffectfulTransactionInjectFailure,
587 RpcEffectfulTransactionInjectRejected,
588 RpcEffectfulTransactionInjectSuccess,
589 RpcEffectfulTransactionPool,
590 RpcEffectfulTransactionStatusGet,
591 RpcEffectfulTransitionFrontierUserCommandsGet,
592 SnarkBlockVerifyError,
593 SnarkBlockVerifyFinish,
594 SnarkBlockVerifyInit,
595 SnarkBlockVerifyPending,
596 SnarkBlockVerifySuccess,
597 SnarkBlockVerifyEffectfulInit,
598 SnarkPoolAutoCreateCommitment,
599 SnarkPoolCheckTimeouts,
600 SnarkPoolCommitmentAdd,
601 SnarkPoolCommitmentCreate,
602 SnarkPoolCommitmentCreateMany,
603 SnarkPoolJobCommitmentTimeout,
604 SnarkPoolJobsUpdate,
605 SnarkPoolP2pSend,
606 SnarkPoolP2pSendAll,
607 SnarkPoolWorkAdd,
608 SnarkPoolCandidateInfoReceived,
609 SnarkPoolCandidatePeerPrune,
610 SnarkPoolCandidateWorkFetchAll,
611 SnarkPoolCandidateWorkFetchError,
612 SnarkPoolCandidateWorkFetchInit,
613 SnarkPoolCandidateWorkFetchPending,
614 SnarkPoolCandidateWorkFetchSuccess,
615 SnarkPoolCandidateWorkVerifyError,
616 SnarkPoolCandidateWorkVerifyNext,
617 SnarkPoolCandidateWorkVerifyPending,
618 SnarkPoolCandidateWorkVerifySuccess,
619 SnarkPoolEffectfulSnarkPoolJobsRandomChoose,
620 SnarkUserCommandVerifyError,
621 SnarkUserCommandVerifyFinish,
622 SnarkUserCommandVerifyInit,
623 SnarkUserCommandVerifyPending,
624 SnarkUserCommandVerifySuccess,
625 SnarkUserCommandVerifyEffectfulInit,
626 SnarkWorkVerifyError,
627 SnarkWorkVerifyFinish,
628 SnarkWorkVerifyInit,
629 SnarkWorkVerifyPending,
630 SnarkWorkVerifySuccess,
631 SnarkWorkVerifyEffectfulInit,
632 TransactionPoolApplyTransitionFrontierDiff,
633 TransactionPoolApplyTransitionFrontierDiffWithAccounts,
634 TransactionPoolApplyVerifiedDiff,
635 TransactionPoolApplyVerifiedDiffWithAccounts,
636 TransactionPoolBestTipChanged,
637 TransactionPoolBestTipChangedWithAccounts,
638 TransactionPoolCollectTransactionsByFee,
639 TransactionPoolP2pSend,
640 TransactionPoolP2pSendAll,
641 TransactionPoolRebroadcast,
642 TransactionPoolStartVerify,
643 TransactionPoolStartVerifyWithAccounts,
644 TransactionPoolVerifyError,
645 TransactionPoolVerifySuccess,
646 TransactionPoolCandidateFetchAll,
647 TransactionPoolCandidateFetchError,
648 TransactionPoolCandidateFetchInit,
649 TransactionPoolCandidateFetchPending,
650 TransactionPoolCandidateFetchSuccess,
651 TransactionPoolCandidateInfoReceived,
652 TransactionPoolCandidateLibp2pTransactionsReceived,
653 TransactionPoolCandidatePeerPrune,
654 TransactionPoolCandidateVerifyError,
655 TransactionPoolCandidateVerifyNext,
656 TransactionPoolCandidateVerifyPending,
657 TransactionPoolCandidateVerifySuccess,
658 TransactionPoolEffectfulFetchAccounts,
659 TransitionFrontierGenesisInject,
660 TransitionFrontierGenesisProvenInject,
661 TransitionFrontierSyncFailed,
662 TransitionFrontierSynced,
663 TransitionFrontierCandidateBlockChainProofUpdate,
664 TransitionFrontierCandidateBlockPrevalidateError,
665 TransitionFrontierCandidateBlockPrevalidateSuccess,
666 TransitionFrontierCandidateBlockReceived,
667 TransitionFrontierCandidateBlockSnarkVerifyError,
668 TransitionFrontierCandidateBlockSnarkVerifyPending,
669 TransitionFrontierCandidateBlockSnarkVerifySuccess,
670 TransitionFrontierCandidateP2pBestTipUpdate,
671 TransitionFrontierCandidatePrune,
672 TransitionFrontierCandidateTransitionFrontierSyncTargetUpdate,
673 TransitionFrontierGenesisLedgerLoadInit,
674 TransitionFrontierGenesisLedgerLoadPending,
675 TransitionFrontierGenesisLedgerLoadSuccess,
676 TransitionFrontierGenesisProduce,
677 TransitionFrontierGenesisProveInit,
678 TransitionFrontierGenesisProvePending,
679 TransitionFrontierGenesisProveSuccess,
680 TransitionFrontierGenesisEffectfulLedgerLoadInit,
681 TransitionFrontierGenesisEffectfulProveInit,
682 TransitionFrontierSyncBestTipUpdate,
683 TransitionFrontierSyncBlocksFetchSuccess,
684 TransitionFrontierSyncBlocksNextApplyError,
685 TransitionFrontierSyncBlocksNextApplyInit,
686 TransitionFrontierSyncBlocksNextApplyPending,
687 TransitionFrontierSyncBlocksNextApplySuccess,
688 TransitionFrontierSyncBlocksPeerQueryError,
689 TransitionFrontierSyncBlocksPeerQueryInit,
690 TransitionFrontierSyncBlocksPeerQueryPending,
691 TransitionFrontierSyncBlocksPeerQueryRetry,
692 TransitionFrontierSyncBlocksPeerQuerySuccess,
693 TransitionFrontierSyncBlocksPeersQuery,
694 TransitionFrontierSyncBlocksPending,
695 TransitionFrontierSyncBlocksSendToArchive,
696 TransitionFrontierSyncBlocksSuccess,
697 TransitionFrontierSyncCommitInit,
698 TransitionFrontierSyncCommitPending,
699 TransitionFrontierSyncCommitSuccess,
700 TransitionFrontierSyncInit,
701 TransitionFrontierSyncLedgerNextEpochPending,
702 TransitionFrontierSyncLedgerNextEpochSuccess,
703 TransitionFrontierSyncLedgerRootPending,
704 TransitionFrontierSyncLedgerRootSuccess,
705 TransitionFrontierSyncLedgerStakingPending,
706 TransitionFrontierSyncLedgerStakingSuccess,
707 TransitionFrontierSyncLedgerInit,
708 TransitionFrontierSyncLedgerSuccess,
709 TransitionFrontierSyncLedgerSnarkedChildAccountsAccepted,
710 TransitionFrontierSyncLedgerSnarkedChildAccountsReceived,
711 TransitionFrontierSyncLedgerSnarkedChildAccountsRejected,
712 TransitionFrontierSyncLedgerSnarkedChildHashesAccepted,
713 TransitionFrontierSyncLedgerSnarkedChildHashesReceived,
714 TransitionFrontierSyncLedgerSnarkedChildHashesRejected,
715 TransitionFrontierSyncLedgerSnarkedMerkleTreeSyncPending,
716 TransitionFrontierSyncLedgerSnarkedMerkleTreeSyncSuccess,
717 TransitionFrontierSyncLedgerSnarkedNumAccountsAccepted,
718 TransitionFrontierSyncLedgerSnarkedNumAccountsReceived,
719 TransitionFrontierSyncLedgerSnarkedNumAccountsRejected,
720 TransitionFrontierSyncLedgerSnarkedNumAccountsSuccess,
721 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressError,
722 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressInit,
723 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressPending,
724 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressRetry,
725 TransitionFrontierSyncLedgerSnarkedPeerQueryAddressSuccess,
726 TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsError,
727 TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsInit,
728 TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsPending,
729 TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsRetry,
730 TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsSuccess,
731 TransitionFrontierSyncLedgerSnarkedPeersQuery,
732 TransitionFrontierSyncLedgerSnarkedPending,
733 TransitionFrontierSyncLedgerSnarkedSuccess,
734 TransitionFrontierSyncLedgerStagedPartsFetchPending,
735 TransitionFrontierSyncLedgerStagedPartsFetchSuccess,
736 TransitionFrontierSyncLedgerStagedPartsPeerFetchError,
737 TransitionFrontierSyncLedgerStagedPartsPeerFetchInit,
738 TransitionFrontierSyncLedgerStagedPartsPeerFetchPending,
739 TransitionFrontierSyncLedgerStagedPartsPeerFetchSuccess,
740 TransitionFrontierSyncLedgerStagedPartsPeerInvalid,
741 TransitionFrontierSyncLedgerStagedPartsPeerValid,
742 TransitionFrontierSyncLedgerStagedReconstructEmpty,
743 TransitionFrontierSyncLedgerStagedReconstructError,
744 TransitionFrontierSyncLedgerStagedReconstructInit,
745 TransitionFrontierSyncLedgerStagedReconstructPending,
746 TransitionFrontierSyncLedgerStagedReconstructSuccess,
747 TransitionFrontierSyncLedgerStagedSuccess,
748 WatchedAccountsAdd,
749 WatchedAccountsBlockLedgerQueryInit,
750 WatchedAccountsBlockLedgerQueryPending,
751 WatchedAccountsBlockLedgerQuerySuccess,
752 WatchedAccountsLedgerInitialStateGetError,
753 WatchedAccountsLedgerInitialStateGetInit,
754 WatchedAccountsLedgerInitialStateGetPending,
755 WatchedAccountsLedgerInitialStateGetRetry,
756 WatchedAccountsLedgerInitialStateGetSuccess,
757 WatchedAccountsTransactionsIncludedInBlock,
758}
759
760impl ActionKind {
761 pub const COUNT: u16 = 629;
762}
763
764impl std::fmt::Display for ActionKind {
765 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
766 write!(f, "{self:?}")
767 }
768}
769
770impl ActionKindGet for Action {
771 fn kind(&self) -> ActionKind {
772 match self {
773 Self::CheckTimeouts(a) => a.kind(),
774 Self::CheckInvalidPeersAction(a) => a.kind(),
775 Self::EventSource(a) => a.kind(),
776 Self::P2p(a) => a.kind(),
777 Self::P2pEffectful(a) => a.kind(),
778 Self::P2pCallbacks(a) => a.kind(),
779 Self::Ledger(a) => a.kind(),
780 Self::LedgerEffects(a) => a.kind(),
781 Self::Snark(a) => a.kind(),
782 Self::TransitionFrontier(a) => a.kind(),
783 Self::SnarkPool(a) => a.kind(),
784 Self::SnarkPoolEffect(a) => a.kind(),
785 Self::TransactionPool(a) => a.kind(),
786 Self::TransactionPoolEffect(a) => a.kind(),
787 Self::ExternalSnarkWorker(a) => a.kind(),
788 Self::ExternalSnarkWorkerEffects(a) => a.kind(),
789 Self::BlockProducer(a) => a.kind(),
790 Self::BlockProducerEffectful(a) => a.kind(),
791 Self::Rpc(a) => a.kind(),
792 Self::RpcEffectful(a) => a.kind(),
793 Self::WatchedAccounts(a) => a.kind(),
794 }
795 }
796}
797
798impl ActionKindGet for CheckTimeoutsAction {
799 fn kind(&self) -> ActionKind {
800 ActionKind::CheckTimeouts
801 }
802}
803
804impl ActionKindGet for CheckInvalidPeersAction {
805 fn kind(&self) -> ActionKind {
806 ActionKind::CheckInvalidPeers
807 }
808}
809
810impl ActionKindGet for EventSourceAction {
811 fn kind(&self) -> ActionKind {
812 match self {
813 Self::ProcessEvents => ActionKind::EventSourceProcessEvents,
814 Self::NewEvent { .. } => ActionKind::EventSourceNewEvent,
815 Self::WaitForEvents => ActionKind::EventSourceWaitForEvents,
816 Self::WaitTimeout => ActionKind::EventSourceWaitTimeout,
817 }
818 }
819}
820
821impl ActionKindGet for P2pAction {
822 fn kind(&self) -> ActionKind {
823 match self {
824 Self::Initialization(a) => a.kind(),
825 Self::Connection(a) => a.kind(),
826 Self::Disconnection(a) => a.kind(),
827 Self::Identify(a) => a.kind(),
828 Self::Channels(a) => a.kind(),
829 Self::Peer(a) => a.kind(),
830 Self::Network(a) => a.kind(),
831 }
832 }
833}
834
835impl ActionKindGet for P2pEffectfulAction {
836 fn kind(&self) -> ActionKind {
837 match self {
838 Self::Channels(a) => a.kind(),
839 Self::Connection(a) => a.kind(),
840 Self::Disconnection(a) => a.kind(),
841 Self::Network(a) => a.kind(),
842 Self::Initialize => ActionKind::P2pEffectfulInitialize,
843 }
844 }
845}
846
847impl ActionKindGet for P2pCallbacksAction {
848 fn kind(&self) -> ActionKind {
849 match self {
850 Self::P2pChannelsRpcReady { .. } => ActionKind::P2pCallbacksP2pChannelsRpcReady,
851 Self::P2pChannelsRpcTimeout { .. } => ActionKind::P2pCallbacksP2pChannelsRpcTimeout,
852 Self::P2pChannelsRpcResponseReceived { .. } => {
853 ActionKind::P2pCallbacksP2pChannelsRpcResponseReceived
854 }
855 Self::P2pChannelsRpcRequestReceived { .. } => {
856 ActionKind::P2pCallbacksP2pChannelsRpcRequestReceived
857 }
858 Self::P2pChannelsStreamingRpcReady => {
859 ActionKind::P2pCallbacksP2pChannelsStreamingRpcReady
860 }
861 Self::P2pChannelsStreamingRpcTimeout { .. } => {
862 ActionKind::P2pCallbacksP2pChannelsStreamingRpcTimeout
863 }
864 Self::P2pChannelsStreamingRpcResponseReceived { .. } => {
865 ActionKind::P2pCallbacksP2pChannelsStreamingRpcResponseReceived
866 }
867 Self::P2pDisconnection { .. } => ActionKind::P2pCallbacksP2pDisconnection,
868 Self::RpcRespondBestTip { .. } => ActionKind::P2pCallbacksRpcRespondBestTip,
869 Self::P2pPubsubValidateMessage { .. } => {
870 ActionKind::P2pCallbacksP2pPubsubValidateMessage
871 }
872 }
873 }
874}
875
876impl ActionKindGet for LedgerAction {
877 fn kind(&self) -> ActionKind {
878 match self {
879 Self::Write(a) => a.kind(),
880 Self::Read(a) => a.kind(),
881 }
882 }
883}
884
885impl ActionKindGet for LedgerEffectfulAction {
886 fn kind(&self) -> ActionKind {
887 match self {
888 Self::WriteInit { .. } => ActionKind::LedgerEffectfulWriteInit,
889 Self::ReadInit { .. } => ActionKind::LedgerEffectfulReadInit,
890 }
891 }
892}
893
894impl ActionKindGet for SnarkAction {
895 fn kind(&self) -> ActionKind {
896 match self {
897 Self::BlockVerify(a) => a.kind(),
898 Self::BlockVerifyEffect(a) => a.kind(),
899 Self::WorkVerify(a) => a.kind(),
900 Self::WorkVerifyEffect(a) => a.kind(),
901 Self::UserCommandVerify(a) => a.kind(),
902 Self::UserCommandVerifyEffect(a) => a.kind(),
903 }
904 }
905}
906
907impl ActionKindGet for TransitionFrontierAction {
908 fn kind(&self) -> ActionKind {
909 match self {
910 Self::Genesis(a) => a.kind(),
911 Self::GenesisEffect(a) => a.kind(),
912 Self::Candidate(a) => a.kind(),
913 Self::Sync(a) => a.kind(),
914 Self::GenesisInject => ActionKind::TransitionFrontierGenesisInject,
915 Self::GenesisProvenInject => ActionKind::TransitionFrontierGenesisProvenInject,
916 Self::Synced { .. } => ActionKind::TransitionFrontierSynced,
917 Self::SyncFailed { .. } => ActionKind::TransitionFrontierSyncFailed,
918 }
919 }
920}
921
922impl ActionKindGet for SnarkPoolAction {
923 fn kind(&self) -> ActionKind {
924 match self {
925 Self::Candidate(a) => a.kind(),
926 Self::JobsUpdate { .. } => ActionKind::SnarkPoolJobsUpdate,
927 Self::AutoCreateCommitment => ActionKind::SnarkPoolAutoCreateCommitment,
928 Self::CommitmentCreateMany { .. } => ActionKind::SnarkPoolCommitmentCreateMany,
929 Self::CommitmentCreate { .. } => ActionKind::SnarkPoolCommitmentCreate,
930 Self::CommitmentAdd { .. } => ActionKind::SnarkPoolCommitmentAdd,
931 Self::WorkAdd { .. } => ActionKind::SnarkPoolWorkAdd,
932 Self::P2pSendAll => ActionKind::SnarkPoolP2pSendAll,
933 Self::P2pSend { .. } => ActionKind::SnarkPoolP2pSend,
934 Self::CheckTimeouts => ActionKind::SnarkPoolCheckTimeouts,
935 Self::JobCommitmentTimeout { .. } => ActionKind::SnarkPoolJobCommitmentTimeout,
936 }
937 }
938}
939
940impl ActionKindGet for SnarkPoolEffectfulAction {
941 fn kind(&self) -> ActionKind {
942 match self {
943 Self::SnarkPoolJobsRandomChoose { .. } => {
944 ActionKind::SnarkPoolEffectfulSnarkPoolJobsRandomChoose
945 }
946 }
947 }
948}
949
950impl ActionKindGet for TransactionPoolAction {
951 fn kind(&self) -> ActionKind {
952 match self {
953 Self::Candidate(a) => a.kind(),
954 Self::StartVerify { .. } => ActionKind::TransactionPoolStartVerify,
955 Self::StartVerifyWithAccounts { .. } => {
956 ActionKind::TransactionPoolStartVerifyWithAccounts
957 }
958 Self::VerifySuccess { .. } => ActionKind::TransactionPoolVerifySuccess,
959 Self::VerifyError { .. } => ActionKind::TransactionPoolVerifyError,
960 Self::BestTipChanged { .. } => ActionKind::TransactionPoolBestTipChanged,
961 Self::BestTipChangedWithAccounts { .. } => {
962 ActionKind::TransactionPoolBestTipChangedWithAccounts
963 }
964 Self::ApplyVerifiedDiff { .. } => ActionKind::TransactionPoolApplyVerifiedDiff,
965 Self::ApplyVerifiedDiffWithAccounts { .. } => {
966 ActionKind::TransactionPoolApplyVerifiedDiffWithAccounts
967 }
968 Self::ApplyTransitionFrontierDiff { .. } => {
969 ActionKind::TransactionPoolApplyTransitionFrontierDiff
970 }
971 Self::ApplyTransitionFrontierDiffWithAccounts { .. } => {
972 ActionKind::TransactionPoolApplyTransitionFrontierDiffWithAccounts
973 }
974 Self::Rebroadcast { .. } => ActionKind::TransactionPoolRebroadcast,
975 Self::CollectTransactionsByFee => ActionKind::TransactionPoolCollectTransactionsByFee,
976 Self::P2pSendAll => ActionKind::TransactionPoolP2pSendAll,
977 Self::P2pSend { .. } => ActionKind::TransactionPoolP2pSend,
978 }
979 }
980}
981
982impl ActionKindGet for TransactionPoolEffectfulAction {
983 fn kind(&self) -> ActionKind {
984 match self {
985 Self::FetchAccounts { .. } => ActionKind::TransactionPoolEffectfulFetchAccounts,
986 }
987 }
988}
989
990impl ActionKindGet for ExternalSnarkWorkerAction {
991 fn kind(&self) -> ActionKind {
992 match self {
993 Self::Start => ActionKind::ExternalSnarkWorkerStart,
994 Self::Started => ActionKind::ExternalSnarkWorkerStarted,
995 Self::StartTimeout { .. } => ActionKind::ExternalSnarkWorkerStartTimeout,
996 Self::Kill => ActionKind::ExternalSnarkWorkerKill,
997 Self::Killed => ActionKind::ExternalSnarkWorkerKilled,
998 Self::SubmitWork { .. } => ActionKind::ExternalSnarkWorkerSubmitWork,
999 Self::WorkResult { .. } => ActionKind::ExternalSnarkWorkerWorkResult,
1000 Self::WorkError { .. } => ActionKind::ExternalSnarkWorkerWorkError,
1001 Self::WorkTimeout { .. } => ActionKind::ExternalSnarkWorkerWorkTimeout,
1002 Self::CancelWork => ActionKind::ExternalSnarkWorkerCancelWork,
1003 Self::WorkCancelled => ActionKind::ExternalSnarkWorkerWorkCancelled,
1004 Self::PruneWork => ActionKind::ExternalSnarkWorkerPruneWork,
1005 Self::Error { .. } => ActionKind::ExternalSnarkWorkerError,
1006 }
1007 }
1008}
1009
1010impl ActionKindGet for ExternalSnarkWorkerEffectfulAction {
1011 fn kind(&self) -> ActionKind {
1012 match self {
1013 Self::Start { .. } => ActionKind::ExternalSnarkWorkerEffectfulStart,
1014 Self::Kill => ActionKind::ExternalSnarkWorkerEffectfulKill,
1015 Self::SubmitWork { .. } => ActionKind::ExternalSnarkWorkerEffectfulSubmitWork,
1016 Self::CancelWork => ActionKind::ExternalSnarkWorkerEffectfulCancelWork,
1017 }
1018 }
1019}
1020
1021impl ActionKindGet for BlockProducerAction {
1022 fn kind(&self) -> ActionKind {
1023 match self {
1024 Self::VrfEvaluator(a) => a.kind(),
1025 Self::BestTipUpdate { .. } => ActionKind::BlockProducerBestTipUpdate,
1026 Self::WonSlotSearch => ActionKind::BlockProducerWonSlotSearch,
1027 Self::WonSlot { .. } => ActionKind::BlockProducerWonSlot,
1028 Self::WonSlotDiscard { .. } => ActionKind::BlockProducerWonSlotDiscard,
1029 Self::WonSlotWait => ActionKind::BlockProducerWonSlotWait,
1030 Self::WonSlotTransactionsGet => ActionKind::BlockProducerWonSlotTransactionsGet,
1031 Self::WonSlotTransactionsSuccess { .. } => {
1032 ActionKind::BlockProducerWonSlotTransactionsSuccess
1033 }
1034 Self::WonSlotProduceInit => ActionKind::BlockProducerWonSlotProduceInit,
1035 Self::StagedLedgerDiffCreateInit => ActionKind::BlockProducerStagedLedgerDiffCreateInit,
1036 Self::StagedLedgerDiffCreatePending => {
1037 ActionKind::BlockProducerStagedLedgerDiffCreatePending
1038 }
1039 Self::StagedLedgerDiffCreateSuccess { .. } => {
1040 ActionKind::BlockProducerStagedLedgerDiffCreateSuccess
1041 }
1042 Self::BlockUnprovenBuild => ActionKind::BlockProducerBlockUnprovenBuild,
1043 Self::BlockProveInit => ActionKind::BlockProducerBlockProveInit,
1044 Self::BlockProvePending => ActionKind::BlockProducerBlockProvePending,
1045 Self::BlockProveSuccess { .. } => ActionKind::BlockProducerBlockProveSuccess,
1046 Self::BlockProduced => ActionKind::BlockProducerBlockProduced,
1047 Self::BlockInject => ActionKind::BlockProducerBlockInject,
1048 Self::BlockInjected => ActionKind::BlockProducerBlockInjected,
1049 }
1050 }
1051}
1052
1053impl ActionKindGet for BlockProducerEffectfulAction {
1054 fn kind(&self) -> ActionKind {
1055 match self {
1056 Self::VrfEvaluator(a) => a.kind(),
1057 Self::WonSlot { .. } => ActionKind::BlockProducerEffectfulWonSlot,
1058 Self::WonSlotDiscard { .. } => ActionKind::BlockProducerEffectfulWonSlotDiscard,
1059 Self::StagedLedgerDiffCreateInit => {
1060 ActionKind::BlockProducerEffectfulStagedLedgerDiffCreateInit
1061 }
1062 Self::StagedLedgerDiffCreateSuccess => {
1063 ActionKind::BlockProducerEffectfulStagedLedgerDiffCreateSuccess
1064 }
1065 Self::BlockUnprovenBuild => ActionKind::BlockProducerEffectfulBlockUnprovenBuild,
1066 Self::BlockProveInit => ActionKind::BlockProducerEffectfulBlockProveInit,
1067 Self::BlockProveSuccess => ActionKind::BlockProducerEffectfulBlockProveSuccess,
1068 Self::BlockProduced { .. } => ActionKind::BlockProducerEffectfulBlockProduced,
1069 }
1070 }
1071}
1072
1073impl ActionKindGet for RpcAction {
1074 fn kind(&self) -> ActionKind {
1075 match self {
1076 Self::GlobalStateGet { .. } => ActionKind::RpcGlobalStateGet,
1077 Self::StatusGet { .. } => ActionKind::RpcStatusGet,
1078 Self::HeartbeatGet { .. } => ActionKind::RpcHeartbeatGet,
1079 Self::ActionStatsGet { .. } => ActionKind::RpcActionStatsGet,
1080 Self::SyncStatsGet { .. } => ActionKind::RpcSyncStatsGet,
1081 Self::BlockProducerStatsGet { .. } => ActionKind::RpcBlockProducerStatsGet,
1082 Self::MessageProgressGet { .. } => ActionKind::RpcMessageProgressGet,
1083 Self::PeersGet { .. } => ActionKind::RpcPeersGet,
1084 Self::P2pConnectionOutgoingInit { .. } => ActionKind::RpcP2pConnectionOutgoingInit,
1085 Self::P2pConnectionOutgoingPending { .. } => {
1086 ActionKind::RpcP2pConnectionOutgoingPending
1087 }
1088 Self::P2pConnectionOutgoingError { .. } => ActionKind::RpcP2pConnectionOutgoingError,
1089 Self::P2pConnectionOutgoingSuccess { .. } => {
1090 ActionKind::RpcP2pConnectionOutgoingSuccess
1091 }
1092 Self::P2pConnectionIncomingInit { .. } => ActionKind::RpcP2pConnectionIncomingInit,
1093 Self::P2pConnectionIncomingPending { .. } => {
1094 ActionKind::RpcP2pConnectionIncomingPending
1095 }
1096 Self::P2pConnectionIncomingRespond { .. } => {
1097 ActionKind::RpcP2pConnectionIncomingRespond
1098 }
1099 Self::P2pConnectionIncomingAnswerReady { .. } => {
1100 ActionKind::RpcP2pConnectionIncomingAnswerReady
1101 }
1102 Self::P2pConnectionIncomingError { .. } => ActionKind::RpcP2pConnectionIncomingError,
1103 Self::P2pConnectionIncomingSuccess { .. } => {
1104 ActionKind::RpcP2pConnectionIncomingSuccess
1105 }
1106 Self::ScanStateSummaryGetInit { .. } => ActionKind::RpcScanStateSummaryGetInit,
1107 Self::ScanStateSummaryLedgerGetInit { .. } => {
1108 ActionKind::RpcScanStateSummaryLedgerGetInit
1109 }
1110 Self::ScanStateSummaryGetPending { .. } => ActionKind::RpcScanStateSummaryGetPending,
1111 Self::ScanStateSummaryGetSuccess { .. } => ActionKind::RpcScanStateSummaryGetSuccess,
1112 Self::SnarkPoolAvailableJobsGet { .. } => ActionKind::RpcSnarkPoolAvailableJobsGet,
1113 Self::SnarkPoolJobGet { .. } => ActionKind::RpcSnarkPoolJobGet,
1114 Self::SnarkPoolCompletedJobsGet { .. } => ActionKind::RpcSnarkPoolCompletedJobsGet,
1115 Self::SnarkPoolPendingJobsGet { .. } => ActionKind::RpcSnarkPoolPendingJobsGet,
1116 Self::SnarkerConfigGet { .. } => ActionKind::RpcSnarkerConfigGet,
1117 Self::SnarkerJobCommit { .. } => ActionKind::RpcSnarkerJobCommit,
1118 Self::SnarkerJobSpec { .. } => ActionKind::RpcSnarkerJobSpec,
1119 Self::SnarkerWorkersGet { .. } => ActionKind::RpcSnarkerWorkersGet,
1120 Self::HealthCheck { .. } => ActionKind::RpcHealthCheck,
1121 Self::ReadinessCheck { .. } => ActionKind::RpcReadinessCheck,
1122 Self::DiscoveryRoutingTable { .. } => ActionKind::RpcDiscoveryRoutingTable,
1123 Self::DiscoveryBoostrapStats { .. } => ActionKind::RpcDiscoveryBoostrapStats,
1124 Self::TransactionPool { .. } => ActionKind::RpcTransactionPool,
1125 Self::LedgerAccountsGetInit { .. } => ActionKind::RpcLedgerAccountsGetInit,
1126 Self::LedgerAccountsGetPending { .. } => ActionKind::RpcLedgerAccountsGetPending,
1127 Self::LedgerAccountsGetSuccess { .. } => ActionKind::RpcLedgerAccountsGetSuccess,
1128 Self::TransactionInjectInit { .. } => ActionKind::RpcTransactionInjectInit,
1129 Self::TransactionInjectPending { .. } => ActionKind::RpcTransactionInjectPending,
1130 Self::TransactionInjectSuccess { .. } => ActionKind::RpcTransactionInjectSuccess,
1131 Self::TransactionInjectRejected { .. } => ActionKind::RpcTransactionInjectRejected,
1132 Self::TransactionInjectFailure { .. } => ActionKind::RpcTransactionInjectFailure,
1133 Self::TransitionFrontierUserCommandsGet { .. } => {
1134 ActionKind::RpcTransitionFrontierUserCommandsGet
1135 }
1136 Self::BestChain { .. } => ActionKind::RpcBestChain,
1137 Self::ConsensusConstantsGet { .. } => ActionKind::RpcConsensusConstantsGet,
1138 Self::TransactionStatusGet { .. } => ActionKind::RpcTransactionStatusGet,
1139 Self::BlockGet { .. } => ActionKind::RpcBlockGet,
1140 Self::ConsensusTimeGet { .. } => ActionKind::RpcConsensusTimeGet,
1141 Self::LedgerStatusGetInit { .. } => ActionKind::RpcLedgerStatusGetInit,
1142 Self::LedgerStatusGetPending { .. } => ActionKind::RpcLedgerStatusGetPending,
1143 Self::LedgerStatusGetSuccess { .. } => ActionKind::RpcLedgerStatusGetSuccess,
1144 Self::LedgerAccountDelegatorsGetInit { .. } => {
1145 ActionKind::RpcLedgerAccountDelegatorsGetInit
1146 }
1147 Self::LedgerAccountDelegatorsGetPending { .. } => {
1148 ActionKind::RpcLedgerAccountDelegatorsGetPending
1149 }
1150 Self::LedgerAccountDelegatorsGetSuccess { .. } => {
1151 ActionKind::RpcLedgerAccountDelegatorsGetSuccess
1152 }
1153 Self::PooledUserCommands { .. } => ActionKind::RpcPooledUserCommands,
1154 Self::PooledZkappCommands { .. } => ActionKind::RpcPooledZkappCommands,
1155 Self::GenesisBlock { .. } => ActionKind::RpcGenesisBlock,
1156 Self::Finish { .. } => ActionKind::RpcFinish,
1157 }
1158 }
1159}
1160
1161impl ActionKindGet for RpcEffectfulAction {
1162 fn kind(&self) -> ActionKind {
1163 match self {
1164 Self::GlobalStateGet { .. } => ActionKind::RpcEffectfulGlobalStateGet,
1165 Self::StatusGet { .. } => ActionKind::RpcEffectfulStatusGet,
1166 Self::HeartbeatGet { .. } => ActionKind::RpcEffectfulHeartbeatGet,
1167 Self::ActionStatsGet { .. } => ActionKind::RpcEffectfulActionStatsGet,
1168 Self::SyncStatsGet { .. } => ActionKind::RpcEffectfulSyncStatsGet,
1169 Self::BlockProducerStatsGet { .. } => ActionKind::RpcEffectfulBlockProducerStatsGet,
1170 Self::MessageProgressGet { .. } => ActionKind::RpcEffectfulMessageProgressGet,
1171 Self::PeersGet { .. } => ActionKind::RpcEffectfulPeersGet,
1172 Self::P2pConnectionOutgoingError { .. } => {
1173 ActionKind::RpcEffectfulP2pConnectionOutgoingError
1174 }
1175 Self::P2pConnectionOutgoingSuccess { .. } => {
1176 ActionKind::RpcEffectfulP2pConnectionOutgoingSuccess
1177 }
1178 Self::P2pConnectionIncomingRespond { .. } => {
1179 ActionKind::RpcEffectfulP2pConnectionIncomingRespond
1180 }
1181 Self::P2pConnectionIncomingError { .. } => {
1182 ActionKind::RpcEffectfulP2pConnectionIncomingError
1183 }
1184 Self::P2pConnectionIncomingSuccess { .. } => {
1185 ActionKind::RpcEffectfulP2pConnectionIncomingSuccess
1186 }
1187 Self::ScanStateSummaryGetSuccess { .. } => {
1188 ActionKind::RpcEffectfulScanStateSummaryGetSuccess
1189 }
1190 Self::SnarkPoolAvailableJobsGet { .. } => {
1191 ActionKind::RpcEffectfulSnarkPoolAvailableJobsGet
1192 }
1193 Self::SnarkPoolJobGet { .. } => ActionKind::RpcEffectfulSnarkPoolJobGet,
1194 Self::SnarkPoolCompletedJobsGet { .. } => {
1195 ActionKind::RpcEffectfulSnarkPoolCompletedJobsGet
1196 }
1197 Self::SnarkPoolPendingJobsGet { .. } => ActionKind::RpcEffectfulSnarkPoolPendingJobsGet,
1198 Self::SnarkerConfigGet { .. } => ActionKind::RpcEffectfulSnarkerConfigGet,
1199 Self::SnarkerJobCommit { .. } => ActionKind::RpcEffectfulSnarkerJobCommit,
1200 Self::SnarkerJobSpec { .. } => ActionKind::RpcEffectfulSnarkerJobSpec,
1201 Self::SnarkerWorkersGet { .. } => ActionKind::RpcEffectfulSnarkerWorkersGet,
1202 Self::HealthCheck { .. } => ActionKind::RpcEffectfulHealthCheck,
1203 Self::ReadinessCheck { .. } => ActionKind::RpcEffectfulReadinessCheck,
1204 Self::DiscoveryRoutingTable { .. } => ActionKind::RpcEffectfulDiscoveryRoutingTable,
1205 Self::DiscoveryBoostrapStats { .. } => ActionKind::RpcEffectfulDiscoveryBoostrapStats,
1206 Self::TransactionPool { .. } => ActionKind::RpcEffectfulTransactionPool,
1207 Self::LedgerAccountsGetSuccess { .. } => {
1208 ActionKind::RpcEffectfulLedgerAccountsGetSuccess
1209 }
1210 Self::TransactionInjectSuccess { .. } => {
1211 ActionKind::RpcEffectfulTransactionInjectSuccess
1212 }
1213 Self::TransactionInjectRejected { .. } => {
1214 ActionKind::RpcEffectfulTransactionInjectRejected
1215 }
1216 Self::TransactionInjectFailure { .. } => {
1217 ActionKind::RpcEffectfulTransactionInjectFailure
1218 }
1219 Self::TransitionFrontierUserCommandsGet { .. } => {
1220 ActionKind::RpcEffectfulTransitionFrontierUserCommandsGet
1221 }
1222 Self::BestChain { .. } => ActionKind::RpcEffectfulBestChain,
1223 Self::ConsensusConstantsGet { .. } => ActionKind::RpcEffectfulConsensusConstantsGet,
1224 Self::TransactionStatusGet { .. } => ActionKind::RpcEffectfulTransactionStatusGet,
1225 Self::BlockGet { .. } => ActionKind::RpcEffectfulBlockGet,
1226 Self::PooledUserCommands { .. } => ActionKind::RpcEffectfulPooledUserCommands,
1227 Self::PooledZkappCommands { .. } => ActionKind::RpcEffectfulPooledZkappCommands,
1228 Self::GenesisBlock { .. } => ActionKind::RpcEffectfulGenesisBlock,
1229 Self::ConsensusTimeGet { .. } => ActionKind::RpcEffectfulConsensusTimeGet,
1230 Self::LedgerStatusGetSuccess { .. } => ActionKind::RpcEffectfulLedgerStatusGetSuccess,
1231 Self::LedgerAccountDelegatorsGetSuccess { .. } => {
1232 ActionKind::RpcEffectfulLedgerAccountDelegatorsGetSuccess
1233 }
1234 }
1235 }
1236}
1237
1238impl ActionKindGet for WatchedAccountsAction {
1239 fn kind(&self) -> ActionKind {
1240 match self {
1241 Self::Add { .. } => ActionKind::WatchedAccountsAdd,
1242 Self::LedgerInitialStateGetInit { .. } => {
1243 ActionKind::WatchedAccountsLedgerInitialStateGetInit
1244 }
1245 Self::LedgerInitialStateGetPending { .. } => {
1246 ActionKind::WatchedAccountsLedgerInitialStateGetPending
1247 }
1248 Self::LedgerInitialStateGetError { .. } => {
1249 ActionKind::WatchedAccountsLedgerInitialStateGetError
1250 }
1251 Self::LedgerInitialStateGetRetry { .. } => {
1252 ActionKind::WatchedAccountsLedgerInitialStateGetRetry
1253 }
1254 Self::LedgerInitialStateGetSuccess { .. } => {
1255 ActionKind::WatchedAccountsLedgerInitialStateGetSuccess
1256 }
1257 Self::TransactionsIncludedInBlock { .. } => {
1258 ActionKind::WatchedAccountsTransactionsIncludedInBlock
1259 }
1260 Self::BlockLedgerQueryInit { .. } => ActionKind::WatchedAccountsBlockLedgerQueryInit,
1261 Self::BlockLedgerQueryPending { .. } => {
1262 ActionKind::WatchedAccountsBlockLedgerQueryPending
1263 }
1264 Self::BlockLedgerQuerySuccess { .. } => {
1265 ActionKind::WatchedAccountsBlockLedgerQuerySuccess
1266 }
1267 }
1268 }
1269}
1270
1271impl ActionKindGet for P2pInitializeAction {
1272 fn kind(&self) -> ActionKind {
1273 match self {
1274 Self::Initialize { .. } => ActionKind::P2pInitializeInitialize,
1275 }
1276 }
1277}
1278
1279impl ActionKindGet for P2pConnectionAction {
1280 fn kind(&self) -> ActionKind {
1281 match self {
1282 Self::Outgoing(a) => a.kind(),
1283 Self::Incoming(a) => a.kind(),
1284 }
1285 }
1286}
1287
1288impl ActionKindGet for P2pDisconnectionAction {
1289 fn kind(&self) -> ActionKind {
1290 match self {
1291 Self::RandomTry => ActionKind::P2pDisconnectionRandomTry,
1292 Self::Init { .. } => ActionKind::P2pDisconnectionInit,
1293 Self::PeerClosed { .. } => ActionKind::P2pDisconnectionPeerClosed,
1294 Self::FailedCleanup { .. } => ActionKind::P2pDisconnectionFailedCleanup,
1295 Self::Finish { .. } => ActionKind::P2pDisconnectionFinish,
1296 }
1297 }
1298}
1299
1300impl ActionKindGet for P2pIdentifyAction {
1301 fn kind(&self) -> ActionKind {
1302 match self {
1303 Self::NewRequest { .. } => ActionKind::P2pIdentifyNewRequest,
1304 Self::UpdatePeerInformation { .. } => ActionKind::P2pIdentifyUpdatePeerInformation,
1305 }
1306 }
1307}
1308
1309impl ActionKindGet for P2pChannelsAction {
1310 fn kind(&self) -> ActionKind {
1311 match self {
1312 Self::MessageReceived(a) => a.kind(),
1313 Self::SignalingDiscovery(a) => a.kind(),
1314 Self::SignalingExchange(a) => a.kind(),
1315 Self::BestTip(a) => a.kind(),
1316 Self::Transaction(a) => a.kind(),
1317 Self::Snark(a) => a.kind(),
1318 Self::SnarkJobCommitment(a) => a.kind(),
1319 Self::Rpc(a) => a.kind(),
1320 Self::StreamingRpc(a) => a.kind(),
1321 }
1322 }
1323}
1324
1325impl ActionKindGet for P2pPeerAction {
1326 fn kind(&self) -> ActionKind {
1327 match self {
1328 Self::Discovered { .. } => ActionKind::P2pPeerDiscovered,
1329 Self::Ready { .. } => ActionKind::P2pPeerReady,
1330 Self::BestTipUpdate { .. } => ActionKind::P2pPeerBestTipUpdate,
1331 Self::Remove { .. } => ActionKind::P2pPeerRemove,
1332 }
1333 }
1334}
1335
1336impl ActionKindGet for P2pNetworkAction {
1337 fn kind(&self) -> ActionKind {
1338 match self {
1339 Self::Scheduler(a) => a.kind(),
1340 Self::Pnet(a) => a.kind(),
1341 Self::Select(a) => a.kind(),
1342 Self::Noise(a) => a.kind(),
1343 Self::Yamux(a) => a.kind(),
1344 Self::Identify(a) => a.kind(),
1345 Self::Kad(a) => a.kind(),
1346 Self::Pubsub(a) => a.kind(),
1347 Self::Rpc(a) => a.kind(),
1348 }
1349 }
1350}
1351
1352impl ActionKindGet for P2pChannelsEffectfulAction {
1353 fn kind(&self) -> ActionKind {
1354 match self {
1355 Self::InitChannel { .. } => ActionKind::P2pChannelsEffectfulInitChannel,
1356 Self::MessageSend { .. } => ActionKind::P2pChannelsEffectfulMessageSend,
1357 Self::SignalingDiscoveryAnswerDecrypt { .. } => {
1358 ActionKind::P2pChannelsEffectfulSignalingDiscoveryAnswerDecrypt
1359 }
1360 Self::SignalingDiscoveryOfferEncryptAndSend { .. } => {
1361 ActionKind::P2pChannelsEffectfulSignalingDiscoveryOfferEncryptAndSend
1362 }
1363 Self::SignalingExchangeOfferDecrypt { .. } => {
1364 ActionKind::P2pChannelsEffectfulSignalingExchangeOfferDecrypt
1365 }
1366 Self::SignalingExchangeAnswerEncryptAndSend { .. } => {
1367 ActionKind::P2pChannelsEffectfulSignalingExchangeAnswerEncryptAndSend
1368 }
1369 }
1370 }
1371}
1372
1373impl ActionKindGet for P2pConnectionEffectfulAction {
1374 fn kind(&self) -> ActionKind {
1375 match self {
1376 Self::Outgoing(a) => a.kind(),
1377 Self::Incoming(a) => a.kind(),
1378 }
1379 }
1380}
1381
1382impl ActionKindGet for P2pDisconnectionEffectfulAction {
1383 fn kind(&self) -> ActionKind {
1384 match self {
1385 Self::Init { .. } => ActionKind::P2pDisconnectionEffectfulInit,
1386 }
1387 }
1388}
1389
1390impl ActionKindGet for P2pNetworkEffectfulAction {
1391 fn kind(&self) -> ActionKind {
1392 match self {
1393 Self::Scheduler(a) => a.kind(),
1394 Self::Pnet(a) => a.kind(),
1395 Self::Pubsub(a) => a.kind(),
1396 Self::Identify(a) => a.kind(),
1397 Self::Kad(a) => a.kind(),
1398 }
1399 }
1400}
1401
1402impl ActionKindGet for LedgerWriteAction {
1403 fn kind(&self) -> ActionKind {
1404 match self {
1405 Self::Init { .. } => ActionKind::LedgerWriteInit,
1406 Self::Pending => ActionKind::LedgerWritePending,
1407 Self::Success { .. } => ActionKind::LedgerWriteSuccess,
1408 }
1409 }
1410}
1411
1412impl ActionKindGet for LedgerReadAction {
1413 fn kind(&self) -> ActionKind {
1414 match self {
1415 Self::FindTodos => ActionKind::LedgerReadFindTodos,
1416 Self::Init { .. } => ActionKind::LedgerReadInit,
1417 Self::Pending { .. } => ActionKind::LedgerReadPending,
1418 Self::Success { .. } => ActionKind::LedgerReadSuccess,
1419 Self::Prune { .. } => ActionKind::LedgerReadPrune,
1420 }
1421 }
1422}
1423
1424impl ActionKindGet for SnarkBlockVerifyAction {
1425 fn kind(&self) -> ActionKind {
1426 match self {
1427 Self::Init { .. } => ActionKind::SnarkBlockVerifyInit,
1428 Self::Pending { .. } => ActionKind::SnarkBlockVerifyPending,
1429 Self::Error { .. } => ActionKind::SnarkBlockVerifyError,
1430 Self::Success { .. } => ActionKind::SnarkBlockVerifySuccess,
1431 Self::Finish { .. } => ActionKind::SnarkBlockVerifyFinish,
1432 }
1433 }
1434}
1435
1436impl ActionKindGet for SnarkBlockVerifyEffectfulAction {
1437 fn kind(&self) -> ActionKind {
1438 match self {
1439 Self::Init { .. } => ActionKind::SnarkBlockVerifyEffectfulInit,
1440 }
1441 }
1442}
1443
1444impl ActionKindGet for SnarkWorkVerifyAction {
1445 fn kind(&self) -> ActionKind {
1446 match self {
1447 Self::Init { .. } => ActionKind::SnarkWorkVerifyInit,
1448 Self::Pending { .. } => ActionKind::SnarkWorkVerifyPending,
1449 Self::Error { .. } => ActionKind::SnarkWorkVerifyError,
1450 Self::Success { .. } => ActionKind::SnarkWorkVerifySuccess,
1451 Self::Finish { .. } => ActionKind::SnarkWorkVerifyFinish,
1452 }
1453 }
1454}
1455
1456impl ActionKindGet for SnarkWorkVerifyEffectfulAction {
1457 fn kind(&self) -> ActionKind {
1458 match self {
1459 Self::Init { .. } => ActionKind::SnarkWorkVerifyEffectfulInit,
1460 }
1461 }
1462}
1463
1464impl ActionKindGet for SnarkUserCommandVerifyAction {
1465 fn kind(&self) -> ActionKind {
1466 match self {
1467 Self::Init { .. } => ActionKind::SnarkUserCommandVerifyInit,
1468 Self::Pending { .. } => ActionKind::SnarkUserCommandVerifyPending,
1469 Self::Error { .. } => ActionKind::SnarkUserCommandVerifyError,
1470 Self::Success { .. } => ActionKind::SnarkUserCommandVerifySuccess,
1471 Self::Finish { .. } => ActionKind::SnarkUserCommandVerifyFinish,
1472 }
1473 }
1474}
1475
1476impl ActionKindGet for SnarkUserCommandVerifyEffectfulAction {
1477 fn kind(&self) -> ActionKind {
1478 match self {
1479 Self::Init { .. } => ActionKind::SnarkUserCommandVerifyEffectfulInit,
1480 }
1481 }
1482}
1483
1484impl ActionKindGet for TransitionFrontierGenesisAction {
1485 fn kind(&self) -> ActionKind {
1486 match self {
1487 Self::LedgerLoadInit => ActionKind::TransitionFrontierGenesisLedgerLoadInit,
1488 Self::LedgerLoadPending => ActionKind::TransitionFrontierGenesisLedgerLoadPending,
1489 Self::LedgerLoadSuccess { .. } => {
1490 ActionKind::TransitionFrontierGenesisLedgerLoadSuccess
1491 }
1492 Self::Produce => ActionKind::TransitionFrontierGenesisProduce,
1493 Self::ProveInit => ActionKind::TransitionFrontierGenesisProveInit,
1494 Self::ProvePending => ActionKind::TransitionFrontierGenesisProvePending,
1495 Self::ProveSuccess { .. } => ActionKind::TransitionFrontierGenesisProveSuccess,
1496 }
1497 }
1498}
1499
1500impl ActionKindGet for TransitionFrontierGenesisEffectfulAction {
1501 fn kind(&self) -> ActionKind {
1502 match self {
1503 Self::LedgerLoadInit { .. } => {
1504 ActionKind::TransitionFrontierGenesisEffectfulLedgerLoadInit
1505 }
1506 Self::ProveInit { .. } => ActionKind::TransitionFrontierGenesisEffectfulProveInit,
1507 }
1508 }
1509}
1510
1511impl ActionKindGet for TransitionFrontierCandidateAction {
1512 fn kind(&self) -> ActionKind {
1513 match self {
1514 Self::P2pBestTipUpdate { .. } => {
1515 ActionKind::TransitionFrontierCandidateP2pBestTipUpdate
1516 }
1517 Self::BlockReceived { .. } => ActionKind::TransitionFrontierCandidateBlockReceived,
1518 Self::BlockPrevalidateSuccess { .. } => {
1519 ActionKind::TransitionFrontierCandidateBlockPrevalidateSuccess
1520 }
1521 Self::BlockPrevalidateError { .. } => {
1522 ActionKind::TransitionFrontierCandidateBlockPrevalidateError
1523 }
1524 Self::BlockChainProofUpdate { .. } => {
1525 ActionKind::TransitionFrontierCandidateBlockChainProofUpdate
1526 }
1527 Self::BlockSnarkVerifyPending { .. } => {
1528 ActionKind::TransitionFrontierCandidateBlockSnarkVerifyPending
1529 }
1530 Self::BlockSnarkVerifySuccess { .. } => {
1531 ActionKind::TransitionFrontierCandidateBlockSnarkVerifySuccess
1532 }
1533 Self::BlockSnarkVerifyError { .. } => {
1534 ActionKind::TransitionFrontierCandidateBlockSnarkVerifyError
1535 }
1536 Self::TransitionFrontierSyncTargetUpdate => {
1537 ActionKind::TransitionFrontierCandidateTransitionFrontierSyncTargetUpdate
1538 }
1539 Self::Prune => ActionKind::TransitionFrontierCandidatePrune,
1540 }
1541 }
1542}
1543
1544impl ActionKindGet for TransitionFrontierSyncAction {
1545 fn kind(&self) -> ActionKind {
1546 match self {
1547 Self::Ledger(a) => a.kind(),
1548 Self::Init { .. } => ActionKind::TransitionFrontierSyncInit,
1549 Self::BestTipUpdate { .. } => ActionKind::TransitionFrontierSyncBestTipUpdate,
1550 Self::LedgerStakingPending => ActionKind::TransitionFrontierSyncLedgerStakingPending,
1551 Self::LedgerStakingSuccess => ActionKind::TransitionFrontierSyncLedgerStakingSuccess,
1552 Self::LedgerNextEpochPending => {
1553 ActionKind::TransitionFrontierSyncLedgerNextEpochPending
1554 }
1555 Self::LedgerNextEpochSuccess => {
1556 ActionKind::TransitionFrontierSyncLedgerNextEpochSuccess
1557 }
1558 Self::LedgerRootPending => ActionKind::TransitionFrontierSyncLedgerRootPending,
1559 Self::LedgerRootSuccess => ActionKind::TransitionFrontierSyncLedgerRootSuccess,
1560 Self::BlocksPending => ActionKind::TransitionFrontierSyncBlocksPending,
1561 Self::BlocksPeersQuery => ActionKind::TransitionFrontierSyncBlocksPeersQuery,
1562 Self::BlocksPeerQueryInit { .. } => {
1563 ActionKind::TransitionFrontierSyncBlocksPeerQueryInit
1564 }
1565 Self::BlocksPeerQueryRetry { .. } => {
1566 ActionKind::TransitionFrontierSyncBlocksPeerQueryRetry
1567 }
1568 Self::BlocksPeerQueryPending { .. } => {
1569 ActionKind::TransitionFrontierSyncBlocksPeerQueryPending
1570 }
1571 Self::BlocksPeerQueryError { .. } => {
1572 ActionKind::TransitionFrontierSyncBlocksPeerQueryError
1573 }
1574 Self::BlocksPeerQuerySuccess { .. } => {
1575 ActionKind::TransitionFrontierSyncBlocksPeerQuerySuccess
1576 }
1577 Self::BlocksFetchSuccess { .. } => ActionKind::TransitionFrontierSyncBlocksFetchSuccess,
1578 Self::BlocksNextApplyInit => ActionKind::TransitionFrontierSyncBlocksNextApplyInit,
1579 Self::BlocksNextApplyPending { .. } => {
1580 ActionKind::TransitionFrontierSyncBlocksNextApplyPending
1581 }
1582 Self::BlocksNextApplyError { .. } => {
1583 ActionKind::TransitionFrontierSyncBlocksNextApplyError
1584 }
1585 Self::BlocksNextApplySuccess { .. } => {
1586 ActionKind::TransitionFrontierSyncBlocksNextApplySuccess
1587 }
1588 Self::BlocksSendToArchive { .. } => {
1589 ActionKind::TransitionFrontierSyncBlocksSendToArchive
1590 }
1591 Self::BlocksSuccess => ActionKind::TransitionFrontierSyncBlocksSuccess,
1592 Self::CommitInit => ActionKind::TransitionFrontierSyncCommitInit,
1593 Self::CommitPending => ActionKind::TransitionFrontierSyncCommitPending,
1594 Self::CommitSuccess { .. } => ActionKind::TransitionFrontierSyncCommitSuccess,
1595 }
1596 }
1597}
1598
1599impl ActionKindGet for SnarkPoolCandidateAction {
1600 fn kind(&self) -> ActionKind {
1601 match self {
1602 Self::InfoReceived { .. } => ActionKind::SnarkPoolCandidateInfoReceived,
1603 Self::WorkFetchAll => ActionKind::SnarkPoolCandidateWorkFetchAll,
1604 Self::WorkFetchInit { .. } => ActionKind::SnarkPoolCandidateWorkFetchInit,
1605 Self::WorkFetchPending { .. } => ActionKind::SnarkPoolCandidateWorkFetchPending,
1606 Self::WorkFetchError { .. } => ActionKind::SnarkPoolCandidateWorkFetchError,
1607 Self::WorkFetchSuccess { .. } => ActionKind::SnarkPoolCandidateWorkFetchSuccess,
1608 Self::WorkVerifyNext => ActionKind::SnarkPoolCandidateWorkVerifyNext,
1609 Self::WorkVerifyPending { .. } => ActionKind::SnarkPoolCandidateWorkVerifyPending,
1610 Self::WorkVerifyError { .. } => ActionKind::SnarkPoolCandidateWorkVerifyError,
1611 Self::WorkVerifySuccess { .. } => ActionKind::SnarkPoolCandidateWorkVerifySuccess,
1612 Self::PeerPrune { .. } => ActionKind::SnarkPoolCandidatePeerPrune,
1613 }
1614 }
1615}
1616
1617impl ActionKindGet for TransactionPoolCandidateAction {
1618 fn kind(&self) -> ActionKind {
1619 match self {
1620 Self::InfoReceived { .. } => ActionKind::TransactionPoolCandidateInfoReceived,
1621 Self::FetchAll => ActionKind::TransactionPoolCandidateFetchAll,
1622 Self::FetchInit { .. } => ActionKind::TransactionPoolCandidateFetchInit,
1623 Self::FetchPending { .. } => ActionKind::TransactionPoolCandidateFetchPending,
1624 Self::FetchError { .. } => ActionKind::TransactionPoolCandidateFetchError,
1625 Self::FetchSuccess { .. } => ActionKind::TransactionPoolCandidateFetchSuccess,
1626 Self::Libp2pTransactionsReceived { .. } => {
1627 ActionKind::TransactionPoolCandidateLibp2pTransactionsReceived
1628 }
1629 Self::VerifyNext => ActionKind::TransactionPoolCandidateVerifyNext,
1630 Self::VerifyPending { .. } => ActionKind::TransactionPoolCandidateVerifyPending,
1631 Self::VerifyError { .. } => ActionKind::TransactionPoolCandidateVerifyError,
1632 Self::VerifySuccess { .. } => ActionKind::TransactionPoolCandidateVerifySuccess,
1633 Self::PeerPrune { .. } => ActionKind::TransactionPoolCandidatePeerPrune,
1634 }
1635 }
1636}
1637
1638impl ActionKindGet for BlockProducerVrfEvaluatorAction {
1639 fn kind(&self) -> ActionKind {
1640 match self {
1641 Self::EvaluateSlot { .. } => ActionKind::BlockProducerVrfEvaluatorEvaluateSlot,
1642 Self::ProcessSlotEvaluationSuccess { .. } => {
1643 ActionKind::BlockProducerVrfEvaluatorProcessSlotEvaluationSuccess
1644 }
1645 Self::InitializeEvaluator { .. } => {
1646 ActionKind::BlockProducerVrfEvaluatorInitializeEvaluator
1647 }
1648 Self::FinalizeEvaluatorInitialization { .. } => {
1649 ActionKind::BlockProducerVrfEvaluatorFinalizeEvaluatorInitialization
1650 }
1651 Self::CheckEpochEvaluability { .. } => {
1652 ActionKind::BlockProducerVrfEvaluatorCheckEpochEvaluability
1653 }
1654 Self::InitializeEpochEvaluation { .. } => {
1655 ActionKind::BlockProducerVrfEvaluatorInitializeEpochEvaluation
1656 }
1657 Self::BeginDelegatorTableConstruction => {
1658 ActionKind::BlockProducerVrfEvaluatorBeginDelegatorTableConstruction
1659 }
1660 Self::FinalizeDelegatorTableConstruction { .. } => {
1661 ActionKind::BlockProducerVrfEvaluatorFinalizeDelegatorTableConstruction
1662 }
1663 Self::SelectInitialSlot { .. } => {
1664 ActionKind::BlockProducerVrfEvaluatorSelectInitialSlot
1665 }
1666 Self::BeginEpochEvaluation { .. } => {
1667 ActionKind::BlockProducerVrfEvaluatorBeginEpochEvaluation
1668 }
1669 Self::InterruptEpochEvaluation { .. } => {
1670 ActionKind::BlockProducerVrfEvaluatorInterruptEpochEvaluation
1671 }
1672 Self::ContinueEpochEvaluation { .. } => {
1673 ActionKind::BlockProducerVrfEvaluatorContinueEpochEvaluation
1674 }
1675 Self::FinishEpochEvaluation { .. } => {
1676 ActionKind::BlockProducerVrfEvaluatorFinishEpochEvaluation
1677 }
1678 Self::WaitForNextEvaluation => {
1679 ActionKind::BlockProducerVrfEvaluatorWaitForNextEvaluation
1680 }
1681 Self::CheckEpochBounds { .. } => ActionKind::BlockProducerVrfEvaluatorCheckEpochBounds,
1682 Self::CleanupOldSlots { .. } => ActionKind::BlockProducerVrfEvaluatorCleanupOldSlots,
1683 }
1684 }
1685}
1686
1687impl ActionKindGet for BlockProducerVrfEvaluatorEffectfulAction {
1688 fn kind(&self) -> ActionKind {
1689 match self {
1690 Self::EvaluateSlot { .. } => ActionKind::BlockProducerVrfEvaluatorEffectfulEvaluateSlot,
1691 Self::SlotEvaluated { .. } => {
1692 ActionKind::BlockProducerVrfEvaluatorEffectfulSlotEvaluated
1693 }
1694 Self::InitializeStats { .. } => {
1695 ActionKind::BlockProducerVrfEvaluatorEffectfulInitializeStats
1696 }
1697 }
1698 }
1699}
1700
1701impl ActionKindGet for P2pConnectionOutgoingAction {
1702 fn kind(&self) -> ActionKind {
1703 match self {
1704 Self::RandomInit => ActionKind::P2pConnectionOutgoingRandomInit,
1705 Self::Init { .. } => ActionKind::P2pConnectionOutgoingInit,
1706 Self::Reconnect { .. } => ActionKind::P2pConnectionOutgoingReconnect,
1707 Self::OfferSdpCreatePending { .. } => {
1708 ActionKind::P2pConnectionOutgoingOfferSdpCreatePending
1709 }
1710 Self::OfferSdpCreateError { .. } => {
1711 ActionKind::P2pConnectionOutgoingOfferSdpCreateError
1712 }
1713 Self::OfferSdpCreateSuccess { .. } => {
1714 ActionKind::P2pConnectionOutgoingOfferSdpCreateSuccess
1715 }
1716 Self::OfferReady { .. } => ActionKind::P2pConnectionOutgoingOfferReady,
1717 Self::OfferSendSuccess { .. } => ActionKind::P2pConnectionOutgoingOfferSendSuccess,
1718 Self::AnswerRecvPending { .. } => ActionKind::P2pConnectionOutgoingAnswerRecvPending,
1719 Self::AnswerRecvError { .. } => ActionKind::P2pConnectionOutgoingAnswerRecvError,
1720 Self::AnswerRecvSuccess { .. } => ActionKind::P2pConnectionOutgoingAnswerRecvSuccess,
1721 Self::FinalizePending { .. } => ActionKind::P2pConnectionOutgoingFinalizePending,
1722 Self::FinalizeError { .. } => ActionKind::P2pConnectionOutgoingFinalizeError,
1723 Self::FinalizeSuccess { .. } => ActionKind::P2pConnectionOutgoingFinalizeSuccess,
1724 Self::Timeout { .. } => ActionKind::P2pConnectionOutgoingTimeout,
1725 Self::Error { .. } => ActionKind::P2pConnectionOutgoingError,
1726 Self::Success { .. } => ActionKind::P2pConnectionOutgoingSuccess,
1727 }
1728 }
1729}
1730
1731impl ActionKindGet for P2pConnectionIncomingAction {
1732 fn kind(&self) -> ActionKind {
1733 match self {
1734 Self::Init { .. } => ActionKind::P2pConnectionIncomingInit,
1735 Self::AnswerSdpCreatePending { .. } => {
1736 ActionKind::P2pConnectionIncomingAnswerSdpCreatePending
1737 }
1738 Self::AnswerSdpCreateError { .. } => {
1739 ActionKind::P2pConnectionIncomingAnswerSdpCreateError
1740 }
1741 Self::AnswerSdpCreateSuccess { .. } => {
1742 ActionKind::P2pConnectionIncomingAnswerSdpCreateSuccess
1743 }
1744 Self::AnswerReady { .. } => ActionKind::P2pConnectionIncomingAnswerReady,
1745 Self::AnswerSendSuccess { .. } => ActionKind::P2pConnectionIncomingAnswerSendSuccess,
1746 Self::FinalizePending { .. } => ActionKind::P2pConnectionIncomingFinalizePending,
1747 Self::FinalizeError { .. } => ActionKind::P2pConnectionIncomingFinalizeError,
1748 Self::FinalizeSuccess { .. } => ActionKind::P2pConnectionIncomingFinalizeSuccess,
1749 Self::Timeout { .. } => ActionKind::P2pConnectionIncomingTimeout,
1750 Self::Error { .. } => ActionKind::P2pConnectionIncomingError,
1751 Self::Success { .. } => ActionKind::P2pConnectionIncomingSuccess,
1752 Self::FinalizePendingLibp2p { .. } => {
1753 ActionKind::P2pConnectionIncomingFinalizePendingLibp2p
1754 }
1755 Self::Libp2pReceived { .. } => ActionKind::P2pConnectionIncomingLibp2pReceived,
1756 }
1757 }
1758}
1759
1760impl ActionKindGet for P2pChannelsMessageReceivedAction {
1761 fn kind(&self) -> ActionKind {
1762 ActionKind::P2pChannelsMessageReceived
1763 }
1764}
1765
1766impl ActionKindGet for P2pChannelsSignalingDiscoveryAction {
1767 fn kind(&self) -> ActionKind {
1768 match self {
1769 Self::Init { .. } => ActionKind::P2pChannelsSignalingDiscoveryInit,
1770 Self::Pending { .. } => ActionKind::P2pChannelsSignalingDiscoveryPending,
1771 Self::Ready { .. } => ActionKind::P2pChannelsSignalingDiscoveryReady,
1772 Self::RequestSend { .. } => ActionKind::P2pChannelsSignalingDiscoveryRequestSend,
1773 Self::DiscoveryRequestReceived { .. } => {
1774 ActionKind::P2pChannelsSignalingDiscoveryDiscoveryRequestReceived
1775 }
1776 Self::DiscoveredSend { .. } => ActionKind::P2pChannelsSignalingDiscoveryDiscoveredSend,
1777 Self::DiscoveredRejectReceived { .. } => {
1778 ActionKind::P2pChannelsSignalingDiscoveryDiscoveredRejectReceived
1779 }
1780 Self::DiscoveredAcceptReceived { .. } => {
1781 ActionKind::P2pChannelsSignalingDiscoveryDiscoveredAcceptReceived
1782 }
1783 Self::AnswerSend { .. } => ActionKind::P2pChannelsSignalingDiscoveryAnswerSend,
1784 Self::RequestReceived { .. } => {
1785 ActionKind::P2pChannelsSignalingDiscoveryRequestReceived
1786 }
1787 Self::DiscoveryRequestSend { .. } => {
1788 ActionKind::P2pChannelsSignalingDiscoveryDiscoveryRequestSend
1789 }
1790 Self::DiscoveredReceived { .. } => {
1791 ActionKind::P2pChannelsSignalingDiscoveryDiscoveredReceived
1792 }
1793 Self::DiscoveredReject { .. } => {
1794 ActionKind::P2pChannelsSignalingDiscoveryDiscoveredReject
1795 }
1796 Self::DiscoveredAccept { .. } => {
1797 ActionKind::P2pChannelsSignalingDiscoveryDiscoveredAccept
1798 }
1799 Self::AnswerReceived { .. } => ActionKind::P2pChannelsSignalingDiscoveryAnswerReceived,
1800 Self::AnswerDecrypted { .. } => {
1801 ActionKind::P2pChannelsSignalingDiscoveryAnswerDecrypted
1802 }
1803 }
1804 }
1805}
1806
1807impl ActionKindGet for P2pChannelsSignalingExchangeAction {
1808 fn kind(&self) -> ActionKind {
1809 match self {
1810 Self::Init { .. } => ActionKind::P2pChannelsSignalingExchangeInit,
1811 Self::Pending { .. } => ActionKind::P2pChannelsSignalingExchangePending,
1812 Self::Ready { .. } => ActionKind::P2pChannelsSignalingExchangeReady,
1813 Self::RequestSend { .. } => ActionKind::P2pChannelsSignalingExchangeRequestSend,
1814 Self::OfferReceived { .. } => ActionKind::P2pChannelsSignalingExchangeOfferReceived,
1815 Self::OfferDecryptError { .. } => {
1816 ActionKind::P2pChannelsSignalingExchangeOfferDecryptError
1817 }
1818 Self::OfferDecryptSuccess { .. } => {
1819 ActionKind::P2pChannelsSignalingExchangeOfferDecryptSuccess
1820 }
1821 Self::AnswerSend { .. } => ActionKind::P2pChannelsSignalingExchangeAnswerSend,
1822 Self::RequestReceived { .. } => ActionKind::P2pChannelsSignalingExchangeRequestReceived,
1823 Self::OfferSend { .. } => ActionKind::P2pChannelsSignalingExchangeOfferSend,
1824 Self::AnswerReceived { .. } => ActionKind::P2pChannelsSignalingExchangeAnswerReceived,
1825 }
1826 }
1827}
1828
1829impl ActionKindGet for P2pChannelsBestTipAction {
1830 fn kind(&self) -> ActionKind {
1831 match self {
1832 Self::Init { .. } => ActionKind::P2pChannelsBestTipInit,
1833 Self::Pending { .. } => ActionKind::P2pChannelsBestTipPending,
1834 Self::Ready { .. } => ActionKind::P2pChannelsBestTipReady,
1835 Self::RequestSend { .. } => ActionKind::P2pChannelsBestTipRequestSend,
1836 Self::Received { .. } => ActionKind::P2pChannelsBestTipReceived,
1837 Self::RequestReceived { .. } => ActionKind::P2pChannelsBestTipRequestReceived,
1838 Self::ResponseSend { .. } => ActionKind::P2pChannelsBestTipResponseSend,
1839 }
1840 }
1841}
1842
1843impl ActionKindGet for P2pChannelsTransactionAction {
1844 fn kind(&self) -> ActionKind {
1845 match self {
1846 Self::Init { .. } => ActionKind::P2pChannelsTransactionInit,
1847 Self::Pending { .. } => ActionKind::P2pChannelsTransactionPending,
1848 Self::Ready { .. } => ActionKind::P2pChannelsTransactionReady,
1849 Self::RequestSend { .. } => ActionKind::P2pChannelsTransactionRequestSend,
1850 Self::PromiseReceived { .. } => ActionKind::P2pChannelsTransactionPromiseReceived,
1851 Self::Received { .. } => ActionKind::P2pChannelsTransactionReceived,
1852 Self::RequestReceived { .. } => ActionKind::P2pChannelsTransactionRequestReceived,
1853 Self::ResponseSend { .. } => ActionKind::P2pChannelsTransactionResponseSend,
1854 Self::Libp2pReceived { .. } => ActionKind::P2pChannelsTransactionLibp2pReceived,
1855 Self::Libp2pBroadcast { .. } => ActionKind::P2pChannelsTransactionLibp2pBroadcast,
1856 }
1857 }
1858}
1859
1860impl ActionKindGet for P2pChannelsSnarkAction {
1861 fn kind(&self) -> ActionKind {
1862 match self {
1863 Self::Init { .. } => ActionKind::P2pChannelsSnarkInit,
1864 Self::Pending { .. } => ActionKind::P2pChannelsSnarkPending,
1865 Self::Ready { .. } => ActionKind::P2pChannelsSnarkReady,
1866 Self::RequestSend { .. } => ActionKind::P2pChannelsSnarkRequestSend,
1867 Self::PromiseReceived { .. } => ActionKind::P2pChannelsSnarkPromiseReceived,
1868 Self::Received { .. } => ActionKind::P2pChannelsSnarkReceived,
1869 Self::RequestReceived { .. } => ActionKind::P2pChannelsSnarkRequestReceived,
1870 Self::ResponseSend { .. } => ActionKind::P2pChannelsSnarkResponseSend,
1871 Self::Libp2pReceived { .. } => ActionKind::P2pChannelsSnarkLibp2pReceived,
1872 Self::Libp2pBroadcast { .. } => ActionKind::P2pChannelsSnarkLibp2pBroadcast,
1873 }
1874 }
1875}
1876
1877impl ActionKindGet for P2pChannelsSnarkJobCommitmentAction {
1878 fn kind(&self) -> ActionKind {
1879 match self {
1880 Self::Init { .. } => ActionKind::P2pChannelsSnarkJobCommitmentInit,
1881 Self::Pending { .. } => ActionKind::P2pChannelsSnarkJobCommitmentPending,
1882 Self::Ready { .. } => ActionKind::P2pChannelsSnarkJobCommitmentReady,
1883 Self::RequestSend { .. } => ActionKind::P2pChannelsSnarkJobCommitmentRequestSend,
1884 Self::PromiseReceived { .. } => {
1885 ActionKind::P2pChannelsSnarkJobCommitmentPromiseReceived
1886 }
1887 Self::Received { .. } => ActionKind::P2pChannelsSnarkJobCommitmentReceived,
1888 Self::RequestReceived { .. } => {
1889 ActionKind::P2pChannelsSnarkJobCommitmentRequestReceived
1890 }
1891 Self::ResponseSend { .. } => ActionKind::P2pChannelsSnarkJobCommitmentResponseSend,
1892 }
1893 }
1894}
1895
1896impl ActionKindGet for P2pChannelsRpcAction {
1897 fn kind(&self) -> ActionKind {
1898 match self {
1899 Self::Init { .. } => ActionKind::P2pChannelsRpcInit,
1900 Self::Pending { .. } => ActionKind::P2pChannelsRpcPending,
1901 Self::Ready { .. } => ActionKind::P2pChannelsRpcReady,
1902 Self::RequestSend { .. } => ActionKind::P2pChannelsRpcRequestSend,
1903 Self::Timeout { .. } => ActionKind::P2pChannelsRpcTimeout,
1904 Self::ResponseReceived { .. } => ActionKind::P2pChannelsRpcResponseReceived,
1905 Self::RequestReceived { .. } => ActionKind::P2pChannelsRpcRequestReceived,
1906 Self::ResponsePending { .. } => ActionKind::P2pChannelsRpcResponsePending,
1907 Self::ResponseSend { .. } => ActionKind::P2pChannelsRpcResponseSend,
1908 }
1909 }
1910}
1911
1912impl ActionKindGet for P2pChannelsStreamingRpcAction {
1913 fn kind(&self) -> ActionKind {
1914 match self {
1915 Self::Init { .. } => ActionKind::P2pChannelsStreamingRpcInit,
1916 Self::Pending { .. } => ActionKind::P2pChannelsStreamingRpcPending,
1917 Self::Ready { .. } => ActionKind::P2pChannelsStreamingRpcReady,
1918 Self::RequestSend { .. } => ActionKind::P2pChannelsStreamingRpcRequestSend,
1919 Self::Timeout { .. } => ActionKind::P2pChannelsStreamingRpcTimeout,
1920 Self::ResponseNextPartGet { .. } => {
1921 ActionKind::P2pChannelsStreamingRpcResponseNextPartGet
1922 }
1923 Self::ResponsePartReceived { .. } => {
1924 ActionKind::P2pChannelsStreamingRpcResponsePartReceived
1925 }
1926 Self::ResponseReceived { .. } => ActionKind::P2pChannelsStreamingRpcResponseReceived,
1927 Self::RequestReceived { .. } => ActionKind::P2pChannelsStreamingRpcRequestReceived,
1928 Self::ResponsePending { .. } => ActionKind::P2pChannelsStreamingRpcResponsePending,
1929 Self::ResponseSendInit { .. } => ActionKind::P2pChannelsStreamingRpcResponseSendInit,
1930 Self::ResponsePartNextSend { .. } => {
1931 ActionKind::P2pChannelsStreamingRpcResponsePartNextSend
1932 }
1933 Self::ResponsePartSend { .. } => ActionKind::P2pChannelsStreamingRpcResponsePartSend,
1934 Self::ResponseSent { .. } => ActionKind::P2pChannelsStreamingRpcResponseSent,
1935 }
1936 }
1937}
1938
1939impl ActionKindGet for P2pNetworkSchedulerAction {
1940 fn kind(&self) -> ActionKind {
1941 match self {
1942 Self::InterfaceDetected { .. } => ActionKind::P2pNetworkSchedulerInterfaceDetected,
1943 Self::InterfaceExpired { .. } => ActionKind::P2pNetworkSchedulerInterfaceExpired,
1944 Self::ListenerReady { .. } => ActionKind::P2pNetworkSchedulerListenerReady,
1945 Self::ListenerError { .. } => ActionKind::P2pNetworkSchedulerListenerError,
1946 Self::IncomingConnectionIsReady { .. } => {
1947 ActionKind::P2pNetworkSchedulerIncomingConnectionIsReady
1948 }
1949 Self::IncomingDidAccept { .. } => ActionKind::P2pNetworkSchedulerIncomingDidAccept,
1950 Self::IncomingDataIsReady { .. } => ActionKind::P2pNetworkSchedulerIncomingDataIsReady,
1951 Self::OutgoingConnect { .. } => ActionKind::P2pNetworkSchedulerOutgoingConnect,
1952 Self::OutgoingDidConnect { .. } => ActionKind::P2pNetworkSchedulerOutgoingDidConnect,
1953 Self::IncomingDataDidReceive { .. } => {
1954 ActionKind::P2pNetworkSchedulerIncomingDataDidReceive
1955 }
1956 Self::SelectDone { .. } => ActionKind::P2pNetworkSchedulerSelectDone,
1957 Self::SelectError { .. } => ActionKind::P2pNetworkSchedulerSelectError,
1958 Self::YamuxDidInit { .. } => ActionKind::P2pNetworkSchedulerYamuxDidInit,
1959 Self::Disconnect { .. } => ActionKind::P2pNetworkSchedulerDisconnect,
1960 Self::Error { .. } => ActionKind::P2pNetworkSchedulerError,
1961 Self::Disconnected { .. } => ActionKind::P2pNetworkSchedulerDisconnected,
1962 Self::Prune { .. } => ActionKind::P2pNetworkSchedulerPrune,
1963 Self::PruneStream { .. } => ActionKind::P2pNetworkSchedulerPruneStream,
1964 }
1965 }
1966}
1967
1968impl ActionKindGet for P2pNetworkPnetAction {
1969 fn kind(&self) -> ActionKind {
1970 match self {
1971 Self::IncomingData { .. } => ActionKind::P2pNetworkPnetIncomingData,
1972 Self::OutgoingData { .. } => ActionKind::P2pNetworkPnetOutgoingData,
1973 Self::SetupNonce { .. } => ActionKind::P2pNetworkPnetSetupNonce,
1974 Self::Timeout { .. } => ActionKind::P2pNetworkPnetTimeout,
1975 }
1976 }
1977}
1978
1979impl ActionKindGet for P2pNetworkSelectAction {
1980 fn kind(&self) -> ActionKind {
1981 match self {
1982 Self::Init { .. } => ActionKind::P2pNetworkSelectInit,
1983 Self::IncomingDataAuth { .. } => ActionKind::P2pNetworkSelectIncomingDataAuth,
1984 Self::IncomingDataMux { .. } => ActionKind::P2pNetworkSelectIncomingDataMux,
1985 Self::IncomingData { .. } => ActionKind::P2pNetworkSelectIncomingData,
1986 Self::IncomingPayloadAuth { .. } => ActionKind::P2pNetworkSelectIncomingPayloadAuth,
1987 Self::IncomingPayloadMux { .. } => ActionKind::P2pNetworkSelectIncomingPayloadMux,
1988 Self::IncomingPayload { .. } => ActionKind::P2pNetworkSelectIncomingPayload,
1989 Self::IncomingToken { .. } => ActionKind::P2pNetworkSelectIncomingToken,
1990 Self::OutgoingTokens { .. } => ActionKind::P2pNetworkSelectOutgoingTokens,
1991 Self::Timeout { .. } => ActionKind::P2pNetworkSelectTimeout,
1992 }
1993 }
1994}
1995
1996impl ActionKindGet for P2pNetworkNoiseAction {
1997 fn kind(&self) -> ActionKind {
1998 match self {
1999 Self::Init { .. } => ActionKind::P2pNetworkNoiseInit,
2000 Self::IncomingData { .. } => ActionKind::P2pNetworkNoiseIncomingData,
2001 Self::IncomingChunk { .. } => ActionKind::P2pNetworkNoiseIncomingChunk,
2002 Self::OutgoingChunk { .. } => ActionKind::P2pNetworkNoiseOutgoingChunk,
2003 Self::OutgoingChunkSelectMux { .. } => {
2004 ActionKind::P2pNetworkNoiseOutgoingChunkSelectMux
2005 }
2006 Self::OutgoingData { .. } => ActionKind::P2pNetworkNoiseOutgoingData,
2007 Self::OutgoingDataSelectMux { .. } => ActionKind::P2pNetworkNoiseOutgoingDataSelectMux,
2008 Self::DecryptedData { .. } => ActionKind::P2pNetworkNoiseDecryptedData,
2009 Self::HandshakeDone { .. } => ActionKind::P2pNetworkNoiseHandshakeDone,
2010 }
2011 }
2012}
2013
2014impl ActionKindGet for P2pNetworkYamuxAction {
2015 fn kind(&self) -> ActionKind {
2016 match self {
2017 Self::IncomingData { .. } => ActionKind::P2pNetworkYamuxIncomingData,
2018 Self::OutgoingData { .. } => ActionKind::P2pNetworkYamuxOutgoingData,
2019 Self::IncomingFrame { .. } => ActionKind::P2pNetworkYamuxIncomingFrame,
2020 Self::OutgoingFrame { .. } => ActionKind::P2pNetworkYamuxOutgoingFrame,
2021 Self::PingStream { .. } => ActionKind::P2pNetworkYamuxPingStream,
2022 Self::OpenStream { .. } => ActionKind::P2pNetworkYamuxOpenStream,
2023 }
2024 }
2025}
2026
2027impl ActionKindGet for P2pNetworkIdentifyAction {
2028 fn kind(&self) -> ActionKind {
2029 match self {
2030 Self::Stream(a) => a.kind(),
2031 }
2032 }
2033}
2034
2035impl ActionKindGet for P2pNetworkKadAction {
2036 fn kind(&self) -> ActionKind {
2037 match self {
2038 Self::System(a) => a.kind(),
2039 Self::Bootstrap(a) => a.kind(),
2040 Self::Request(a) => a.kind(),
2041 Self::Stream(a) => a.kind(),
2042 }
2043 }
2044}
2045
2046impl ActionKindGet for P2pNetworkPubsubAction {
2047 fn kind(&self) -> ActionKind {
2048 match self {
2049 Self::NewStream { .. } => ActionKind::P2pNetworkPubsubNewStream,
2050 Self::IncomingData { .. } => ActionKind::P2pNetworkPubsubIncomingData,
2051 Self::ValidateIncomingMessages { .. } => {
2052 ActionKind::P2pNetworkPubsubValidateIncomingMessages
2053 }
2054 Self::IncomingMessage { .. } => ActionKind::P2pNetworkPubsubIncomingMessage,
2055 Self::IncomingMessageCleanup { .. } => {
2056 ActionKind::P2pNetworkPubsubIncomingMessageCleanup
2057 }
2058 Self::Graft { .. } => ActionKind::P2pNetworkPubsubGraft,
2059 Self::Prune { .. } => ActionKind::P2pNetworkPubsubPrune,
2060 Self::WebRtcRebroadcast { .. } => ActionKind::P2pNetworkPubsubWebRtcRebroadcast,
2061 Self::Broadcast { .. } => ActionKind::P2pNetworkPubsubBroadcast,
2062 Self::Sign { .. } => ActionKind::P2pNetworkPubsubSign,
2063 Self::SignError { .. } => ActionKind::P2pNetworkPubsubSignError,
2064 Self::BroadcastSigned { .. } => ActionKind::P2pNetworkPubsubBroadcastSigned,
2065 Self::OutgoingMessage { .. } => ActionKind::P2pNetworkPubsubOutgoingMessage,
2066 Self::OutgoingMessageClear { .. } => ActionKind::P2pNetworkPubsubOutgoingMessageClear,
2067 Self::OutgoingMessageError { .. } => ActionKind::P2pNetworkPubsubOutgoingMessageError,
2068 Self::OutgoingData { .. } => ActionKind::P2pNetworkPubsubOutgoingData,
2069 Self::HandleIncomingMessage { .. } => ActionKind::P2pNetworkPubsubHandleIncomingMessage,
2070 Self::ValidateIncomingMessage { .. } => {
2071 ActionKind::P2pNetworkPubsubValidateIncomingMessage
2072 }
2073 Self::PruneMessages { .. } => ActionKind::P2pNetworkPubsubPruneMessages,
2074 Self::RejectMessage { .. } => ActionKind::P2pNetworkPubsubRejectMessage,
2075 Self::IgnoreMessage { .. } => ActionKind::P2pNetworkPubsubIgnoreMessage,
2076 Self::BroadcastValidatedMessage { .. } => {
2077 ActionKind::P2pNetworkPubsubBroadcastValidatedMessage
2078 }
2079 }
2080 }
2081}
2082
2083impl ActionKindGet for P2pNetworkRpcAction {
2084 fn kind(&self) -> ActionKind {
2085 match self {
2086 Self::Init { .. } => ActionKind::P2pNetworkRpcInit,
2087 Self::IncomingData { .. } => ActionKind::P2pNetworkRpcIncomingData,
2088 Self::IncomingMessage { .. } => ActionKind::P2pNetworkRpcIncomingMessage,
2089 Self::PrunePending { .. } => ActionKind::P2pNetworkRpcPrunePending,
2090 Self::HeartbeatSend { .. } => ActionKind::P2pNetworkRpcHeartbeatSend,
2091 Self::OutgoingQuery { .. } => ActionKind::P2pNetworkRpcOutgoingQuery,
2092 Self::OutgoingResponse { .. } => ActionKind::P2pNetworkRpcOutgoingResponse,
2093 Self::OutgoingData { .. } => ActionKind::P2pNetworkRpcOutgoingData,
2094 }
2095 }
2096}
2097
2098impl ActionKindGet for P2pConnectionOutgoingEffectfulAction {
2099 fn kind(&self) -> ActionKind {
2100 match self {
2101 Self::RandomInit { .. } => ActionKind::P2pConnectionOutgoingEffectfulRandomInit,
2102 Self::Init { .. } => ActionKind::P2pConnectionOutgoingEffectfulInit,
2103 Self::OfferSend { .. } => ActionKind::P2pConnectionOutgoingEffectfulOfferSend,
2104 Self::AnswerSet { .. } => ActionKind::P2pConnectionOutgoingEffectfulAnswerSet,
2105 Self::ConnectionAuthorizationEncryptAndSend { .. } => {
2106 ActionKind::P2pConnectionOutgoingEffectfulConnectionAuthorizationEncryptAndSend
2107 }
2108 Self::ConnectionAuthorizationDecryptAndCheck { .. } => {
2109 ActionKind::P2pConnectionOutgoingEffectfulConnectionAuthorizationDecryptAndCheck
2110 }
2111 }
2112 }
2113}
2114
2115impl ActionKindGet for P2pConnectionIncomingEffectfulAction {
2116 fn kind(&self) -> ActionKind {
2117 match self {
2118 Self::Init { .. } => ActionKind::P2pConnectionIncomingEffectfulInit,
2119 Self::ConnectionAuthorizationEncryptAndSend { .. } => {
2120 ActionKind::P2pConnectionIncomingEffectfulConnectionAuthorizationEncryptAndSend
2121 }
2122 Self::ConnectionAuthorizationDecryptAndCheck { .. } => {
2123 ActionKind::P2pConnectionIncomingEffectfulConnectionAuthorizationDecryptAndCheck
2124 }
2125 }
2126 }
2127}
2128
2129impl ActionKindGet for P2pNetworkSchedulerEffectfulAction {
2130 fn kind(&self) -> ActionKind {
2131 match self {
2132 Self::InterfaceDetected { .. } => {
2133 ActionKind::P2pNetworkSchedulerEffectfulInterfaceDetected
2134 }
2135 Self::IncomingConnectionIsReady { .. } => {
2136 ActionKind::P2pNetworkSchedulerEffectfulIncomingConnectionIsReady
2137 }
2138 Self::IncomingDidAccept { .. } => {
2139 ActionKind::P2pNetworkSchedulerEffectfulIncomingDidAccept
2140 }
2141 Self::OutgoingConnect { .. } => ActionKind::P2pNetworkSchedulerEffectfulOutgoingConnect,
2142 Self::OutgoingDidConnect { .. } => {
2143 ActionKind::P2pNetworkSchedulerEffectfulOutgoingDidConnect
2144 }
2145 Self::IncomingDataIsReady { .. } => {
2146 ActionKind::P2pNetworkSchedulerEffectfulIncomingDataIsReady
2147 }
2148 Self::NoiseSelectDone { .. } => ActionKind::P2pNetworkSchedulerEffectfulNoiseSelectDone,
2149 Self::Disconnect { .. } => ActionKind::P2pNetworkSchedulerEffectfulDisconnect,
2150 }
2151 }
2152}
2153
2154impl ActionKindGet for P2pNetworkPnetEffectfulAction {
2155 fn kind(&self) -> ActionKind {
2156 match self {
2157 Self::OutgoingData { .. } => ActionKind::P2pNetworkPnetEffectfulOutgoingData,
2158 Self::SetupNonce { .. } => ActionKind::P2pNetworkPnetEffectfulSetupNonce,
2159 }
2160 }
2161}
2162
2163impl ActionKindGet for P2pNetworkPubsubEffectfulAction {
2164 fn kind(&self) -> ActionKind {
2165 match self {
2166 Self::Sign { .. } => ActionKind::P2pNetworkPubsubEffectfulSign,
2167 Self::ValidateIncomingMessages { .. } => {
2168 ActionKind::P2pNetworkPubsubEffectfulValidateIncomingMessages
2169 }
2170 }
2171 }
2172}
2173
2174impl ActionKindGet for P2pNetworkIdentifyEffectfulAction {
2175 fn kind(&self) -> ActionKind {
2176 match self {
2177 Self::Stream(a) => a.kind(),
2178 }
2179 }
2180}
2181
2182impl ActionKindGet for P2pNetworkKadEffectfulAction {
2183 fn kind(&self) -> ActionKind {
2184 match self {
2185 Self::Discovered { .. } => ActionKind::P2pNetworkKadEffectfulDiscovered,
2186 Self::MakeRequest { .. } => ActionKind::P2pNetworkKadEffectfulMakeRequest,
2187 }
2188 }
2189}
2190
2191impl ActionKindGet for TransitionFrontierSyncLedgerAction {
2192 fn kind(&self) -> ActionKind {
2193 match self {
2194 Self::Snarked(a) => a.kind(),
2195 Self::Staged(a) => a.kind(),
2196 Self::Init => ActionKind::TransitionFrontierSyncLedgerInit,
2197 Self::Success => ActionKind::TransitionFrontierSyncLedgerSuccess,
2198 }
2199 }
2200}
2201
2202impl ActionKindGet for P2pNetworkIdentifyStreamAction {
2203 fn kind(&self) -> ActionKind {
2204 match self {
2205 Self::New { .. } => ActionKind::P2pNetworkIdentifyStreamNew,
2206 Self::IncomingData { .. } => ActionKind::P2pNetworkIdentifyStreamIncomingData,
2207 Self::Close { .. } => ActionKind::P2pNetworkIdentifyStreamClose,
2208 Self::RemoteClose { .. } => ActionKind::P2pNetworkIdentifyStreamRemoteClose,
2209 Self::Prune { .. } => ActionKind::P2pNetworkIdentifyStreamPrune,
2210 Self::SendIdentify { .. } => ActionKind::P2pNetworkIdentifyStreamSendIdentify,
2211 }
2212 }
2213}
2214
2215impl ActionKindGet for P2pNetworkKademliaAction {
2216 fn kind(&self) -> ActionKind {
2217 match self {
2218 Self::AnswerFindNodeRequest { .. } => {
2219 ActionKind::P2pNetworkKademliaAnswerFindNodeRequest
2220 }
2221 Self::UpdateFindNodeRequest { .. } => {
2222 ActionKind::P2pNetworkKademliaUpdateFindNodeRequest
2223 }
2224 Self::StartBootstrap { .. } => ActionKind::P2pNetworkKademliaStartBootstrap,
2225 Self::BootstrapFinished => ActionKind::P2pNetworkKademliaBootstrapFinished,
2226 Self::UpdateRoutingTable { .. } => ActionKind::P2pNetworkKademliaUpdateRoutingTable,
2227 }
2228 }
2229}
2230
2231impl ActionKindGet for P2pNetworkKadBootstrapAction {
2232 fn kind(&self) -> ActionKind {
2233 match self {
2234 Self::CreateRequests => ActionKind::P2pNetworkKadBootstrapCreateRequests,
2235 Self::AppendRequest { .. } => ActionKind::P2pNetworkKadBootstrapAppendRequest,
2236 Self::FinalizeRequests => ActionKind::P2pNetworkKadBootstrapFinalizeRequests,
2237 Self::RequestDone { .. } => ActionKind::P2pNetworkKadBootstrapRequestDone,
2238 Self::RequestError { .. } => ActionKind::P2pNetworkKadBootstrapRequestError,
2239 }
2240 }
2241}
2242
2243impl ActionKindGet for P2pNetworkKadRequestAction {
2244 fn kind(&self) -> ActionKind {
2245 match self {
2246 Self::New { .. } => ActionKind::P2pNetworkKadRequestNew,
2247 Self::PeerIsConnecting { .. } => ActionKind::P2pNetworkKadRequestPeerIsConnecting,
2248 Self::MuxReady { .. } => ActionKind::P2pNetworkKadRequestMuxReady,
2249 Self::StreamIsCreating { .. } => ActionKind::P2pNetworkKadRequestStreamIsCreating,
2250 Self::StreamReady { .. } => ActionKind::P2pNetworkKadRequestStreamReady,
2251 Self::RequestSent { .. } => ActionKind::P2pNetworkKadRequestRequestSent,
2252 Self::ReplyReceived { .. } => ActionKind::P2pNetworkKadRequestReplyReceived,
2253 Self::Prune { .. } => ActionKind::P2pNetworkKadRequestPrune,
2254 Self::Error { .. } => ActionKind::P2pNetworkKadRequestError,
2255 }
2256 }
2257}
2258
2259impl ActionKindGet for P2pNetworkKademliaStreamAction {
2260 fn kind(&self) -> ActionKind {
2261 match self {
2262 Self::New { .. } => ActionKind::P2pNetworkKademliaStreamNew,
2263 Self::IncomingData { .. } => ActionKind::P2pNetworkKademliaStreamIncomingData,
2264 Self::RemoteClose { .. } => ActionKind::P2pNetworkKademliaStreamRemoteClose,
2265 Self::WaitIncoming { .. } => ActionKind::P2pNetworkKademliaStreamWaitIncoming,
2266 Self::WaitOutgoing { .. } => ActionKind::P2pNetworkKademliaStreamWaitOutgoing,
2267 Self::SendRequest { .. } => ActionKind::P2pNetworkKademliaStreamSendRequest,
2268 Self::SendResponse { .. } => ActionKind::P2pNetworkKademliaStreamSendResponse,
2269 Self::OutgoingDataReady { .. } => ActionKind::P2pNetworkKademliaStreamOutgoingDataReady,
2270 Self::Close { .. } => ActionKind::P2pNetworkKademliaStreamClose,
2271 Self::Prune { .. } => ActionKind::P2pNetworkKademliaStreamPrune,
2272 }
2273 }
2274}
2275
2276impl ActionKindGet for P2pNetworkIdentifyStreamEffectfulAction {
2277 fn kind(&self) -> ActionKind {
2278 match self {
2279 Self::GetListenAddresses { .. } => {
2280 ActionKind::P2pNetworkIdentifyStreamEffectfulGetListenAddresses
2281 }
2282 }
2283 }
2284}
2285
2286impl ActionKindGet for TransitionFrontierSyncLedgerSnarkedAction {
2287 fn kind(&self) -> ActionKind {
2288 match self {
2289 Self::Pending => ActionKind::TransitionFrontierSyncLedgerSnarkedPending,
2290 Self::PeersQuery => ActionKind::TransitionFrontierSyncLedgerSnarkedPeersQuery,
2291 Self::PeerQueryNumAccountsInit { .. } => {
2292 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsInit
2293 }
2294 Self::PeerQueryNumAccountsPending { .. } => {
2295 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsPending
2296 }
2297 Self::PeerQueryNumAccountsRetry { .. } => {
2298 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsRetry
2299 }
2300 Self::PeerQueryNumAccountsError { .. } => {
2301 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsError
2302 }
2303 Self::PeerQueryNumAccountsSuccess { .. } => {
2304 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryNumAccountsSuccess
2305 }
2306 Self::NumAccountsReceived { .. } => {
2307 ActionKind::TransitionFrontierSyncLedgerSnarkedNumAccountsReceived
2308 }
2309 Self::NumAccountsAccepted { .. } => {
2310 ActionKind::TransitionFrontierSyncLedgerSnarkedNumAccountsAccepted
2311 }
2312 Self::NumAccountsRejected { .. } => {
2313 ActionKind::TransitionFrontierSyncLedgerSnarkedNumAccountsRejected
2314 }
2315 Self::NumAccountsSuccess { .. } => {
2316 ActionKind::TransitionFrontierSyncLedgerSnarkedNumAccountsSuccess
2317 }
2318 Self::MerkleTreeSyncPending => {
2319 ActionKind::TransitionFrontierSyncLedgerSnarkedMerkleTreeSyncPending
2320 }
2321 Self::PeerQueryAddressInit { .. } => {
2322 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryAddressInit
2323 }
2324 Self::PeerQueryAddressPending { .. } => {
2325 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryAddressPending
2326 }
2327 Self::PeerQueryAddressRetry { .. } => {
2328 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryAddressRetry
2329 }
2330 Self::PeerQueryAddressError { .. } => {
2331 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryAddressError
2332 }
2333 Self::PeerQueryAddressSuccess { .. } => {
2334 ActionKind::TransitionFrontierSyncLedgerSnarkedPeerQueryAddressSuccess
2335 }
2336 Self::ChildHashesReceived { .. } => {
2337 ActionKind::TransitionFrontierSyncLedgerSnarkedChildHashesReceived
2338 }
2339 Self::ChildHashesAccepted { .. } => {
2340 ActionKind::TransitionFrontierSyncLedgerSnarkedChildHashesAccepted
2341 }
2342 Self::ChildHashesRejected { .. } => {
2343 ActionKind::TransitionFrontierSyncLedgerSnarkedChildHashesRejected
2344 }
2345 Self::ChildAccountsReceived { .. } => {
2346 ActionKind::TransitionFrontierSyncLedgerSnarkedChildAccountsReceived
2347 }
2348 Self::ChildAccountsAccepted { .. } => {
2349 ActionKind::TransitionFrontierSyncLedgerSnarkedChildAccountsAccepted
2350 }
2351 Self::ChildAccountsRejected { .. } => {
2352 ActionKind::TransitionFrontierSyncLedgerSnarkedChildAccountsRejected
2353 }
2354 Self::MerkleTreeSyncSuccess => {
2355 ActionKind::TransitionFrontierSyncLedgerSnarkedMerkleTreeSyncSuccess
2356 }
2357 Self::Success => ActionKind::TransitionFrontierSyncLedgerSnarkedSuccess,
2358 }
2359 }
2360}
2361
2362impl ActionKindGet for TransitionFrontierSyncLedgerStagedAction {
2363 fn kind(&self) -> ActionKind {
2364 match self {
2365 Self::PartsFetchPending => {
2366 ActionKind::TransitionFrontierSyncLedgerStagedPartsFetchPending
2367 }
2368 Self::PartsPeerFetchInit => {
2369 ActionKind::TransitionFrontierSyncLedgerStagedPartsPeerFetchInit
2370 }
2371 Self::PartsPeerFetchPending { .. } => {
2372 ActionKind::TransitionFrontierSyncLedgerStagedPartsPeerFetchPending
2373 }
2374 Self::PartsPeerFetchError { .. } => {
2375 ActionKind::TransitionFrontierSyncLedgerStagedPartsPeerFetchError
2376 }
2377 Self::PartsPeerFetchSuccess { .. } => {
2378 ActionKind::TransitionFrontierSyncLedgerStagedPartsPeerFetchSuccess
2379 }
2380 Self::PartsPeerInvalid { .. } => {
2381 ActionKind::TransitionFrontierSyncLedgerStagedPartsPeerInvalid
2382 }
2383 Self::PartsPeerValid { .. } => {
2384 ActionKind::TransitionFrontierSyncLedgerStagedPartsPeerValid
2385 }
2386 Self::PartsFetchSuccess { .. } => {
2387 ActionKind::TransitionFrontierSyncLedgerStagedPartsFetchSuccess
2388 }
2389 Self::ReconstructEmpty => {
2390 ActionKind::TransitionFrontierSyncLedgerStagedReconstructEmpty
2391 }
2392 Self::ReconstructInit => ActionKind::TransitionFrontierSyncLedgerStagedReconstructInit,
2393 Self::ReconstructPending => {
2394 ActionKind::TransitionFrontierSyncLedgerStagedReconstructPending
2395 }
2396 Self::ReconstructError { .. } => {
2397 ActionKind::TransitionFrontierSyncLedgerStagedReconstructError
2398 }
2399 Self::ReconstructSuccess { .. } => {
2400 ActionKind::TransitionFrontierSyncLedgerStagedReconstructSuccess
2401 }
2402 Self::Success => ActionKind::TransitionFrontierSyncLedgerStagedSuccess,
2403 }
2404 }
2405}