Documentation ¶
Index ¶
- Variables
- func GenerateKeyFile(fileLocation string)
- func RegisterConsensusMessages(cdc *amino.Codec)
- func RegisterPacket(cdc *amino.Codec)
- func RunDataConnect(peerAddr string, marlinTo chan marlinTypes.MarlinMessage, ...)
- func RunSpamFilter(rpcAddr string, marlinTo chan marlinTypes.MarlinMessage, ...)
- func VerifyKeyFile(fileLocation string) (bool, error)
- type BitArray
- type BlockID
- type BlockPartMessage
- type CanonicalBlockID
- type CanonicalPartSetHeader
- type CanonicalProposal
- type CanonicalVote
- type ConsensusMessage
- type DefaultNodeInfo
- type DefaultNodeInfoOther
- type HasVoteMessage
- type NewRoundStepMessage
- type NewValidBlockMessage
- type P2PConnection
- type Packet
- type PacketMsg
- type PacketPing
- type PacketPong
- type Part
- type PartSetHeader
- type Proposal
- type ProposalMessage
- type ProposalPOLMessage
- type ProtocolVersion
- type TendermintHandler
- type Validator
- type Vote
- type VoteMessage
- type VoteSetBitsMessage
- type VoteSetMaj23Message
Constants ¶
This section is empty.
Variables ¶
var ServicedKeyFile string = "irisnet"
var ServicedTMCore chains.NodeType = chains.NodeType{Version: "0.32.2", Network: "irishub", ProtocolVersionApp: "2", ProtocolVersionBlock: "9", ProtocolVersionP2p: "5"}
ServicedTMCore is a string associated with each TM core handler to decipher which handler is to be attached.
Functions ¶
func GenerateKeyFile ¶
func GenerateKeyFile(fileLocation string)
func RegisterPacket ¶
func RunDataConnect ¶
func RunDataConnect(peerAddr string, marlinTo chan marlinTypes.MarlinMessage, marlinFrom chan marlinTypes.MarlinMessage, isConnectionOutgoing bool, keyFile string, listenPort int)
func RunSpamFilter ¶
func RunSpamFilter(rpcAddr string, marlinTo chan marlinTypes.MarlinMessage, marlinFrom chan marlinTypes.MarlinMessage)
RunSpamFilter serves as the entry point for a TM Core handler when serving as a spamfilter
func VerifyKeyFile ¶
Types ¶
type BitArray ¶
type BlockID ¶
type BlockID struct { Hash cmn.HexBytes `json:"hash"` PartsHeader PartSetHeader `json:"parts"` }
type BlockPartMessage ¶
BlockPartMessage is sent when gossipping a piece of the proposed block.
func (*BlockPartMessage) String ¶
func (m *BlockPartMessage) String() string
String returns a string representation.
func (*BlockPartMessage) ValidateBasic ¶
func (m *BlockPartMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type CanonicalBlockID ¶
type CanonicalBlockID struct { Hash cmn.HexBytes PartsHeader CanonicalPartSetHeader }
func CanonicalizeBlockID ¶
func CanonicalizeBlockID(blockID BlockID) CanonicalBlockID
type CanonicalPartSetHeader ¶
func CanonicalizePartSetHeader ¶
func CanonicalizePartSetHeader(psh PartSetHeader) CanonicalPartSetHeader
type CanonicalProposal ¶
type CanonicalProposal struct { Type byte // type alias for byte Height int64 `binary:"fixed64"` Round int64 `binary:"fixed64"` POLRound int64 `binary:"fixed64"` BlockID CanonicalBlockID Timestamp time.Time ChainID string }
func CanonicalizeProposal ¶
func CanonicalizeProposal(chainID string, proposal *Proposal) CanonicalProposal
type CanonicalVote ¶
type CanonicalVote struct { Type byte // type alias for byte Height int64 `binary:"fixed64"` Round int64 `binary:"fixed64"` BlockID CanonicalBlockID Timestamp time.Time ChainID string }
func CanonicalizeVote ¶
func CanonicalizeVote(chainID string, vote *Vote) CanonicalVote
type DefaultNodeInfo ¶
type DefaultNodeInfo struct { ProtocolVersion ProtocolVersion `json:"protocol_version"` ID_ string `json:"id"` // authenticated identifier ListenAddr string `json:"listen_addr"` // accepting incoming // Check compatibility. // Channels are HexBytes so easier to read as JSON Network string `json:"network"` // network/chain ID Version string `json:"version"` // major.minor.revision Channels cmn.HexBytes `json:"channels"` // channels this node knows about // ASCIIText fields Moniker string `json:"moniker"` // arbitrary moniker Other DefaultNodeInfoOther `json:"other"` // other application specific data }
type DefaultNodeInfoOther ¶
type DefaultNodeInfoOther struct { TxIndex string `json:"tx_index"` RPCAddress string `json:"rpc_address"` }
DefaultNodeInfoOther is the misc. applcation specific data
type HasVoteMessage ¶
func (*HasVoteMessage) String ¶
func (m *HasVoteMessage) String() string
String returns a string representation.
func (*HasVoteMessage) ValidateBasic ¶
func (m *HasVoteMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type NewRoundStepMessage ¶
type NewRoundStepMessage struct { Height int64 Round int Step uint8 SecondsSinceStartTime int LastCommitRound int }
NewRoundStepMessage is sent for every step taken in the ConsensusState. For every height/round/step transition
func (*NewRoundStepMessage) String ¶
func (m *NewRoundStepMessage) String() string
String returns a string representation.
func (*NewRoundStepMessage) ValidateBasic ¶
func (m *NewRoundStepMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type NewValidBlockMessage ¶
type NewValidBlockMessage struct { Height int64 Round int BlockPartsHeader PartSetHeader BlockParts BitArray IsCommit bool }
func (*NewValidBlockMessage) String ¶
func (m *NewValidBlockMessage) String() string
String returns a string representation.
func (*NewValidBlockMessage) ValidateBasic ¶
func (m *NewValidBlockMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type P2PConnection ¶
type P2PConnection struct {
// contains filtered or unexported fields
}
type PacketMsg ¶
func (PacketMsg) AssertIsPacket ¶
func (_ PacketMsg) AssertIsPacket()
type PacketPing ¶
type PacketPing struct { }
func (PacketPing) AssertIsPacket ¶
func (_ PacketPing) AssertIsPacket()
type PacketPong ¶
type PacketPong struct { }
func (PacketPong) AssertIsPacket ¶
func (_ PacketPong) AssertIsPacket()
type Part ¶
type Part struct { Index int `json:"index"` Bytes cmn.HexBytes `json:"bytes"` Proof merkle.SimpleProof `json:"proof"` // contains filtered or unexported fields }
type PartSetHeader ¶
NewValidBlockMessage is sent when a validator observes a valid block B in some round r, i.e., there is a Proposal for block B and 2/3+ prevotes for the block B in the round r. In case the block is also committed, then IsCommit flag is set to true.
type ProposalMessage ¶
type ProposalMessage struct {
Proposal Proposal
}
ProposalMessage is sent when a new block is proposed.
func (*ProposalMessage) String ¶
func (m *ProposalMessage) String() string
String returns a string representation.
func (*ProposalMessage) ValidateBasic ¶
func (m *ProposalMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type ProposalPOLMessage ¶
ProposalPOLMessage is sent when a previous proposal is re-proposed.
func (*ProposalPOLMessage) String ¶
func (m *ProposalPOLMessage) String() string
String returns a string representation.
func (*ProposalPOLMessage) ValidateBasic ¶
func (m *ProposalPOLMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type ProtocolVersion ¶
type TendermintHandler ¶
type TendermintHandler struct {
// contains filtered or unexported fields
}
type Validator ¶
type Validator struct { PublicKey ed25519.PubKeyEd25519 Address string }
type Vote ¶
type Vote struct { Type byte `json:"type"` Height int64 `json:"height"` Round int `json:"round"` BlockID BlockID `json:"block_id"` // zero if vote is nil. Timestamp time.Time `json:"timestamp"` ValidatorAddress cmn.HexBytes `json:"validator_address"` ValidatorIndex int `json:"validator_index"` Signature []byte `json:"signature"` }
Vote represents a prevote, precommit, or commit vote from validators for consensus.
type VoteMessage ¶
type VoteMessage struct {
Vote Vote
}
VoteMessage is sent when voting for a proposal (or lack thereof).
func (*VoteMessage) String ¶
func (m *VoteMessage) String() string
String returns a string representation.
func (*VoteMessage) ValidateBasic ¶
func (m *VoteMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type VoteSetBitsMessage ¶
type VoteSetBitsMessage struct { Height int64 Round int Type byte BlockID BlockID Votes *cmn.BitArray }
VoteSetBitsMessage is sent to communicate the bit-array of votes seen for the BlockID.
func (*VoteSetBitsMessage) String ¶
func (m *VoteSetBitsMessage) String() string
String returns a string representation.
func (*VoteSetBitsMessage) ValidateBasic ¶
func (m *VoteSetBitsMessage) ValidateBasic() error
ValidateBasic performs basic validation.
type VoteSetMaj23Message ¶
VoteSetMaj23Message is sent to indicate that a given BlockID has seen +2/3 votes.
func (*VoteSetMaj23Message) String ¶
func (m *VoteSetMaj23Message) String() string
String returns a string representation.
func (*VoteSetMaj23Message) ValidateBasic ¶
func (m *VoteSetMaj23Message) ValidateBasic() error
ValidateBasic performs basic validation.
Directories ¶
Path | Synopsis |
---|---|
libs
|
|
common
nolint
|
nolint |
errors
Package errors contains errors that are thrown across packages.
|
Package errors contains errors that are thrown across packages. |
events
Package events - Pub-Sub in go with event caching
|
Package events - Pub-Sub in go with event caching |
flowrate
Package flowrate provides the tools for monitoring and limiting the flow rate of an arbitrary data stream.
|
Package flowrate provides the tools for monitoring and limiting the flow rate of an arbitrary data stream. |
pubsub
Package pubsub implements a pub-sub model with a single publisher (Server) and multiple subscribers (clients).
|
Package pubsub implements a pub-sub model with a single publisher (Server) and multiple subscribers (clients). |
pubsub/query
Package query provides a parser for a custom query format: abci.invoice.number=22 AND abci.invoice.owner=Ivan See query.peg for the grammar, which is a https://en.wikipedia.org/wiki/Parsing_expression_grammar.
|
Package query provides a parser for a custom query format: abci.invoice.number=22 AND abci.invoice.owner=Ivan See query.peg for the grammar, which is a https://en.wikipedia.org/wiki/Parsing_expression_grammar. |