Documentation
¶
Index ¶
- Constants
- Variables
- func GenerateID() uint64
- type Acceptor
- type Broker
- func (b *Broker) AddSession(details *SessionDetails) error
- func (b *Broker) AutoDisclosePublisher(disclose bool)
- func (b *Broker) HasSubscription(topic string) bool
- func (b *Broker) ReceiveMessage(sessionID uint64, msg messages.Message) (*MessageWithRecipient, error)
- func (b *Broker) ReceivePublish(sessionID uint64, publish *messages.Publish) (*Publication, error)
- func (b *Broker) RemoveSession(id uint64) error
- type CallMap
- type Dealer
- func (d *Dealer) AddSession(details *SessionDetails) error
- func (d *Dealer) AutoDiscloseCaller(disclose bool)
- func (d *Dealer) HasProcedure(procedure string) bool
- func (d *Dealer) ReceiveMessage(sessionID uint64, msg messages.Message) (*MessageWithRecipient, error)
- func (d *Dealer) RemoveSession(id uint64) error
- type Joiner
- type MessageWithRecipient
- type PendingInvocation
- type Publication
- type Registration
- type Session
- type SessionDetails
- func (s *SessionDetails) AuthExtra() map[string]any
- func (s *SessionDetails) AuthID() string
- func (s *SessionDetails) AuthMethod() string
- func (s *SessionDetails) AuthRole() string
- func (s *SessionDetails) CreatedAt() string
- func (s *SessionDetails) ID() uint64
- func (s *SessionDetails) Realm() string
- func (s *SessionDetails) RouterRoles() map[string]any
- func (s *SessionDetails) StaticSerializer() bool
- type SessionScopeIDGenerator
- type Subscription
Constants ¶
View Source
const ( AcceptorStateNone acceptorState = iota AcceptorStateChallengeSent AcceptorStateWelcomeSent )
View Source
const ( OptionReceiveProgress = "receive_progress" OptionProgress = "progress" OptionMatch = "match" OptionInvoke = "invoke" MatchExact = "exact" MatchPrefix = "prefix" MatchWildcard = "wildcard" InvokeSingle = "single" InvokeFirst = "first" InvokeLast = "last" InvokeRoundRobin = "roundrobin" InvokeRandom = "random" )
View Source
const ( FeatureProgressiveCallInvocations = "progressive_call_invocations" FeatureProgressiveCallResults = "progressive_call_results" FeatureCallCancelling = "call_canceling" FeaturePublisherExclusion = "publisher_exclusion" )
View Source
const ( CloseGoodByeAndOut = "wamp.close.goodbye_and_out" CloseCloseRealm = "wamp.close.close_realm" CloseSystemShutdown = "wamp.close.system_shutdown" CloseKilled = "wamp.close.killed" ErrNoMatchingAuthMethod = "wamp.error.no_matching_auth_method" ErrNoSuchRealm = "wamp.error.no_such_realm" ErrNoSuchRole = "wamp.error.no_such_role" ErrNoSuchPrincipal = "wamp.error.no_such_principal" ErrNoSuchSession = "wamp.error.no_such_session" ErrAuthenticationDenied = "wamp.error.authentication_denied" ErrAuthenticationFailed = "wamp.error.authentication_failed" ErrAuthenticationRequired = "wamp.error.authentication_required" ErrAuthorizationDenied = "wamp.error.authorization_denied" ErrAuthorizationFailed = "wamp.error.authorization_failed" ErrAuthorizationRequired = "wamp.error.authorization_required" ErrTimeout = "wamp.error.timeout" ErrOptionNotAllowed = "wamp.error.option_not_allowed" ErrOptionDisallowedDiscloseMe = "wamp.error.option_disallowed.disclose_me" ErrNetworkFailure = "wamp.error.network_failure" ErrNoAvailableCallee = "wamp.error.no_available_callee" ErrFeatureNotSupported = "wamp.error.feature_not_supported" ErrInvalidURI = "wamp.error.invalid_uri" ErrNoSuchProcedure = "wamp.error.no_such_procedure" ErrProcedureAlreadyExists = "wamp.error.procedure_already_exists" ErrNoSuchRegistration = "wamp.error.no_such_registration" ErrNoSuchSubscription = "wamp.error.no_such_subscription" ErrInvalidArgument = "wamp.error.invalid_argument" ErrCanceled = "wamp.error.canceled" ErrPayloadSizeExceeded = "wamp.error.payload_size_exceeded" ErrProtocolViolation = "wamp.error.protocol_violation" ErrNotAuthorized = "wamp.error.not_authorized" )
View Source
const (
OptAcknowledge = "acknowledge"
)
Variables ¶
View Source
var ClientRoles = map[string]any{ "caller": map[string]any{ // contains filtered or unexported fields }, "callee": map[string]any{ // contains filtered or unexported fields }, "publisher": map[string]any{ // contains filtered or unexported fields }, "subscriber": map[string]any{ // contains filtered or unexported fields }, }
Functions ¶
Types ¶
type Acceptor ¶
type Acceptor struct {
// contains filtered or unexported fields
}
func NewAcceptor ¶
func NewAcceptor(serializer serializers.Serializer, authenticator auth.ServerAuthenticator) *Acceptor
func (*Acceptor) ReceiveMessage ¶
func (*Acceptor) SessionDetails ¶
func (a *Acceptor) SessionDetails() (*SessionDetails, error)
type Broker ¶
func (*Broker) AddSession ¶
func (b *Broker) AddSession(details *SessionDetails) error
func (*Broker) AutoDisclosePublisher ¶
func (*Broker) HasSubscription ¶
func (*Broker) ReceiveMessage ¶
func (*Broker) ReceivePublish ¶
func (*Broker) RemoveSession ¶
type Dealer ¶
func (*Dealer) AddSession ¶
func (d *Dealer) AddSession(details *SessionDetails) error
func (*Dealer) AutoDiscloseCaller ¶
func (*Dealer) HasProcedure ¶
func (*Dealer) ReceiveMessage ¶
func (*Dealer) RemoveSession ¶
type Joiner ¶
type Joiner struct {
// contains filtered or unexported fields
}
func NewJoiner ¶
func NewJoiner(realm string, serializer serializers.Serializer, authenticator auth.ClientAuthenticator) *Joiner
func (*Joiner) ReceiveMessage ¶
func (*Joiner) SessionDetails ¶
func (j *Joiner) SessionDetails() (*SessionDetails, error)
type MessageWithRecipient ¶
type PendingInvocation ¶
type Publication ¶
type Publication struct {
Event *messages.Event
Recipients []uint64
Ack *MessageWithRecipient
}
type Registration ¶
type Session ¶
type Session struct {
// contains filtered or unexported fields
}
func NewSession ¶
func NewSession(serializer serializers.Serializer) *Session
func (*Session) ReceiveMessage ¶
type SessionDetails ¶
type SessionDetails struct {
// contains filtered or unexported fields
}
func NewSessionDetails ¶
func (*SessionDetails) AuthExtra ¶
func (s *SessionDetails) AuthExtra() map[string]any
func (*SessionDetails) AuthID ¶
func (s *SessionDetails) AuthID() string
func (*SessionDetails) AuthMethod ¶
func (s *SessionDetails) AuthMethod() string
func (*SessionDetails) AuthRole ¶
func (s *SessionDetails) AuthRole() string
func (*SessionDetails) CreatedAt ¶
func (s *SessionDetails) CreatedAt() string
func (*SessionDetails) ID ¶
func (s *SessionDetails) ID() uint64
func (*SessionDetails) Realm ¶
func (s *SessionDetails) Realm() string
func (*SessionDetails) RouterRoles ¶
func (s *SessionDetails) RouterRoles() map[string]any
func (*SessionDetails) StaticSerializer ¶
func (s *SessionDetails) StaticSerializer() bool
type SessionScopeIDGenerator ¶
func (*SessionScopeIDGenerator) NextID ¶
func (s *SessionScopeIDGenerator) NextID() uint64
Source Files
¶
Click to show internal directories.
Click to hide internal directories.