remoting

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2026 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handshake

type Handshake struct {
	AdvertiseAddr string // 广告地址
}

func (*Handshake) Send

func (h *Handshake) Send(conn net.Conn) error

func (*Handshake) Wait

func (h *Handshake) Wait(conn net.Conn) error

type Mailbox

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

func (*Mailbox) Enqueue

func (m *Mailbox) Enqueue(envelop vivid.Envelop)

func (*Mailbox) IsPaused

func (m *Mailbox) IsPaused() bool

func (*Mailbox) Pause

func (m *Mailbox) Pause()

func (*Mailbox) Resume

func (m *Mailbox) Resume()

type MailboxCentral

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

func (*MailboxCentral) Close

func (rmc *MailboxCentral) Close()

func (*MailboxCentral) GetOrCreate

func (rmc *MailboxCentral) GetOrCreate(advertiseAddr string, envelopHandler NetworkEnvelopHandler) *Mailbox

type NetworkEnvelopHandler

type NetworkEnvelopHandler interface {
	HandleRemotingEnvelop(system bool, senderAddr, senderPath, receiverAddr, receiverPath string, messageInstance any) error

	HandleFailedRemotingEnvelop(envelop vivid.Envelop)
}

type ServerActor

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

ServerActor 管理TCP服务器

func NewServerActor

func NewServerActor(ctx context.Context, bindAddr string, advertiseAddr string, codec vivid.Codec, envelopHandler NetworkEnvelopHandler, options vivid.ActorSystemRemotingOptions) *ServerActor

NewServerActor 创建新的服务器

func (*ServerActor) GetRemotingMailboxCentral

func (s *ServerActor) GetRemotingMailboxCentral() *MailboxCentral

func (*ServerActor) OnReceive

func (s *ServerActor) OnReceive(ctx vivid.ActorContext)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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