servicenetwork

package
v0.0.0-...-05bc493 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2023 License: MIT Imports: 37 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthWatermillmessage        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowWatermillmessage          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupWatermillmessage = fmt.Errorf("proto: unexpected end of group")
)

Functions

This section is empty.

Types

type ServiceNetwork

type ServiceNetwork struct {

	// dependencies
	CertificateManager nodeinfo.CertificateManager `inject:""`

	// subcomponents
	RPC                controller.RPCController   `inject:"subcomponent"`
	NodeKeeper         beat.NodeKeeper            `inject:"subcomponent"`
	TerminationHandler network.TerminationHandler `inject:"subcomponent"`

	HostNetwork network.HostNetwork

	Gatewayer   network.Gatewayer
	BaseGateway *gateway.Base
	// contains filtered or unexported fields
}

func NewServiceNetwork

func NewServiceNetwork(conf configuration.Configuration, rootCm *component.Manager) (*ServiceNetwork, error)

NewServiceNetwork returns a new ServiceNetwork.

func (*ServiceNetwork) AddDispatcher

func (n *ServiceNetwork) AddDispatcher(beat.Dispatcher)

func (*ServiceNetwork) CreateMessagesRouter

func (n *ServiceNetwork) CreateMessagesRouter(ctx context.Context) messagesender.MessageRouter

func (*ServiceNetwork) FindAnyLatestNodeSnapshot

func (n *ServiceNetwork) FindAnyLatestNodeSnapshot() beat.NodeSnapshot

func (*ServiceNetwork) GetBeatHistory

func (n *ServiceNetwork) GetBeatHistory() beat.History

func (*ServiceNetwork) GetCert

func (*ServiceNetwork) GetLocalNodeReference

func (n *ServiceNetwork) GetLocalNodeReference() reference.Holder

func (*ServiceNetwork) GetLocalNodeRole

func (n *ServiceNetwork) GetLocalNodeRole() member.PrimaryRole

func (*ServiceNetwork) GetNetworkStatus

func (n *ServiceNetwork) GetNetworkStatus() network.StatusReply

func (*ServiceNetwork) GetNodeSnapshot

func (n *ServiceNetwork) GetNodeSnapshot(p pulse.Number) beat.NodeSnapshot

func (*ServiceNetwork) GracefulStop

func (n *ServiceNetwork) GracefulStop(ctx context.Context) error

func (*ServiceNetwork) Init

func (n *ServiceNetwork) Init(ctx context.Context) error

Init implements component.Initer

func (*ServiceNetwork) Leave

func (n *ServiceNetwork) Leave(ctx context.Context, eta pulse.Number)

func (*ServiceNetwork) SendMessageHandler

func (n *ServiceNetwork) SendMessageHandler(msg *message.Message) error

SendMessageHandler async sends message with confirmation of delivery.

func (*ServiceNetwork) Start

func (n *ServiceNetwork) Start(ctx context.Context) error

Start implements component.Starter

func (*ServiceNetwork) Stop

func (n *ServiceNetwork) Stop(ctx context.Context) error

Stop implements component.Stopper

type WatermillMessage

type WatermillMessage struct {
	UUID     string            `protobuf:"bytes,1,opt,name=UUID,proto3" json:"UUID,omitempty"`
	Metadata map[string]string `` /* 157-byte string literal not displayed */
	Payload  []byte            `protobuf:"bytes,3,opt,name=Payload,proto3" json:"Payload,omitempty"`
}

func (*WatermillMessage) Descriptor

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

func (*WatermillMessage) Equal

func (this *WatermillMessage) Equal(that interface{}) bool

func (*WatermillMessage) GoString

func (this *WatermillMessage) GoString() string

func (*WatermillMessage) Marshal

func (m *WatermillMessage) Marshal() (dAtA []byte, err error)

func (*WatermillMessage) MarshalTo

func (m *WatermillMessage) MarshalTo(dAtA []byte) (int, error)

func (*WatermillMessage) MarshalToSizedBuffer

func (m *WatermillMessage) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*WatermillMessage) ProtoMessage

func (*WatermillMessage) ProtoMessage()

func (*WatermillMessage) Reset

func (m *WatermillMessage) Reset()

func (*WatermillMessage) Size

func (m *WatermillMessage) Size() (n int)

func (*WatermillMessage) String

func (this *WatermillMessage) String() string

func (*WatermillMessage) Unmarshal

func (m *WatermillMessage) Unmarshal(dAtA []byte) error

func (*WatermillMessage) XXX_DiscardUnknown

func (m *WatermillMessage) XXX_DiscardUnknown()

func (*WatermillMessage) XXX_Marshal

func (m *WatermillMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*WatermillMessage) XXX_Merge

func (m *WatermillMessage) XXX_Merge(src proto.Message)

func (*WatermillMessage) XXX_Size

func (m *WatermillMessage) XXX_Size() int

func (*WatermillMessage) XXX_Unmarshal

func (m *WatermillMessage) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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