Documentation
¶
Overview ¶
staker_delegated.go
staker_delegated.go
staker_delegated.go
staker_delegated.go
event_handler.go
staker_delegated.go
staker_delegated.go
Index ¶
- func ConvertToWithdrawal(event delegationmanager.IDelegationManagerWithdrawal) *xmsgtypes.Withdrawal
- func NewEVMEventReactor(evmClient interfaces.EVMRPCClient, jsonRPC interfaces.EVMJSONRPCClient, ...) interfaces.IEVMEventReactor
- type EVMEventReactor
- func (r *EVMEventReactor) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt, lastBlock uint64) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (r *EVMEventReactor) HandleBlocks(startBlock, toBlock uint64) (map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx, uint64)
- func (r *EVMEventReactor) RegisterEventHandler(handler interfaces.ChainEventHandler)
- type PellSentHandler
- func (h *PellSentHandler) BuildInboundVoteMsg(event *pellconnector.PellConnectorPellSent, sender common.Address) *xmsgtypes.MsgVoteOnObservedInboundTx
- func (h *PellSentHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (h *PellSentHandler) HandleBlocks(startBlock, toBlock uint64, ...) (uint64, error)
- type RegisterChainDVSToPellHandler
- func (h *RegisterChainDVSToPellHandler) BuildInboundVoteMsg(event *RegisterToPellEvents, sender common.Address) *xmsgtypes.MsgVoteOnObservedInboundTx
- func (h *RegisterChainDVSToPellHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (h *RegisterChainDVSToPellHandler) HandleBlocks(startBlock, toBlock uint64, ...) (uint64, error)
- type RegisterToPellEvents
- type StakerDelegatedHandler
- func (h *StakerDelegatedHandler) BuildInboundVoteMsg(event *delegationmanager.DelegationManagerStakerDelegated, ...) *xmsgtypes.MsgVoteOnObservedInboundTx
- func (h *StakerDelegatedHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (h *StakerDelegatedHandler) HandleBlocks(startBlock, toBlock uint64, ...) (uint64, error)
- type StakerDepositHandler
- func (h *StakerDepositHandler) BuildInboundVoteMsg(event *strategymanager.StrategyManagerDeposit, sender common.Address) *xmsgtypes.MsgVoteOnObservedInboundTx
- func (h *StakerDepositHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (h *StakerDepositHandler) HandleBlocks(startBlock, toBlock uint64, ...) (uint64, error)
- type StakerUndelegatedHandler
- func (h *StakerUndelegatedHandler) BuildInboundVoteMsg(event *delegationmanager.DelegationManagerStakerUndelegated, ...) *xmsgtypes.MsgVoteOnObservedInboundTx
- func (h *StakerUndelegatedHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (h *StakerUndelegatedHandler) HandleBlocks(startBlock, toBlock uint64, ...) (uint64, error)
- type TxEvents
- type WithdrawalQueuedHandler
- func (h *WithdrawalQueuedHandler) BuildInboundVoteMsg(event *delegationmanager.DelegationManagerWithdrawalQueued, ...) *xmsgtypes.MsgVoteOnObservedInboundTx
- func (h *WithdrawalQueuedHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
- func (h *WithdrawalQueuedHandler) HandleBlocks(startBlock, toBlock uint64, ...) (uint64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConvertToWithdrawal ¶
func ConvertToWithdrawal(event delegationmanager.IDelegationManagerWithdrawal) *xmsgtypes.Withdrawal
func NewEVMEventReactor ¶
func NewEVMEventReactor( evmClient interfaces.EVMRPCClient, jsonRPC interfaces.EVMJSONRPCClient, chainParams relayertypes.ChainParams, chain chains.Chain, coreClient interfaces.PellCoreBridger, logger *base.ObserverLogger) interfaces.IEVMEventReactor
Types ¶
type EVMEventReactor ¶
type EVMEventReactor struct {
// contains filtered or unexported fields
}
func (*EVMEventReactor) CheckAndBuildInboundVoteMsg ¶
func (r *EVMEventReactor) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt, lastBlock uint64) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*EVMEventReactor) HandleBlocks ¶
func (r *EVMEventReactor) HandleBlocks(startBlock, toBlock uint64) (map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx, uint64)
func (*EVMEventReactor) RegisterEventHandler ¶
func (r *EVMEventReactor) RegisterEventHandler(handler interfaces.ChainEventHandler)
type PellSentHandler ¶
type PellSentHandler struct {
EvmJSONRPC interfaces.EVMJSONRPCClient
ContractAddr common.Address
Contract *pellconnector.PellConnector
ChainId int64
CoreChainId int64
SignerAddress string
InBoundLogger zerolog.Logger
ComplianceLogger zerolog.Logger
}
func (*PellSentHandler) BuildInboundVoteMsg ¶
func (h *PellSentHandler) BuildInboundVoteMsg( event *pellconnector.PellConnectorPellSent, sender common.Address, ) *xmsgtypes.MsgVoteOnObservedInboundTx
func (*PellSentHandler) CheckAndBuildInboundVoteMsg ¶
func (h *PellSentHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*PellSentHandler) HandleBlocks ¶
func (h *PellSentHandler) HandleBlocks(startBlock, toBlock uint64, eventStore *map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx) (uint64, error)
type RegisterChainDVSToPellHandler ¶
type RegisterChainDVSToPellHandler struct {
EvmJSONRPC interfaces.EVMJSONRPCClient
ContractAddr common.Address
Contract *registryinteractor.RegistryInteractor
ChainId int64
CoreChainId int64
SignerAddress string
InBoundLogger zerolog.Logger
ComplianceLogger zerolog.Logger
}
func (*RegisterChainDVSToPellHandler) BuildInboundVoteMsg ¶
func (h *RegisterChainDVSToPellHandler) BuildInboundVoteMsg( event *RegisterToPellEvents, sender common.Address, ) *xmsgtypes.MsgVoteOnObservedInboundTx
func (*RegisterChainDVSToPellHandler) CheckAndBuildInboundVoteMsg ¶
func (h *RegisterChainDVSToPellHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*RegisterChainDVSToPellHandler) HandleBlocks ¶
func (h *RegisterChainDVSToPellHandler) HandleBlocks(startBlock, toBlock uint64, eventStore *map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx) (uint64, error)
HandleBlocks processes the blocks from startBlock to toBlock and returns the last scanned block need three types of events in one tx to build the message 1. CentralSchedulerEvent 2. StakeManagerEvent 3. EjectionManagerEvent
type RegisterToPellEvents ¶
type RegisterToPellEvents struct {
CentralSchedulerEvent *registryinteractor.RegistryInteractorRegisterCentralSchedulerToPell
StakeManagerEvent *registryinteractor.RegistryInteractorRegisterStakeManagerToPell
EjectionManagerEvent *registryinteractor.RegistryInteractorRegisterEjectionManagerToPell
}
Add this struct to hold all three event types
type StakerDelegatedHandler ¶
type StakerDelegatedHandler struct {
EvmJSONRPC interfaces.EVMJSONRPCClient
ContractAddr common.Address
Contract *delegationmanager.DelegationManager
ChainId int64
CoreChainId int64
SignerAddress string
InBoundLogger zerolog.Logger
ComplianceLogger zerolog.Logger
}
func (*StakerDelegatedHandler) BuildInboundVoteMsg ¶
func (h *StakerDelegatedHandler) BuildInboundVoteMsg( event *delegationmanager.DelegationManagerStakerDelegated, sender common.Address, ) *xmsgtypes.MsgVoteOnObservedInboundTx
func (*StakerDelegatedHandler) CheckAndBuildInboundVoteMsg ¶
func (h *StakerDelegatedHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*StakerDelegatedHandler) HandleBlocks ¶
func (h *StakerDelegatedHandler) HandleBlocks(startBlock, toBlock uint64, eventStore *map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx) (uint64, error)
type StakerDepositHandler ¶
type StakerDepositHandler struct {
EvmJSONRPC interfaces.EVMJSONRPCClient
ContractAddr common.Address
Contract *strategymanager.StrategyManager
ChainId int64
CoreChainId int64
SignerAddress string
InBoundLogger zerolog.Logger
ComplianceLogger zerolog.Logger
}
func (*StakerDepositHandler) BuildInboundVoteMsg ¶
func (h *StakerDepositHandler) BuildInboundVoteMsg( event *strategymanager.StrategyManagerDeposit, sender common.Address, ) *xmsgtypes.MsgVoteOnObservedInboundTx
func (*StakerDepositHandler) CheckAndBuildInboundVoteMsg ¶
func (h *StakerDepositHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*StakerDepositHandler) HandleBlocks ¶
func (h *StakerDepositHandler) HandleBlocks(startBlock, toBlock uint64, eventStore *map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx) (uint64, error)
type StakerUndelegatedHandler ¶
type StakerUndelegatedHandler struct {
EvmJSONRPC interfaces.EVMJSONRPCClient
ContractAddr common.Address
Contract *delegationmanager.DelegationManager
ChainId int64
CoreChainId int64
SignerAddress string
InBoundLogger zerolog.Logger
ComplianceLogger zerolog.Logger
}
func (*StakerUndelegatedHandler) BuildInboundVoteMsg ¶
func (h *StakerUndelegatedHandler) BuildInboundVoteMsg( event *delegationmanager.DelegationManagerStakerUndelegated, sender common.Address, ) *xmsgtypes.MsgVoteOnObservedInboundTx
func (*StakerUndelegatedHandler) CheckAndBuildInboundVoteMsg ¶
func (h *StakerUndelegatedHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*StakerUndelegatedHandler) HandleBlocks ¶
func (h *StakerUndelegatedHandler) HandleBlocks(startBlock, toBlock uint64, eventStore *map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx) (uint64, error)
type TxEvents ¶
type TxEvents struct {
BlockNumber uint64
TxHash string
Events *RegisterToPellEvents
}
TxEvents is used to collect and sort the completed events by block number.
type WithdrawalQueuedHandler ¶
type WithdrawalQueuedHandler struct {
EvmJSONRPC interfaces.EVMJSONRPCClient
ContractAddr common.Address
Contract *delegationmanager.DelegationManager
ChainId int64
CoreChainId int64
SignerAddress string
InBoundLogger zerolog.Logger
ComplianceLogger zerolog.Logger
}
func (*WithdrawalQueuedHandler) BuildInboundVoteMsg ¶
func (h *WithdrawalQueuedHandler) BuildInboundVoteMsg( event *delegationmanager.DelegationManagerWithdrawalQueued, sender common.Address, ) *xmsgtypes.MsgVoteOnObservedInboundTx
func (*WithdrawalQueuedHandler) CheckAndBuildInboundVoteMsg ¶
func (h *WithdrawalQueuedHandler) CheckAndBuildInboundVoteMsg(tx *ethrpc.Transaction, receipt *ethtypes.Receipt) ([]*xmsgtypes.MsgVoteOnObservedInboundTx, error)
func (*WithdrawalQueuedHandler) HandleBlocks ¶
func (h *WithdrawalQueuedHandler) HandleBlocks(startBlock, toBlock uint64, eventStore *map[uint64][]*xmsgtypes.MsgVoteOnObservedInboundTx) (uint64, error)
Click to show internal directories.
Click to hide internal directories.