sentry

package
v0.0.0-...-1f8a15b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 12, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Sentry_SetStatus_FullMethodName                = "/sentry.Sentry/SetStatus"
	Sentry_PenalizePeer_FullMethodName             = "/sentry.Sentry/PenalizePeer"
	Sentry_PeerMinBlock_FullMethodName             = "/sentry.Sentry/PeerMinBlock"
	Sentry_HandShake_FullMethodName                = "/sentry.Sentry/HandShake"
	Sentry_SendMessageByMinBlock_FullMethodName    = "/sentry.Sentry/SendMessageByMinBlock"
	Sentry_SendMessageById_FullMethodName          = "/sentry.Sentry/SendMessageById"
	Sentry_SendMessageToRandomPeers_FullMethodName = "/sentry.Sentry/SendMessageToRandomPeers"
	Sentry_SendMessageToAll_FullMethodName         = "/sentry.Sentry/SendMessageToAll"
	Sentry_Messages_FullMethodName                 = "/sentry.Sentry/Messages"
	Sentry_Peers_FullMethodName                    = "/sentry.Sentry/Peers"
	Sentry_PeerCount_FullMethodName                = "/sentry.Sentry/PeerCount"
	Sentry_PeerById_FullMethodName                 = "/sentry.Sentry/PeerById"
	Sentry_PeerEvents_FullMethodName               = "/sentry.Sentry/PeerEvents"
	Sentry_AddPeer_FullMethodName                  = "/sentry.Sentry/AddPeer"
	Sentry_NodeInfo_FullMethodName                 = "/sentry.Sentry/NodeInfo"
)

Variables

View Source
var (
	MessageId_name = map[int32]string{
		0:  "STATUS_65",
		1:  "GET_BLOCK_HEADERS_65",
		2:  "BLOCK_HEADERS_65",
		3:  "BLOCK_HASHES_65",
		4:  "GET_BLOCK_BODIES_65",
		5:  "BLOCK_BODIES_65",
		6:  "GET_NODE_DATA_65",
		7:  "NODE_DATA_65",
		8:  "GET_RECEIPTS_65",
		9:  "RECEIPTS_65",
		10: "NEW_BLOCK_HASHES_65",
		11: "NEW_BLOCK_65",
		12: "TRANSACTIONS_65",
		13: "NEW_POOLED_TRANSACTION_HASHES_65",
		14: "GET_POOLED_TRANSACTIONS_65",
		15: "POOLED_TRANSACTIONS_65",
		17: "STATUS_66",
		18: "NEW_BLOCK_HASHES_66",
		19: "NEW_BLOCK_66",
		20: "TRANSACTIONS_66",
		21: "NEW_POOLED_TRANSACTION_HASHES_66",
		22: "GET_BLOCK_HEADERS_66",
		23: "GET_BLOCK_BODIES_66",
		24: "GET_NODE_DATA_66",
		25: "GET_RECEIPTS_66",
		26: "GET_POOLED_TRANSACTIONS_66",
		27: "BLOCK_HEADERS_66",
		28: "BLOCK_BODIES_66",
		29: "NODE_DATA_66",
		30: "RECEIPTS_66",
		31: "POOLED_TRANSACTIONS_66",
		32: "NEW_POOLED_TRANSACTION_HASHES_68",
	}
	MessageId_value = map[string]int32{
		"STATUS_65":                        0,
		"GET_BLOCK_HEADERS_65":             1,
		"BLOCK_HEADERS_65":                 2,
		"BLOCK_HASHES_65":                  3,
		"GET_BLOCK_BODIES_65":              4,
		"BLOCK_BODIES_65":                  5,
		"GET_NODE_DATA_65":                 6,
		"NODE_DATA_65":                     7,
		"GET_RECEIPTS_65":                  8,
		"RECEIPTS_65":                      9,
		"NEW_BLOCK_HASHES_65":              10,
		"NEW_BLOCK_65":                     11,
		"TRANSACTIONS_65":                  12,
		"NEW_POOLED_TRANSACTION_HASHES_65": 13,
		"GET_POOLED_TRANSACTIONS_65":       14,
		"POOLED_TRANSACTIONS_65":           15,
		"STATUS_66":                        17,
		"NEW_BLOCK_HASHES_66":              18,
		"NEW_BLOCK_66":                     19,
		"TRANSACTIONS_66":                  20,
		"NEW_POOLED_TRANSACTION_HASHES_66": 21,
		"GET_BLOCK_HEADERS_66":             22,
		"GET_BLOCK_BODIES_66":              23,
		"GET_NODE_DATA_66":                 24,
		"GET_RECEIPTS_66":                  25,
		"GET_POOLED_TRANSACTIONS_66":       26,
		"BLOCK_HEADERS_66":                 27,
		"BLOCK_BODIES_66":                  28,
		"NODE_DATA_66":                     29,
		"RECEIPTS_66":                      30,
		"POOLED_TRANSACTIONS_66":           31,
		"NEW_POOLED_TRANSACTION_HASHES_68": 32,
	}
)

Enum value maps for MessageId.

View Source
var (
	PenaltyKind_name = map[int32]string{
		0: "Kick",
	}
	PenaltyKind_value = map[string]int32{
		"Kick": 0,
	}
)

Enum value maps for PenaltyKind.

View Source
var (
	Protocol_name = map[int32]string{
		0: "ETH65",
		1: "ETH66",
		2: "ETH67",
		3: "ETH68",
	}
	Protocol_value = map[string]int32{
		"ETH65": 0,
		"ETH66": 1,
		"ETH67": 2,
		"ETH68": 3,
	}
)

Enum value maps for Protocol.

View Source
var (
	PeerEvent_PeerEventId_name = map[int32]string{
		0: "Connect",
		1: "Disconnect",
	}
	PeerEvent_PeerEventId_value = map[string]int32{
		"Connect":    0,
		"Disconnect": 1,
	}
)

Enum value maps for PeerEvent_PeerEventId.

View Source
var File_p2psentry_sentry_proto protoreflect.FileDescriptor
View Source
var Sentry_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "sentry.Sentry",
	HandlerType: (*SentryServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SetStatus",
			Handler:    _Sentry_SetStatus_Handler,
		},
		{
			MethodName: "PenalizePeer",
			Handler:    _Sentry_PenalizePeer_Handler,
		},
		{
			MethodName: "PeerMinBlock",
			Handler:    _Sentry_PeerMinBlock_Handler,
		},
		{
			MethodName: "HandShake",
			Handler:    _Sentry_HandShake_Handler,
		},
		{
			MethodName: "SendMessageByMinBlock",
			Handler:    _Sentry_SendMessageByMinBlock_Handler,
		},
		{
			MethodName: "SendMessageById",
			Handler:    _Sentry_SendMessageById_Handler,
		},
		{
			MethodName: "SendMessageToRandomPeers",
			Handler:    _Sentry_SendMessageToRandomPeers_Handler,
		},
		{
			MethodName: "SendMessageToAll",
			Handler:    _Sentry_SendMessageToAll_Handler,
		},
		{
			MethodName: "Peers",
			Handler:    _Sentry_Peers_Handler,
		},
		{
			MethodName: "PeerCount",
			Handler:    _Sentry_PeerCount_Handler,
		},
		{
			MethodName: "PeerById",
			Handler:    _Sentry_PeerById_Handler,
		},
		{
			MethodName: "AddPeer",
			Handler:    _Sentry_AddPeer_Handler,
		},
		{
			MethodName: "NodeInfo",
			Handler:    _Sentry_NodeInfo_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Messages",
			Handler:       _Sentry_Messages_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "PeerEvents",
			Handler:       _Sentry_PeerEvents_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "p2psentry/sentry.proto",
}

Sentry_ServiceDesc is the grpc.ServiceDesc for Sentry service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterSentryServer

func RegisterSentryServer(s grpc.ServiceRegistrar, srv SentryServer)

Types

type AddPeerReply

type AddPeerReply struct {
	Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
	// contains filtered or unexported fields
}

func (*AddPeerReply) Descriptor deprecated

func (*AddPeerReply) Descriptor() ([]byte, []int)

Deprecated: Use AddPeerReply.ProtoReflect.Descriptor instead.

func (*AddPeerReply) GetSuccess

func (x *AddPeerReply) GetSuccess() bool

func (*AddPeerReply) ProtoMessage

func (*AddPeerReply) ProtoMessage()

func (*AddPeerReply) ProtoReflect

func (x *AddPeerReply) ProtoReflect() protoreflect.Message

func (*AddPeerReply) Reset

func (x *AddPeerReply) Reset()

func (*AddPeerReply) String

func (x *AddPeerReply) String() string

type AddPeerRequest

type AddPeerRequest struct {
	Url string `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"`
	// contains filtered or unexported fields
}

func (*AddPeerRequest) Descriptor deprecated

func (*AddPeerRequest) Descriptor() ([]byte, []int)

Deprecated: Use AddPeerRequest.ProtoReflect.Descriptor instead.

func (*AddPeerRequest) GetUrl

func (x *AddPeerRequest) GetUrl() string

func (*AddPeerRequest) ProtoMessage

func (*AddPeerRequest) ProtoMessage()

func (*AddPeerRequest) ProtoReflect

func (x *AddPeerRequest) ProtoReflect() protoreflect.Message

func (*AddPeerRequest) Reset

func (x *AddPeerRequest) Reset()

func (*AddPeerRequest) String

func (x *AddPeerRequest) String() string

type Forks

type Forks struct {
	Genesis     *types.H256 `protobuf:"bytes,1,opt,name=genesis,proto3" json:"genesis,omitempty"`
	HeightForks []uint64    `protobuf:"varint,2,rep,packed,name=height_forks,json=heightForks,proto3" json:"height_forks,omitempty"`
	TimeForks   []uint64    `protobuf:"varint,3,rep,packed,name=time_forks,json=timeForks,proto3" json:"time_forks,omitempty"`
	// contains filtered or unexported fields
}

func (*Forks) Descriptor deprecated

func (*Forks) Descriptor() ([]byte, []int)

Deprecated: Use Forks.ProtoReflect.Descriptor instead.

func (*Forks) GetGenesis

func (x *Forks) GetGenesis() *types.H256

func (*Forks) GetHeightForks

func (x *Forks) GetHeightForks() []uint64

func (*Forks) GetTimeForks

func (x *Forks) GetTimeForks() []uint64

func (*Forks) ProtoMessage

func (*Forks) ProtoMessage()

func (*Forks) ProtoReflect

func (x *Forks) ProtoReflect() protoreflect.Message

func (*Forks) Reset

func (x *Forks) Reset()

func (*Forks) String

func (x *Forks) String() string

type HandShakeReply

type HandShakeReply struct {
	Protocol Protocol `protobuf:"varint,1,opt,name=protocol,proto3,enum=sentry.Protocol" json:"protocol,omitempty"`
	// contains filtered or unexported fields
}

func (*HandShakeReply) Descriptor deprecated

func (*HandShakeReply) Descriptor() ([]byte, []int)

Deprecated: Use HandShakeReply.ProtoReflect.Descriptor instead.

func (*HandShakeReply) GetProtocol

func (x *HandShakeReply) GetProtocol() Protocol

func (*HandShakeReply) ProtoMessage

func (*HandShakeReply) ProtoMessage()

func (*HandShakeReply) ProtoReflect

func (x *HandShakeReply) ProtoReflect() protoreflect.Message

func (*HandShakeReply) Reset

func (x *HandShakeReply) Reset()

func (*HandShakeReply) String

func (x *HandShakeReply) String() string

type InboundMessage

type InboundMessage struct {
	Id     MessageId   `protobuf:"varint,1,opt,name=id,proto3,enum=sentry.MessageId" json:"id,omitempty"`
	Data   []byte      `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
	PeerId *types.H512 `protobuf:"bytes,3,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
	// contains filtered or unexported fields
}

func (*InboundMessage) Descriptor deprecated

func (*InboundMessage) Descriptor() ([]byte, []int)

Deprecated: Use InboundMessage.ProtoReflect.Descriptor instead.

func (*InboundMessage) GetData

func (x *InboundMessage) GetData() []byte

func (*InboundMessage) GetId

func (x *InboundMessage) GetId() MessageId

func (*InboundMessage) GetPeerId

func (x *InboundMessage) GetPeerId() *types.H512

func (*InboundMessage) ProtoMessage

func (*InboundMessage) ProtoMessage()

func (*InboundMessage) ProtoReflect

func (x *InboundMessage) ProtoReflect() protoreflect.Message

func (*InboundMessage) Reset

func (x *InboundMessage) Reset()

func (*InboundMessage) String

func (x *InboundMessage) String() string

type MessageId

type MessageId int32
const (
	MessageId_STATUS_65                        MessageId = 0
	MessageId_GET_BLOCK_HEADERS_65             MessageId = 1
	MessageId_BLOCK_HEADERS_65                 MessageId = 2
	MessageId_BLOCK_HASHES_65                  MessageId = 3
	MessageId_GET_BLOCK_BODIES_65              MessageId = 4
	MessageId_BLOCK_BODIES_65                  MessageId = 5
	MessageId_GET_NODE_DATA_65                 MessageId = 6
	MessageId_NODE_DATA_65                     MessageId = 7
	MessageId_GET_RECEIPTS_65                  MessageId = 8
	MessageId_RECEIPTS_65                      MessageId = 9
	MessageId_NEW_BLOCK_HASHES_65              MessageId = 10
	MessageId_NEW_BLOCK_65                     MessageId = 11
	MessageId_TRANSACTIONS_65                  MessageId = 12
	MessageId_NEW_POOLED_TRANSACTION_HASHES_65 MessageId = 13
	MessageId_GET_POOLED_TRANSACTIONS_65       MessageId = 14
	MessageId_POOLED_TRANSACTIONS_65           MessageId = 15
	// eth64 announcement messages (no id)
	MessageId_STATUS_66           MessageId = 17
	MessageId_NEW_BLOCK_HASHES_66 MessageId = 18
	MessageId_NEW_BLOCK_66        MessageId = 19
	MessageId_TRANSACTIONS_66     MessageId = 20
	// eth65 announcement messages (no id)
	MessageId_NEW_POOLED_TRANSACTION_HASHES_66 MessageId = 21
	// eth66 messages with request-id
	MessageId_GET_BLOCK_HEADERS_66       MessageId = 22
	MessageId_GET_BLOCK_BODIES_66        MessageId = 23
	MessageId_GET_NODE_DATA_66           MessageId = 24
	MessageId_GET_RECEIPTS_66            MessageId = 25
	MessageId_GET_POOLED_TRANSACTIONS_66 MessageId = 26
	MessageId_BLOCK_HEADERS_66           MessageId = 27
	MessageId_BLOCK_BODIES_66            MessageId = 28
	MessageId_NODE_DATA_66               MessageId = 29
	MessageId_RECEIPTS_66                MessageId = 30
	MessageId_POOLED_TRANSACTIONS_66     MessageId = 31
	// ======= eth 68 protocol ===========
	MessageId_NEW_POOLED_TRANSACTION_HASHES_68 MessageId = 32
)

func (MessageId) Descriptor

func (MessageId) Descriptor() protoreflect.EnumDescriptor

func (MessageId) Enum

func (x MessageId) Enum() *MessageId

func (MessageId) EnumDescriptor deprecated

func (MessageId) EnumDescriptor() ([]byte, []int)

Deprecated: Use MessageId.Descriptor instead.

func (MessageId) Number

func (x MessageId) Number() protoreflect.EnumNumber

func (MessageId) String

func (x MessageId) String() string

func (MessageId) Type

type MessagesRequest

type MessagesRequest struct {
	Ids []MessageId `protobuf:"varint,1,rep,packed,name=ids,proto3,enum=sentry.MessageId" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

func (*MessagesRequest) Descriptor deprecated

func (*MessagesRequest) Descriptor() ([]byte, []int)

Deprecated: Use MessagesRequest.ProtoReflect.Descriptor instead.

func (*MessagesRequest) GetIds

func (x *MessagesRequest) GetIds() []MessageId

func (*MessagesRequest) ProtoMessage

func (*MessagesRequest) ProtoMessage()

func (*MessagesRequest) ProtoReflect

func (x *MessagesRequest) ProtoReflect() protoreflect.Message

func (*MessagesRequest) Reset

func (x *MessagesRequest) Reset()

func (*MessagesRequest) String

func (x *MessagesRequest) String() string

type OutboundMessageData

type OutboundMessageData struct {
	Id   MessageId `protobuf:"varint,1,opt,name=id,proto3,enum=sentry.MessageId" json:"id,omitempty"`
	Data []byte    `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*OutboundMessageData) Descriptor deprecated

func (*OutboundMessageData) Descriptor() ([]byte, []int)

Deprecated: Use OutboundMessageData.ProtoReflect.Descriptor instead.

func (*OutboundMessageData) GetData

func (x *OutboundMessageData) GetData() []byte

func (*OutboundMessageData) GetId

func (x *OutboundMessageData) GetId() MessageId

func (*OutboundMessageData) ProtoMessage

func (*OutboundMessageData) ProtoMessage()

func (*OutboundMessageData) ProtoReflect

func (x *OutboundMessageData) ProtoReflect() protoreflect.Message

func (*OutboundMessageData) Reset

func (x *OutboundMessageData) Reset()

func (*OutboundMessageData) String

func (x *OutboundMessageData) String() string

type PeerByIdReply

type PeerByIdReply struct {
	Peer *types.PeerInfo `protobuf:"bytes,1,opt,name=peer,proto3,oneof" json:"peer,omitempty"`
	// contains filtered or unexported fields
}

func (*PeerByIdReply) Descriptor deprecated

func (*PeerByIdReply) Descriptor() ([]byte, []int)

Deprecated: Use PeerByIdReply.ProtoReflect.Descriptor instead.

func (*PeerByIdReply) GetPeer

func (x *PeerByIdReply) GetPeer() *types.PeerInfo

func (*PeerByIdReply) ProtoMessage

func (*PeerByIdReply) ProtoMessage()

func (*PeerByIdReply) ProtoReflect

func (x *PeerByIdReply) ProtoReflect() protoreflect.Message

func (*PeerByIdReply) Reset

func (x *PeerByIdReply) Reset()

func (*PeerByIdReply) String

func (x *PeerByIdReply) String() string

type PeerByIdRequest

type PeerByIdRequest struct {
	PeerId *types.H512 `protobuf:"bytes,1,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
	// contains filtered or unexported fields
}

func (*PeerByIdRequest) Descriptor deprecated

func (*PeerByIdRequest) Descriptor() ([]byte, []int)

Deprecated: Use PeerByIdRequest.ProtoReflect.Descriptor instead.

func (*PeerByIdRequest) GetPeerId

func (x *PeerByIdRequest) GetPeerId() *types.H512

func (*PeerByIdRequest) ProtoMessage

func (*PeerByIdRequest) ProtoMessage()

func (*PeerByIdRequest) ProtoReflect

func (x *PeerByIdRequest) ProtoReflect() protoreflect.Message

func (*PeerByIdRequest) Reset

func (x *PeerByIdRequest) Reset()

func (*PeerByIdRequest) String

func (x *PeerByIdRequest) String() string

type PeerCountPerProtocol

type PeerCountPerProtocol struct {
	Protocol Protocol `protobuf:"varint,1,opt,name=protocol,proto3,enum=sentry.Protocol" json:"protocol,omitempty"`
	Count    uint64   `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
	// contains filtered or unexported fields
}

func (*PeerCountPerProtocol) Descriptor deprecated

func (*PeerCountPerProtocol) Descriptor() ([]byte, []int)

Deprecated: Use PeerCountPerProtocol.ProtoReflect.Descriptor instead.

func (*PeerCountPerProtocol) GetCount

func (x *PeerCountPerProtocol) GetCount() uint64

func (*PeerCountPerProtocol) GetProtocol

func (x *PeerCountPerProtocol) GetProtocol() Protocol

func (*PeerCountPerProtocol) ProtoMessage

func (*PeerCountPerProtocol) ProtoMessage()

func (*PeerCountPerProtocol) ProtoReflect

func (x *PeerCountPerProtocol) ProtoReflect() protoreflect.Message

func (*PeerCountPerProtocol) Reset

func (x *PeerCountPerProtocol) Reset()

func (*PeerCountPerProtocol) String

func (x *PeerCountPerProtocol) String() string

type PeerCountReply

type PeerCountReply struct {
	Count             uint64                  `protobuf:"varint,1,opt,name=count,proto3" json:"count,omitempty"`
	CountsPerProtocol []*PeerCountPerProtocol `protobuf:"bytes,2,rep,name=counts_per_protocol,json=countsPerProtocol,proto3" json:"counts_per_protocol,omitempty"`
	// contains filtered or unexported fields
}

func (*PeerCountReply) Descriptor deprecated

func (*PeerCountReply) Descriptor() ([]byte, []int)

Deprecated: Use PeerCountReply.ProtoReflect.Descriptor instead.

func (*PeerCountReply) GetCount

func (x *PeerCountReply) GetCount() uint64

func (*PeerCountReply) GetCountsPerProtocol

func (x *PeerCountReply) GetCountsPerProtocol() []*PeerCountPerProtocol

func (*PeerCountReply) ProtoMessage

func (*PeerCountReply) ProtoMessage()

func (*PeerCountReply) ProtoReflect

func (x *PeerCountReply) ProtoReflect() protoreflect.Message

func (*PeerCountReply) Reset

func (x *PeerCountReply) Reset()

func (*PeerCountReply) String

func (x *PeerCountReply) String() string

type PeerCountRequest

type PeerCountRequest struct {
	// contains filtered or unexported fields
}

func (*PeerCountRequest) Descriptor deprecated

func (*PeerCountRequest) Descriptor() ([]byte, []int)

Deprecated: Use PeerCountRequest.ProtoReflect.Descriptor instead.

func (*PeerCountRequest) ProtoMessage

func (*PeerCountRequest) ProtoMessage()

func (*PeerCountRequest) ProtoReflect

func (x *PeerCountRequest) ProtoReflect() protoreflect.Message

func (*PeerCountRequest) Reset

func (x *PeerCountRequest) Reset()

func (*PeerCountRequest) String

func (x *PeerCountRequest) String() string

type PeerEvent

type PeerEvent struct {
	PeerId  *types.H512           `protobuf:"bytes,1,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
	EventId PeerEvent_PeerEventId `protobuf:"varint,2,opt,name=event_id,json=eventId,proto3,enum=sentry.PeerEvent_PeerEventId" json:"event_id,omitempty"`
	// contains filtered or unexported fields
}

func (*PeerEvent) Descriptor deprecated

func (*PeerEvent) Descriptor() ([]byte, []int)

Deprecated: Use PeerEvent.ProtoReflect.Descriptor instead.

func (*PeerEvent) GetEventId

func (x *PeerEvent) GetEventId() PeerEvent_PeerEventId

func (*PeerEvent) GetPeerId

func (x *PeerEvent) GetPeerId() *types.H512

func (*PeerEvent) ProtoMessage

func (*PeerEvent) ProtoMessage()

func (*PeerEvent) ProtoReflect

func (x *PeerEvent) ProtoReflect() protoreflect.Message

func (*PeerEvent) Reset

func (x *PeerEvent) Reset()

func (*PeerEvent) String

func (x *PeerEvent) String() string

type PeerEvent_PeerEventId

type PeerEvent_PeerEventId int32
const (
	// Happens after after a successful sub-protocol handshake.
	PeerEvent_Connect    PeerEvent_PeerEventId = 0
	PeerEvent_Disconnect PeerEvent_PeerEventId = 1
)

func (PeerEvent_PeerEventId) Descriptor

func (PeerEvent_PeerEventId) Enum

func (PeerEvent_PeerEventId) EnumDescriptor deprecated

func (PeerEvent_PeerEventId) EnumDescriptor() ([]byte, []int)

Deprecated: Use PeerEvent_PeerEventId.Descriptor instead.

func (PeerEvent_PeerEventId) Number

func (PeerEvent_PeerEventId) String

func (x PeerEvent_PeerEventId) String() string

func (PeerEvent_PeerEventId) Type

type PeerEventsRequest

type PeerEventsRequest struct {
	// contains filtered or unexported fields
}

func (*PeerEventsRequest) Descriptor deprecated

func (*PeerEventsRequest) Descriptor() ([]byte, []int)

Deprecated: Use PeerEventsRequest.ProtoReflect.Descriptor instead.

func (*PeerEventsRequest) ProtoMessage

func (*PeerEventsRequest) ProtoMessage()

func (*PeerEventsRequest) ProtoReflect

func (x *PeerEventsRequest) ProtoReflect() protoreflect.Message

func (*PeerEventsRequest) Reset

func (x *PeerEventsRequest) Reset()

func (*PeerEventsRequest) String

func (x *PeerEventsRequest) String() string

type PeerMinBlockRequest

type PeerMinBlockRequest struct {
	PeerId   *types.H512 `protobuf:"bytes,1,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
	MinBlock uint64      `protobuf:"varint,2,opt,name=min_block,json=minBlock,proto3" json:"min_block,omitempty"`
	// contains filtered or unexported fields
}

func (*PeerMinBlockRequest) Descriptor deprecated

func (*PeerMinBlockRequest) Descriptor() ([]byte, []int)

Deprecated: Use PeerMinBlockRequest.ProtoReflect.Descriptor instead.

func (*PeerMinBlockRequest) GetMinBlock

func (x *PeerMinBlockRequest) GetMinBlock() uint64

func (*PeerMinBlockRequest) GetPeerId

func (x *PeerMinBlockRequest) GetPeerId() *types.H512

func (*PeerMinBlockRequest) ProtoMessage

func (*PeerMinBlockRequest) ProtoMessage()

func (*PeerMinBlockRequest) ProtoReflect

func (x *PeerMinBlockRequest) ProtoReflect() protoreflect.Message

func (*PeerMinBlockRequest) Reset

func (x *PeerMinBlockRequest) Reset()

func (*PeerMinBlockRequest) String

func (x *PeerMinBlockRequest) String() string

type PeersReply

type PeersReply struct {
	Peers []*types.PeerInfo `protobuf:"bytes,1,rep,name=peers,proto3" json:"peers,omitempty"`
	// contains filtered or unexported fields
}

func (*PeersReply) Descriptor deprecated

func (*PeersReply) Descriptor() ([]byte, []int)

Deprecated: Use PeersReply.ProtoReflect.Descriptor instead.

func (*PeersReply) GetPeers

func (x *PeersReply) GetPeers() []*types.PeerInfo

func (*PeersReply) ProtoMessage

func (*PeersReply) ProtoMessage()

func (*PeersReply) ProtoReflect

func (x *PeersReply) ProtoReflect() protoreflect.Message

func (*PeersReply) Reset

func (x *PeersReply) Reset()

func (*PeersReply) String

func (x *PeersReply) String() string

type PenalizePeerRequest

type PenalizePeerRequest struct {
	PeerId  *types.H512 `protobuf:"bytes,1,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
	Penalty PenaltyKind `protobuf:"varint,2,opt,name=penalty,proto3,enum=sentry.PenaltyKind" json:"penalty,omitempty"`
	// contains filtered or unexported fields
}

func (*PenalizePeerRequest) Descriptor deprecated

func (*PenalizePeerRequest) Descriptor() ([]byte, []int)

Deprecated: Use PenalizePeerRequest.ProtoReflect.Descriptor instead.

func (*PenalizePeerRequest) GetPeerId

func (x *PenalizePeerRequest) GetPeerId() *types.H512

func (*PenalizePeerRequest) GetPenalty

func (x *PenalizePeerRequest) GetPenalty() PenaltyKind

func (*PenalizePeerRequest) ProtoMessage

func (*PenalizePeerRequest) ProtoMessage()

func (*PenalizePeerRequest) ProtoReflect

func (x *PenalizePeerRequest) ProtoReflect() protoreflect.Message

func (*PenalizePeerRequest) Reset

func (x *PenalizePeerRequest) Reset()

func (*PenalizePeerRequest) String

func (x *PenalizePeerRequest) String() string

type PenaltyKind

type PenaltyKind int32
const (
	PenaltyKind_Kick PenaltyKind = 0
)

func (PenaltyKind) Descriptor

func (PenaltyKind) Enum

func (x PenaltyKind) Enum() *PenaltyKind

func (PenaltyKind) EnumDescriptor deprecated

func (PenaltyKind) EnumDescriptor() ([]byte, []int)

Deprecated: Use PenaltyKind.Descriptor instead.

func (PenaltyKind) Number

func (x PenaltyKind) Number() protoreflect.EnumNumber

func (PenaltyKind) String

func (x PenaltyKind) String() string

func (PenaltyKind) Type

type Protocol

type Protocol int32
const (
	Protocol_ETH65 Protocol = 0
	Protocol_ETH66 Protocol = 1
	Protocol_ETH67 Protocol = 2
	Protocol_ETH68 Protocol = 3
)

func (Protocol) Descriptor

func (Protocol) Descriptor() protoreflect.EnumDescriptor

func (Protocol) Enum

func (x Protocol) Enum() *Protocol

func (Protocol) EnumDescriptor deprecated

func (Protocol) EnumDescriptor() ([]byte, []int)

Deprecated: Use Protocol.Descriptor instead.

func (Protocol) Number

func (x Protocol) Number() protoreflect.EnumNumber

func (Protocol) String

func (x Protocol) String() string

func (Protocol) Type

type SendMessageByIdRequest

type SendMessageByIdRequest struct {
	Data   *OutboundMessageData `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	PeerId *types.H512          `protobuf:"bytes,2,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"`
	// contains filtered or unexported fields
}

func (*SendMessageByIdRequest) Descriptor deprecated

func (*SendMessageByIdRequest) Descriptor() ([]byte, []int)

Deprecated: Use SendMessageByIdRequest.ProtoReflect.Descriptor instead.

func (*SendMessageByIdRequest) GetData

func (*SendMessageByIdRequest) GetPeerId

func (x *SendMessageByIdRequest) GetPeerId() *types.H512

func (*SendMessageByIdRequest) ProtoMessage

func (*SendMessageByIdRequest) ProtoMessage()

func (*SendMessageByIdRequest) ProtoReflect

func (x *SendMessageByIdRequest) ProtoReflect() protoreflect.Message

func (*SendMessageByIdRequest) Reset

func (x *SendMessageByIdRequest) Reset()

func (*SendMessageByIdRequest) String

func (x *SendMessageByIdRequest) String() string

type SendMessageByMinBlockRequest

type SendMessageByMinBlockRequest struct {
	Data     *OutboundMessageData `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	MinBlock uint64               `protobuf:"varint,2,opt,name=min_block,json=minBlock,proto3" json:"min_block,omitempty"`
	MaxPeers uint64               `protobuf:"varint,3,opt,name=max_peers,json=maxPeers,proto3" json:"max_peers,omitempty"`
	// contains filtered or unexported fields
}

func (*SendMessageByMinBlockRequest) Descriptor deprecated

func (*SendMessageByMinBlockRequest) Descriptor() ([]byte, []int)

Deprecated: Use SendMessageByMinBlockRequest.ProtoReflect.Descriptor instead.

func (*SendMessageByMinBlockRequest) GetData

func (*SendMessageByMinBlockRequest) GetMaxPeers

func (x *SendMessageByMinBlockRequest) GetMaxPeers() uint64

func (*SendMessageByMinBlockRequest) GetMinBlock

func (x *SendMessageByMinBlockRequest) GetMinBlock() uint64

func (*SendMessageByMinBlockRequest) ProtoMessage

func (*SendMessageByMinBlockRequest) ProtoMessage()

func (*SendMessageByMinBlockRequest) ProtoReflect

func (*SendMessageByMinBlockRequest) Reset

func (x *SendMessageByMinBlockRequest) Reset()

func (*SendMessageByMinBlockRequest) String

type SendMessageToRandomPeersRequest

type SendMessageToRandomPeersRequest struct {
	Data     *OutboundMessageData `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	MaxPeers uint64               `protobuf:"varint,2,opt,name=max_peers,json=maxPeers,proto3" json:"max_peers,omitempty"`
	// contains filtered or unexported fields
}

func (*SendMessageToRandomPeersRequest) Descriptor deprecated

func (*SendMessageToRandomPeersRequest) Descriptor() ([]byte, []int)

Deprecated: Use SendMessageToRandomPeersRequest.ProtoReflect.Descriptor instead.

func (*SendMessageToRandomPeersRequest) GetData

func (*SendMessageToRandomPeersRequest) GetMaxPeers

func (x *SendMessageToRandomPeersRequest) GetMaxPeers() uint64

func (*SendMessageToRandomPeersRequest) ProtoMessage

func (*SendMessageToRandomPeersRequest) ProtoMessage()

func (*SendMessageToRandomPeersRequest) ProtoReflect

func (*SendMessageToRandomPeersRequest) Reset

func (*SendMessageToRandomPeersRequest) String

type SentPeers

type SentPeers struct {
	Peers []*types.H512 `protobuf:"bytes,1,rep,name=peers,proto3" json:"peers,omitempty"`
	// contains filtered or unexported fields
}

func (*SentPeers) Descriptor deprecated

func (*SentPeers) Descriptor() ([]byte, []int)

Deprecated: Use SentPeers.ProtoReflect.Descriptor instead.

func (*SentPeers) GetPeers

func (x *SentPeers) GetPeers() []*types.H512

func (*SentPeers) ProtoMessage

func (*SentPeers) ProtoMessage()

func (*SentPeers) ProtoReflect

func (x *SentPeers) ProtoReflect() protoreflect.Message

func (*SentPeers) Reset

func (x *SentPeers) Reset()

func (*SentPeers) String

func (x *SentPeers) String() string

type SentryClient

type SentryClient interface {
	// SetStatus - force new ETH client state of sentry - network_id, max_block, etc...
	SetStatus(ctx context.Context, in *StatusData, opts ...grpc.CallOption) (*SetStatusReply, error)
	PenalizePeer(ctx context.Context, in *PenalizePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	PeerMinBlock(ctx context.Context, in *PeerMinBlockRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// HandShake - pre-requirement for all Send* methods - returns list of ETH protocol versions,
	// without knowledge of protocol - impossible encode correct P2P message
	HandShake(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*HandShakeReply, error)
	SendMessageByMinBlock(ctx context.Context, in *SendMessageByMinBlockRequest, opts ...grpc.CallOption) (*SentPeers, error)
	SendMessageById(ctx context.Context, in *SendMessageByIdRequest, opts ...grpc.CallOption) (*SentPeers, error)
	SendMessageToRandomPeers(ctx context.Context, in *SendMessageToRandomPeersRequest, opts ...grpc.CallOption) (*SentPeers, error)
	SendMessageToAll(ctx context.Context, in *OutboundMessageData, opts ...grpc.CallOption) (*SentPeers, error)
	// Subscribe to receive messages.
	// Calling multiple times with a different set of ids starts separate streams.
	// It is possible to subscribe to the same set if ids more than once.
	Messages(ctx context.Context, in *MessagesRequest, opts ...grpc.CallOption) (Sentry_MessagesClient, error)
	Peers(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*PeersReply, error)
	PeerCount(ctx context.Context, in *PeerCountRequest, opts ...grpc.CallOption) (*PeerCountReply, error)
	PeerById(ctx context.Context, in *PeerByIdRequest, opts ...grpc.CallOption) (*PeerByIdReply, error)
	// Subscribe to notifications about connected or lost peers.
	PeerEvents(ctx context.Context, in *PeerEventsRequest, opts ...grpc.CallOption) (Sentry_PeerEventsClient, error)
	AddPeer(ctx context.Context, in *AddPeerRequest, opts ...grpc.CallOption) (*AddPeerReply, error)
	// NodeInfo returns a collection of metadata known about the host.
	NodeInfo(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*types.NodeInfoReply, error)
}

SentryClient is the client API for Sentry service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewSentryClient

func NewSentryClient(cc grpc.ClientConnInterface) SentryClient

type SentryClientMock

type SentryClientMock struct {
	// AddPeerFunc mocks the AddPeer method.
	AddPeerFunc func(ctx context.Context, in *AddPeerRequest, opts ...grpc.CallOption) (*AddPeerReply, error)

	// HandShakeFunc mocks the HandShake method.
	HandShakeFunc func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*HandShakeReply, error)

	// MessagesFunc mocks the Messages method.
	MessagesFunc func(ctx context.Context, in *MessagesRequest, opts ...grpc.CallOption) (Sentry_MessagesClient, error)

	// NodeInfoFunc mocks the NodeInfo method.
	NodeInfoFunc func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*types.NodeInfoReply, error)

	// PeerByIdFunc mocks the PeerById method.
	PeerByIdFunc func(ctx context.Context, in *PeerByIdRequest, opts ...grpc.CallOption) (*PeerByIdReply, error)

	// PeerCountFunc mocks the PeerCount method.
	PeerCountFunc func(ctx context.Context, in *PeerCountRequest, opts ...grpc.CallOption) (*PeerCountReply, error)

	// PeerEventsFunc mocks the PeerEvents method.
	PeerEventsFunc func(ctx context.Context, in *PeerEventsRequest, opts ...grpc.CallOption) (Sentry_PeerEventsClient, error)

	// PeerMinBlockFunc mocks the PeerMinBlock method.
	PeerMinBlockFunc func(ctx context.Context, in *PeerMinBlockRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)

	// PeersFunc mocks the Peers method.
	PeersFunc func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*PeersReply, error)

	// PenalizePeerFunc mocks the PenalizePeer method.
	PenalizePeerFunc func(ctx context.Context, in *PenalizePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)

	// SendMessageByIdFunc mocks the SendMessageById method.
	SendMessageByIdFunc func(ctx context.Context, in *SendMessageByIdRequest, opts ...grpc.CallOption) (*SentPeers, error)

	// SendMessageByMinBlockFunc mocks the SendMessageByMinBlock method.
	SendMessageByMinBlockFunc func(ctx context.Context, in *SendMessageByMinBlockRequest, opts ...grpc.CallOption) (*SentPeers, error)

	// SendMessageToAllFunc mocks the SendMessageToAll method.
	SendMessageToAllFunc func(ctx context.Context, in *OutboundMessageData, opts ...grpc.CallOption) (*SentPeers, error)

	// SendMessageToRandomPeersFunc mocks the SendMessageToRandomPeers method.
	SendMessageToRandomPeersFunc func(ctx context.Context, in *SendMessageToRandomPeersRequest, opts ...grpc.CallOption) (*SentPeers, error)

	// SetStatusFunc mocks the SetStatus method.
	SetStatusFunc func(ctx context.Context, in *StatusData, opts ...grpc.CallOption) (*SetStatusReply, error)
	// contains filtered or unexported fields
}

SentryClientMock is a mock implementation of SentryClient.

func TestSomethingThatUsesSentryClient(t *testing.T) {

	// make and configure a mocked SentryClient
	mockedSentryClient := &SentryClientMock{
		AddPeerFunc: func(ctx context.Context, in *AddPeerRequest, opts ...grpc.CallOption) (*AddPeerReply, error) {
			panic("mock out the AddPeer method")
		},
		HandShakeFunc: func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*HandShakeReply, error) {
			panic("mock out the HandShake method")
		},
		MessagesFunc: func(ctx context.Context, in *MessagesRequest, opts ...grpc.CallOption) (Sentry_MessagesClient, error) {
			panic("mock out the Messages method")
		},
		NodeInfoFunc: func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*types.NodeInfoReply, error) {
			panic("mock out the NodeInfo method")
		},
		PeerByIdFunc: func(ctx context.Context, in *PeerByIdRequest, opts ...grpc.CallOption) (*PeerByIdReply, error) {
			panic("mock out the PeerById method")
		},
		PeerCountFunc: func(ctx context.Context, in *PeerCountRequest, opts ...grpc.CallOption) (*PeerCountReply, error) {
			panic("mock out the PeerCount method")
		},
		PeerEventsFunc: func(ctx context.Context, in *PeerEventsRequest, opts ...grpc.CallOption) (Sentry_PeerEventsClient, error) {
			panic("mock out the PeerEvents method")
		},
		PeerMinBlockFunc: func(ctx context.Context, in *PeerMinBlockRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
			panic("mock out the PeerMinBlock method")
		},
		PeersFunc: func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*PeersReply, error) {
			panic("mock out the Peers method")
		},
		PenalizePeerFunc: func(ctx context.Context, in *PenalizePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
			panic("mock out the PenalizePeer method")
		},
		SendMessageByIdFunc: func(ctx context.Context, in *SendMessageByIdRequest, opts ...grpc.CallOption) (*SentPeers, error) {
			panic("mock out the SendMessageById method")
		},
		SendMessageByMinBlockFunc: func(ctx context.Context, in *SendMessageByMinBlockRequest, opts ...grpc.CallOption) (*SentPeers, error) {
			panic("mock out the SendMessageByMinBlock method")
		},
		SendMessageToAllFunc: func(ctx context.Context, in *OutboundMessageData, opts ...grpc.CallOption) (*SentPeers, error) {
			panic("mock out the SendMessageToAll method")
		},
		SendMessageToRandomPeersFunc: func(ctx context.Context, in *SendMessageToRandomPeersRequest, opts ...grpc.CallOption) (*SentPeers, error) {
			panic("mock out the SendMessageToRandomPeers method")
		},
		SetStatusFunc: func(ctx context.Context, in *StatusData, opts ...grpc.CallOption) (*SetStatusReply, error) {
			panic("mock out the SetStatus method")
		},
	}

	// use mockedSentryClient in code that requires SentryClient
	// and then make assertions.

}

func (*SentryClientMock) AddPeer

func (mock *SentryClientMock) AddPeer(ctx context.Context, in *AddPeerRequest, opts ...grpc.CallOption) (*AddPeerReply, error)

AddPeer calls AddPeerFunc.

func (*SentryClientMock) AddPeerCalls

func (mock *SentryClientMock) AddPeerCalls() []struct {
	Ctx  context.Context
	In   *AddPeerRequest
	Opts []grpc.CallOption
}

AddPeerCalls gets all the calls that were made to AddPeer. Check the length with:

len(mockedSentryClient.AddPeerCalls())

func (*SentryClientMock) HandShake

func (mock *SentryClientMock) HandShake(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*HandShakeReply, error)

HandShake calls HandShakeFunc.

func (*SentryClientMock) HandShakeCalls

func (mock *SentryClientMock) HandShakeCalls() []struct {
	Ctx  context.Context
	In   *emptypb.Empty
	Opts []grpc.CallOption
}

HandShakeCalls gets all the calls that were made to HandShake. Check the length with:

len(mockedSentryClient.HandShakeCalls())

func (*SentryClientMock) Messages

Messages calls MessagesFunc.

func (*SentryClientMock) MessagesCalls

func (mock *SentryClientMock) MessagesCalls() []struct {
	Ctx  context.Context
	In   *MessagesRequest
	Opts []grpc.CallOption
}

MessagesCalls gets all the calls that were made to Messages. Check the length with:

len(mockedSentryClient.MessagesCalls())

func (*SentryClientMock) NodeInfo

func (mock *SentryClientMock) NodeInfo(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*types.NodeInfoReply, error)

NodeInfo calls NodeInfoFunc.

func (*SentryClientMock) NodeInfoCalls

func (mock *SentryClientMock) NodeInfoCalls() []struct {
	Ctx  context.Context
	In   *emptypb.Empty
	Opts []grpc.CallOption
}

NodeInfoCalls gets all the calls that were made to NodeInfo. Check the length with:

len(mockedSentryClient.NodeInfoCalls())

func (*SentryClientMock) PeerById

func (mock *SentryClientMock) PeerById(ctx context.Context, in *PeerByIdRequest, opts ...grpc.CallOption) (*PeerByIdReply, error)

PeerById calls PeerByIdFunc.

func (*SentryClientMock) PeerByIdCalls

func (mock *SentryClientMock) PeerByIdCalls() []struct {
	Ctx  context.Context
	In   *PeerByIdRequest
	Opts []grpc.CallOption
}

PeerByIdCalls gets all the calls that were made to PeerById. Check the length with:

len(mockedSentryClient.PeerByIdCalls())

func (*SentryClientMock) PeerCount

func (mock *SentryClientMock) PeerCount(ctx context.Context, in *PeerCountRequest, opts ...grpc.CallOption) (*PeerCountReply, error)

PeerCount calls PeerCountFunc.

func (*SentryClientMock) PeerCountCalls

func (mock *SentryClientMock) PeerCountCalls() []struct {
	Ctx  context.Context
	In   *PeerCountRequest
	Opts []grpc.CallOption
}

PeerCountCalls gets all the calls that were made to PeerCount. Check the length with:

len(mockedSentryClient.PeerCountCalls())

func (*SentryClientMock) PeerEvents

PeerEvents calls PeerEventsFunc.

func (*SentryClientMock) PeerEventsCalls

func (mock *SentryClientMock) PeerEventsCalls() []struct {
	Ctx  context.Context
	In   *PeerEventsRequest
	Opts []grpc.CallOption
}

PeerEventsCalls gets all the calls that were made to PeerEvents. Check the length with:

len(mockedSentryClient.PeerEventsCalls())

func (*SentryClientMock) PeerMinBlock

func (mock *SentryClientMock) PeerMinBlock(ctx context.Context, in *PeerMinBlockRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)

PeerMinBlock calls PeerMinBlockFunc.

func (*SentryClientMock) PeerMinBlockCalls

func (mock *SentryClientMock) PeerMinBlockCalls() []struct {
	Ctx  context.Context
	In   *PeerMinBlockRequest
	Opts []grpc.CallOption
}

PeerMinBlockCalls gets all the calls that were made to PeerMinBlock. Check the length with:

len(mockedSentryClient.PeerMinBlockCalls())

func (*SentryClientMock) Peers

func (mock *SentryClientMock) Peers(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*PeersReply, error)

Peers calls PeersFunc.

func (*SentryClientMock) PeersCalls

func (mock *SentryClientMock) PeersCalls() []struct {
	Ctx  context.Context
	In   *emptypb.Empty
	Opts []grpc.CallOption
}

PeersCalls gets all the calls that were made to Peers. Check the length with:

len(mockedSentryClient.PeersCalls())

func (*SentryClientMock) PenalizePeer

func (mock *SentryClientMock) PenalizePeer(ctx context.Context, in *PenalizePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)

PenalizePeer calls PenalizePeerFunc.

func (*SentryClientMock) PenalizePeerCalls

func (mock *SentryClientMock) PenalizePeerCalls() []struct {
	Ctx  context.Context
	In   *PenalizePeerRequest
	Opts []grpc.CallOption
}

PenalizePeerCalls gets all the calls that were made to PenalizePeer. Check the length with:

len(mockedSentryClient.PenalizePeerCalls())

func (*SentryClientMock) SendMessageById

func (mock *SentryClientMock) SendMessageById(ctx context.Context, in *SendMessageByIdRequest, opts ...grpc.CallOption) (*SentPeers, error)

SendMessageById calls SendMessageByIdFunc.

func (*SentryClientMock) SendMessageByIdCalls

func (mock *SentryClientMock) SendMessageByIdCalls() []struct {
	Ctx  context.Context
	In   *SendMessageByIdRequest
	Opts []grpc.CallOption
}

SendMessageByIdCalls gets all the calls that were made to SendMessageById. Check the length with:

len(mockedSentryClient.SendMessageByIdCalls())

func (*SentryClientMock) SendMessageByMinBlock

func (mock *SentryClientMock) SendMessageByMinBlock(ctx context.Context, in *SendMessageByMinBlockRequest, opts ...grpc.CallOption) (*SentPeers, error)

SendMessageByMinBlock calls SendMessageByMinBlockFunc.

func (*SentryClientMock) SendMessageByMinBlockCalls

func (mock *SentryClientMock) SendMessageByMinBlockCalls() []struct {
	Ctx  context.Context
	In   *SendMessageByMinBlockRequest
	Opts []grpc.CallOption
}

SendMessageByMinBlockCalls gets all the calls that were made to SendMessageByMinBlock. Check the length with:

len(mockedSentryClient.SendMessageByMinBlockCalls())

func (*SentryClientMock) SendMessageToAll

func (mock *SentryClientMock) SendMessageToAll(ctx context.Context, in *OutboundMessageData, opts ...grpc.CallOption) (*SentPeers, error)

SendMessageToAll calls SendMessageToAllFunc.

func (*SentryClientMock) SendMessageToAllCalls

func (mock *SentryClientMock) SendMessageToAllCalls() []struct {
	Ctx  context.Context
	In   *OutboundMessageData
	Opts []grpc.CallOption
}

SendMessageToAllCalls gets all the calls that were made to SendMessageToAll. Check the length with:

len(mockedSentryClient.SendMessageToAllCalls())

func (*SentryClientMock) SendMessageToRandomPeers

func (mock *SentryClientMock) SendMessageToRandomPeers(ctx context.Context, in *SendMessageToRandomPeersRequest, opts ...grpc.CallOption) (*SentPeers, error)

SendMessageToRandomPeers calls SendMessageToRandomPeersFunc.

func (*SentryClientMock) SendMessageToRandomPeersCalls

func (mock *SentryClientMock) SendMessageToRandomPeersCalls() []struct {
	Ctx  context.Context
	In   *SendMessageToRandomPeersRequest
	Opts []grpc.CallOption
}

SendMessageToRandomPeersCalls gets all the calls that were made to SendMessageToRandomPeers. Check the length with:

len(mockedSentryClient.SendMessageToRandomPeersCalls())

func (*SentryClientMock) SetStatus

func (mock *SentryClientMock) SetStatus(ctx context.Context, in *StatusData, opts ...grpc.CallOption) (*SetStatusReply, error)

SetStatus calls SetStatusFunc.

func (*SentryClientMock) SetStatusCalls

func (mock *SentryClientMock) SetStatusCalls() []struct {
	Ctx  context.Context
	In   *StatusData
	Opts []grpc.CallOption
}

SetStatusCalls gets all the calls that were made to SetStatus. Check the length with:

len(mockedSentryClient.SetStatusCalls())

type SentryServer

type SentryServer interface {
	// SetStatus - force new ETH client state of sentry - network_id, max_block, etc...
	SetStatus(context.Context, *StatusData) (*SetStatusReply, error)
	PenalizePeer(context.Context, *PenalizePeerRequest) (*emptypb.Empty, error)
	PeerMinBlock(context.Context, *PeerMinBlockRequest) (*emptypb.Empty, error)
	// HandShake - pre-requirement for all Send* methods - returns list of ETH protocol versions,
	// without knowledge of protocol - impossible encode correct P2P message
	HandShake(context.Context, *emptypb.Empty) (*HandShakeReply, error)
	SendMessageByMinBlock(context.Context, *SendMessageByMinBlockRequest) (*SentPeers, error)
	SendMessageById(context.Context, *SendMessageByIdRequest) (*SentPeers, error)
	SendMessageToRandomPeers(context.Context, *SendMessageToRandomPeersRequest) (*SentPeers, error)
	SendMessageToAll(context.Context, *OutboundMessageData) (*SentPeers, error)
	// Subscribe to receive messages.
	// Calling multiple times with a different set of ids starts separate streams.
	// It is possible to subscribe to the same set if ids more than once.
	Messages(*MessagesRequest, Sentry_MessagesServer) error
	Peers(context.Context, *emptypb.Empty) (*PeersReply, error)
	PeerCount(context.Context, *PeerCountRequest) (*PeerCountReply, error)
	PeerById(context.Context, *PeerByIdRequest) (*PeerByIdReply, error)
	// Subscribe to notifications about connected or lost peers.
	PeerEvents(*PeerEventsRequest, Sentry_PeerEventsServer) error
	AddPeer(context.Context, *AddPeerRequest) (*AddPeerReply, error)
	// NodeInfo returns a collection of metadata known about the host.
	NodeInfo(context.Context, *emptypb.Empty) (*types.NodeInfoReply, error)
	// contains filtered or unexported methods
}

SentryServer is the server API for Sentry service. All implementations must embed UnimplementedSentryServer for forward compatibility

type SentryServerMock

type SentryServerMock struct {
	// AddPeerFunc mocks the AddPeer method.
	AddPeerFunc func(contextMoqParam context.Context, addPeerRequest *AddPeerRequest) (*AddPeerReply, error)

	// HandShakeFunc mocks the HandShake method.
	HandShakeFunc func(contextMoqParam context.Context, empty *emptypb.Empty) (*HandShakeReply, error)

	// MessagesFunc mocks the Messages method.
	MessagesFunc func(messagesRequest *MessagesRequest, sentry_MessagesServer Sentry_MessagesServer) error

	// NodeInfoFunc mocks the NodeInfo method.
	NodeInfoFunc func(contextMoqParam context.Context, empty *emptypb.Empty) (*types.NodeInfoReply, error)

	// PeerByIdFunc mocks the PeerById method.
	PeerByIdFunc func(contextMoqParam context.Context, peerByIdRequest *PeerByIdRequest) (*PeerByIdReply, error)

	// PeerCountFunc mocks the PeerCount method.
	PeerCountFunc func(contextMoqParam context.Context, peerCountRequest *PeerCountRequest) (*PeerCountReply, error)

	// PeerEventsFunc mocks the PeerEvents method.
	PeerEventsFunc func(peerEventsRequest *PeerEventsRequest, sentry_PeerEventsServer Sentry_PeerEventsServer) error

	// PeerMinBlockFunc mocks the PeerMinBlock method.
	PeerMinBlockFunc func(contextMoqParam context.Context, peerMinBlockRequest *PeerMinBlockRequest) (*emptypb.Empty, error)

	// PeersFunc mocks the Peers method.
	PeersFunc func(contextMoqParam context.Context, empty *emptypb.Empty) (*PeersReply, error)

	// PenalizePeerFunc mocks the PenalizePeer method.
	PenalizePeerFunc func(contextMoqParam context.Context, penalizePeerRequest *PenalizePeerRequest) (*emptypb.Empty, error)

	// SendMessageByIdFunc mocks the SendMessageById method.
	SendMessageByIdFunc func(contextMoqParam context.Context, sendMessageByIdRequest *SendMessageByIdRequest) (*SentPeers, error)

	// SendMessageByMinBlockFunc mocks the SendMessageByMinBlock method.
	SendMessageByMinBlockFunc func(contextMoqParam context.Context, sendMessageByMinBlockRequest *SendMessageByMinBlockRequest) (*SentPeers, error)

	// SendMessageToAllFunc mocks the SendMessageToAll method.
	SendMessageToAllFunc func(contextMoqParam context.Context, outboundMessageData *OutboundMessageData) (*SentPeers, error)

	// SendMessageToRandomPeersFunc mocks the SendMessageToRandomPeers method.
	SendMessageToRandomPeersFunc func(contextMoqParam context.Context, sendMessageToRandomPeersRequest *SendMessageToRandomPeersRequest) (*SentPeers, error)

	// SetStatusFunc mocks the SetStatus method.
	SetStatusFunc func(contextMoqParam context.Context, statusData *StatusData) (*SetStatusReply, error)
	// contains filtered or unexported fields
}

SentryServerMock is a mock implementation of SentryServer.

func TestSomethingThatUsesSentryServer(t *testing.T) {

	// make and configure a mocked SentryServer
	mockedSentryServer := &SentryServerMock{
		AddPeerFunc: func(contextMoqParam context.Context, addPeerRequest *AddPeerRequest) (*AddPeerReply, error) {
			panic("mock out the AddPeer method")
		},
		HandShakeFunc: func(contextMoqParam context.Context, empty *emptypb.Empty) (*HandShakeReply, error) {
			panic("mock out the HandShake method")
		},
		MessagesFunc: func(messagesRequest *MessagesRequest, sentry_MessagesServer Sentry_MessagesServer) error {
			panic("mock out the Messages method")
		},
		NodeInfoFunc: func(contextMoqParam context.Context, empty *emptypb.Empty) (*types.NodeInfoReply, error) {
			panic("mock out the NodeInfo method")
		},
		PeerByIdFunc: func(contextMoqParam context.Context, peerByIdRequest *PeerByIdRequest) (*PeerByIdReply, error) {
			panic("mock out the PeerById method")
		},
		PeerCountFunc: func(contextMoqParam context.Context, peerCountRequest *PeerCountRequest) (*PeerCountReply, error) {
			panic("mock out the PeerCount method")
		},
		PeerEventsFunc: func(peerEventsRequest *PeerEventsRequest, sentry_PeerEventsServer Sentry_PeerEventsServer) error {
			panic("mock out the PeerEvents method")
		},
		PeerMinBlockFunc: func(contextMoqParam context.Context, peerMinBlockRequest *PeerMinBlockRequest) (*emptypb.Empty, error) {
			panic("mock out the PeerMinBlock method")
		},
		PeersFunc: func(contextMoqParam context.Context, empty *emptypb.Empty) (*PeersReply, error) {
			panic("mock out the Peers method")
		},
		PenalizePeerFunc: func(contextMoqParam context.Context, penalizePeerRequest *PenalizePeerRequest) (*emptypb.Empty, error) {
			panic("mock out the PenalizePeer method")
		},
		SendMessageByIdFunc: func(contextMoqParam context.Context, sendMessageByIdRequest *SendMessageByIdRequest) (*SentPeers, error) {
			panic("mock out the SendMessageById method")
		},
		SendMessageByMinBlockFunc: func(contextMoqParam context.Context, sendMessageByMinBlockRequest *SendMessageByMinBlockRequest) (*SentPeers, error) {
			panic("mock out the SendMessageByMinBlock method")
		},
		SendMessageToAllFunc: func(contextMoqParam context.Context, outboundMessageData *OutboundMessageData) (*SentPeers, error) {
			panic("mock out the SendMessageToAll method")
		},
		SendMessageToRandomPeersFunc: func(contextMoqParam context.Context, sendMessageToRandomPeersRequest *SendMessageToRandomPeersRequest) (*SentPeers, error) {
			panic("mock out the SendMessageToRandomPeers method")
		},
		SetStatusFunc: func(contextMoqParam context.Context, statusData *StatusData) (*SetStatusReply, error) {
			panic("mock out the SetStatus method")
		},
		mustEmbedUnimplementedSentryServerFunc: func()  {
			panic("mock out the mustEmbedUnimplementedSentryServer method")
		},
	}

	// use mockedSentryServer in code that requires SentryServer
	// and then make assertions.

}

func (*SentryServerMock) AddPeer

func (mock *SentryServerMock) AddPeer(contextMoqParam context.Context, addPeerRequest *AddPeerRequest) (*AddPeerReply, error)

AddPeer calls AddPeerFunc.

func (*SentryServerMock) AddPeerCalls

func (mock *SentryServerMock) AddPeerCalls() []struct {
	ContextMoqParam context.Context
	AddPeerRequest  *AddPeerRequest
}

AddPeerCalls gets all the calls that were made to AddPeer. Check the length with:

len(mockedSentryServer.AddPeerCalls())

func (*SentryServerMock) HandShake

func (mock *SentryServerMock) HandShake(contextMoqParam context.Context, empty *emptypb.Empty) (*HandShakeReply, error)

HandShake calls HandShakeFunc.

func (*SentryServerMock) HandShakeCalls

func (mock *SentryServerMock) HandShakeCalls() []struct {
	ContextMoqParam context.Context
	Empty           *emptypb.Empty
}

HandShakeCalls gets all the calls that were made to HandShake. Check the length with:

len(mockedSentryServer.HandShakeCalls())

func (*SentryServerMock) Messages

func (mock *SentryServerMock) Messages(messagesRequest *MessagesRequest, sentry_MessagesServer Sentry_MessagesServer) error

Messages calls MessagesFunc.

func (*SentryServerMock) MessagesCalls

func (mock *SentryServerMock) MessagesCalls() []struct {
	MessagesRequest       *MessagesRequest
	Sentry_MessagesServer Sentry_MessagesServer
}

MessagesCalls gets all the calls that were made to Messages. Check the length with:

len(mockedSentryServer.MessagesCalls())

func (*SentryServerMock) NodeInfo

func (mock *SentryServerMock) NodeInfo(contextMoqParam context.Context, empty *emptypb.Empty) (*types.NodeInfoReply, error)

NodeInfo calls NodeInfoFunc.

func (*SentryServerMock) NodeInfoCalls

func (mock *SentryServerMock) NodeInfoCalls() []struct {
	ContextMoqParam context.Context
	Empty           *emptypb.Empty
}

NodeInfoCalls gets all the calls that were made to NodeInfo. Check the length with:

len(mockedSentryServer.NodeInfoCalls())

func (*SentryServerMock) PeerById

func (mock *SentryServerMock) PeerById(contextMoqParam context.Context, peerByIdRequest *PeerByIdRequest) (*PeerByIdReply, error)

PeerById calls PeerByIdFunc.

func (*SentryServerMock) PeerByIdCalls

func (mock *SentryServerMock) PeerByIdCalls() []struct {
	ContextMoqParam context.Context
	PeerByIdRequest *PeerByIdRequest
}

PeerByIdCalls gets all the calls that were made to PeerById. Check the length with:

len(mockedSentryServer.PeerByIdCalls())

func (*SentryServerMock) PeerCount

func (mock *SentryServerMock) PeerCount(contextMoqParam context.Context, peerCountRequest *PeerCountRequest) (*PeerCountReply, error)

PeerCount calls PeerCountFunc.

func (*SentryServerMock) PeerCountCalls

func (mock *SentryServerMock) PeerCountCalls() []struct {
	ContextMoqParam  context.Context
	PeerCountRequest *PeerCountRequest
}

PeerCountCalls gets all the calls that were made to PeerCount. Check the length with:

len(mockedSentryServer.PeerCountCalls())

func (*SentryServerMock) PeerEvents

func (mock *SentryServerMock) PeerEvents(peerEventsRequest *PeerEventsRequest, sentry_PeerEventsServer Sentry_PeerEventsServer) error

PeerEvents calls PeerEventsFunc.

func (*SentryServerMock) PeerEventsCalls

func (mock *SentryServerMock) PeerEventsCalls() []struct {
	PeerEventsRequest       *PeerEventsRequest
	Sentry_PeerEventsServer Sentry_PeerEventsServer
}

PeerEventsCalls gets all the calls that were made to PeerEvents. Check the length with:

len(mockedSentryServer.PeerEventsCalls())

func (*SentryServerMock) PeerMinBlock

func (mock *SentryServerMock) PeerMinBlock(contextMoqParam context.Context, peerMinBlockRequest *PeerMinBlockRequest) (*emptypb.Empty, error)

PeerMinBlock calls PeerMinBlockFunc.

func (*SentryServerMock) PeerMinBlockCalls

func (mock *SentryServerMock) PeerMinBlockCalls() []struct {
	ContextMoqParam     context.Context
	PeerMinBlockRequest *PeerMinBlockRequest
}

PeerMinBlockCalls gets all the calls that were made to PeerMinBlock. Check the length with:

len(mockedSentryServer.PeerMinBlockCalls())

func (*SentryServerMock) Peers

func (mock *SentryServerMock) Peers(contextMoqParam context.Context, empty *emptypb.Empty) (*PeersReply, error)

Peers calls PeersFunc.

func (*SentryServerMock) PeersCalls

func (mock *SentryServerMock) PeersCalls() []struct {
	ContextMoqParam context.Context
	Empty           *emptypb.Empty
}

PeersCalls gets all the calls that were made to Peers. Check the length with:

len(mockedSentryServer.PeersCalls())

func (*SentryServerMock) PenalizePeer

func (mock *SentryServerMock) PenalizePeer(contextMoqParam context.Context, penalizePeerRequest *PenalizePeerRequest) (*emptypb.Empty, error)

PenalizePeer calls PenalizePeerFunc.

func (*SentryServerMock) PenalizePeerCalls

func (mock *SentryServerMock) PenalizePeerCalls() []struct {
	ContextMoqParam     context.Context
	PenalizePeerRequest *PenalizePeerRequest
}

PenalizePeerCalls gets all the calls that were made to PenalizePeer. Check the length with:

len(mockedSentryServer.PenalizePeerCalls())

func (*SentryServerMock) SendMessageById

func (mock *SentryServerMock) SendMessageById(contextMoqParam context.Context, sendMessageByIdRequest *SendMessageByIdRequest) (*SentPeers, error)

SendMessageById calls SendMessageByIdFunc.

func (*SentryServerMock) SendMessageByIdCalls

func (mock *SentryServerMock) SendMessageByIdCalls() []struct {
	ContextMoqParam        context.Context
	SendMessageByIdRequest *SendMessageByIdRequest
}

SendMessageByIdCalls gets all the calls that were made to SendMessageById. Check the length with:

len(mockedSentryServer.SendMessageByIdCalls())

func (*SentryServerMock) SendMessageByMinBlock

func (mock *SentryServerMock) SendMessageByMinBlock(contextMoqParam context.Context, sendMessageByMinBlockRequest *SendMessageByMinBlockRequest) (*SentPeers, error)

SendMessageByMinBlock calls SendMessageByMinBlockFunc.

func (*SentryServerMock) SendMessageByMinBlockCalls

func (mock *SentryServerMock) SendMessageByMinBlockCalls() []struct {
	ContextMoqParam              context.Context
	SendMessageByMinBlockRequest *SendMessageByMinBlockRequest
}

SendMessageByMinBlockCalls gets all the calls that were made to SendMessageByMinBlock. Check the length with:

len(mockedSentryServer.SendMessageByMinBlockCalls())

func (*SentryServerMock) SendMessageToAll

func (mock *SentryServerMock) SendMessageToAll(contextMoqParam context.Context, outboundMessageData *OutboundMessageData) (*SentPeers, error)

SendMessageToAll calls SendMessageToAllFunc.

func (*SentryServerMock) SendMessageToAllCalls

func (mock *SentryServerMock) SendMessageToAllCalls() []struct {
	ContextMoqParam     context.Context
	OutboundMessageData *OutboundMessageData
}

SendMessageToAllCalls gets all the calls that were made to SendMessageToAll. Check the length with:

len(mockedSentryServer.SendMessageToAllCalls())

func (*SentryServerMock) SendMessageToRandomPeers

func (mock *SentryServerMock) SendMessageToRandomPeers(contextMoqParam context.Context, sendMessageToRandomPeersRequest *SendMessageToRandomPeersRequest) (*SentPeers, error)

SendMessageToRandomPeers calls SendMessageToRandomPeersFunc.

func (*SentryServerMock) SendMessageToRandomPeersCalls

func (mock *SentryServerMock) SendMessageToRandomPeersCalls() []struct {
	ContextMoqParam                 context.Context
	SendMessageToRandomPeersRequest *SendMessageToRandomPeersRequest
}

SendMessageToRandomPeersCalls gets all the calls that were made to SendMessageToRandomPeers. Check the length with:

len(mockedSentryServer.SendMessageToRandomPeersCalls())

func (*SentryServerMock) SetStatus

func (mock *SentryServerMock) SetStatus(contextMoqParam context.Context, statusData *StatusData) (*SetStatusReply, error)

SetStatus calls SetStatusFunc.

func (*SentryServerMock) SetStatusCalls

func (mock *SentryServerMock) SetStatusCalls() []struct {
	ContextMoqParam context.Context
	StatusData      *StatusData
}

SetStatusCalls gets all the calls that were made to SetStatus. Check the length with:

len(mockedSentryServer.SetStatusCalls())

type Sentry_MessagesClient

type Sentry_MessagesClient interface {
	Recv() (*InboundMessage, error)
	grpc.ClientStream
}

type Sentry_MessagesServer

type Sentry_MessagesServer interface {
	Send(*InboundMessage) error
	grpc.ServerStream
}

type Sentry_PeerEventsClient

type Sentry_PeerEventsClient interface {
	Recv() (*PeerEvent, error)
	grpc.ClientStream
}

type Sentry_PeerEventsServer

type Sentry_PeerEventsServer interface {
	Send(*PeerEvent) error
	grpc.ServerStream
}

type SetStatusReply

type SetStatusReply struct {
	// contains filtered or unexported fields
}

func (*SetStatusReply) Descriptor deprecated

func (*SetStatusReply) Descriptor() ([]byte, []int)

Deprecated: Use SetStatusReply.ProtoReflect.Descriptor instead.

func (*SetStatusReply) ProtoMessage

func (*SetStatusReply) ProtoMessage()

func (*SetStatusReply) ProtoReflect

func (x *SetStatusReply) ProtoReflect() protoreflect.Message

func (*SetStatusReply) Reset

func (x *SetStatusReply) Reset()

func (*SetStatusReply) String

func (x *SetStatusReply) String() string

type StatusData

type StatusData struct {
	NetworkId       uint64      `protobuf:"varint,1,opt,name=network_id,json=networkId,proto3" json:"network_id,omitempty"`
	TotalDifficulty *types.H256 `protobuf:"bytes,2,opt,name=total_difficulty,json=totalDifficulty,proto3" json:"total_difficulty,omitempty"`
	BestHash        *types.H256 `protobuf:"bytes,3,opt,name=best_hash,json=bestHash,proto3" json:"best_hash,omitempty"`
	ForkData        *Forks      `protobuf:"bytes,4,opt,name=fork_data,json=forkData,proto3" json:"fork_data,omitempty"`
	MaxBlockHeight  uint64      `protobuf:"varint,5,opt,name=max_block_height,json=maxBlockHeight,proto3" json:"max_block_height,omitempty"`
	MaxBlockTime    uint64      `protobuf:"varint,6,opt,name=max_block_time,json=maxBlockTime,proto3" json:"max_block_time,omitempty"`
	// contains filtered or unexported fields
}

func (*StatusData) Descriptor deprecated

func (*StatusData) Descriptor() ([]byte, []int)

Deprecated: Use StatusData.ProtoReflect.Descriptor instead.

func (*StatusData) GetBestHash

func (x *StatusData) GetBestHash() *types.H256

func (*StatusData) GetForkData

func (x *StatusData) GetForkData() *Forks

func (*StatusData) GetMaxBlockHeight

func (x *StatusData) GetMaxBlockHeight() uint64

func (*StatusData) GetMaxBlockTime

func (x *StatusData) GetMaxBlockTime() uint64

func (*StatusData) GetNetworkId

func (x *StatusData) GetNetworkId() uint64

func (*StatusData) GetTotalDifficulty

func (x *StatusData) GetTotalDifficulty() *types.H256

func (*StatusData) ProtoMessage

func (*StatusData) ProtoMessage()

func (*StatusData) ProtoReflect

func (x *StatusData) ProtoReflect() protoreflect.Message

func (*StatusData) Reset

func (x *StatusData) Reset()

func (*StatusData) String

func (x *StatusData) String() string

type UnimplementedSentryServer

type UnimplementedSentryServer struct {
}

UnimplementedSentryServer must be embedded to have forward compatible implementations.

func (UnimplementedSentryServer) AddPeer

func (UnimplementedSentryServer) HandShake

func (UnimplementedSentryServer) Messages

func (UnimplementedSentryServer) NodeInfo

func (UnimplementedSentryServer) PeerById

func (UnimplementedSentryServer) PeerCount

func (UnimplementedSentryServer) PeerEvents

func (UnimplementedSentryServer) PeerMinBlock

func (UnimplementedSentryServer) Peers

func (UnimplementedSentryServer) PenalizePeer

func (UnimplementedSentryServer) SendMessageById

func (UnimplementedSentryServer) SendMessageByMinBlock

func (UnimplementedSentryServer) SendMessageToAll

func (UnimplementedSentryServer) SendMessageToRandomPeers

func (UnimplementedSentryServer) SetStatus

type UnsafeSentryServer

type UnsafeSentryServer interface {
	// contains filtered or unexported methods
}

UnsafeSentryServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to SentryServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL