Documentation ¶
Index ¶
- func DoCheck(slackApi *slack.Client, channel string, ips []string)
- func DoPing(ips []string)
- func DoVersionCheck(slackApi *slack.Client, channel string, ips []string)
- func InitSlack(token string) *slack.Client
- func PostMessage(slackAPI *slack.Client, message string, channel string)
- func PostOddNodesReport(slackAPI *slack.Client, channel string, nodes OddNodes)
- func PostVersionMismatchReport(slackAPI *slack.Client, channel string, nodes MismatchVeresionNodes)
- func ReadChannels(slackAPI *slack.Client)
- type Check
- type MismatchVeresionNodes
- type OddNodes
- type Ping
- type VersionCheck
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DoVersionCheck ¶
DoVersionCheck - check version/protocol versions of nodes
func PostMessage ¶
PostMessage - sends a message to Slack channel
func PostOddNodesReport ¶
PostOddNodesReport - posts report containing all nodes with differences in blockchain status
func PostVersionMismatchReport ¶
func PostVersionMismatchReport(slackAPI *slack.Client, channel string, nodes MismatchVeresionNodes)
PostVersionMismatchReport - posts report containing all nodes with differences daemon or protocol version
func ReadChannels ¶
ReadChannels - get Slack channels list
Types ¶
type Check ¶
type Check struct {
// contains filtered or unexported fields
}
Check - blockchain status check payload
type MismatchVeresionNodes ¶
type MismatchVeresionNodes struct { RespondedWithError []string HaveDifferentVersions map[int64][]string HaveDifferentProtocolVersions map[int64][]string NewestVersion int64 NewestProtocolVersion int64 }
MismatchVeresionNodes - datatype for storing info about nodes with mismatches in version/protocol version
type OddNodes ¶
type OddNodes struct { RespondedWithError []string HeadersAndBlocksDontMatch []string HaveDifferentNumberOfHeaders map[int32][]string HaveDifferentNumberOfBlocks map[int32][]string HaveDifferentDifficulty map[float64][]string HaveDifferentChainwork map[string][]string HaveDifferentBestBlockHash map[string][]string }
OddNodes - datatype for storing info about nodes with mismatches in blockchain state
type VersionCheck ¶
type VersionCheck struct {
// contains filtered or unexported fields
}
VersionCheck - version check payload
Click to show internal directories.
Click to hide internal directories.