Documentation ¶
Index ¶
- Constants
- Variables
- func ActorSystem() *actorSystem
- func AddConnection(name string, conf OptionsInterface)
- func CloseActorSystem() error
- func DeleteRemoteActorConnection(name string) error
- func InitActorSystem(options SystemOptions) error
- func InitRemoteConnections(configuration map[string]OptionsInterface)
- func NewActorLogger(name string) (*log.Logger, *log.Logger)
- type Actor
- type ActorOptions
- func (options *ActorOptions) Autoclose() bool
- func (options *ActorOptions) BufferSize() int
- func (options *ActorOptions) DefaultWatcher() time.Duration
- func (options *ActorOptions) Destination() string
- func (options *ActorOptions) Parent() string
- func (options *ActorOptions) Remote() bool
- func (options *ActorOptions) RemoteType() string
- func (options *ActorOptions) SetAutoclose(b bool) OptionsInterface
- func (options *ActorOptions) SetBufferSize(i int) OptionsInterface
- func (options *ActorOptions) SetDefaultWatcher(d time.Duration) OptionsInterface
- func (options *ActorOptions) SetDestination(s string) OptionsInterface
- func (options *ActorOptions) SetRemote(b bool) OptionsInterface
- func (options *ActorOptions) SetRemoteType(s string) OptionsInterface
- func (options *ActorOptions) SetUrl(s string) OptionsInterface
- func (options *ActorOptions) Url() string
- type ActorRef
- func (ref ActorRef) AskForClose(sender ActorRefInterface)
- func (ref ActorRef) Become(messageType string, f func(Context)) error
- func (ref ActorRef) Forward(context Context, destinations ...string)
- func (ref ActorRef) LogError(context Context, format string, a ...interface{})
- func (ref ActorRef) LogInfo(context Context, format string, a ...interface{})
- func (ref ActorRef) Name() string
- func (ref ActorRef) Repeat(messageType string, d time.Duration, data interface{}, ...) (chan struct{}, error)
- func (ref ActorRef) Tell(context Context, messageType string, data interface{}, ...) error
- func (ref ActorRef) Unbecome(messageType string) error
- type ActorRefInterface
- type Context
- type OptionsInterface
- type RemoteActor
- type SystemOptions
- type TransportInterface
- type ZipkinOptions
Constants ¶
View Source
const ( GosirisMsgPoisonPill = "gosirisPoisonPill" GosirisMsgChildClosed = "gosirisChildClosed" GosirisMsgHeartbeatRequest = "gosirisHeartbeatRequest" GosirisMsgHeartbeatReply = "gosirisHeartbeatReply" )
Variables ¶
View Source
var Amqp = "amqp"
View Source
var ErrorLogger *log.Logger
View Source
var FatalLogger *log.Logger
View Source
var InfoLogger *log.Logger
View Source
var Kafka = "kafka"
Functions ¶
func ActorSystem ¶
func ActorSystem() *actorSystem
func AddConnection ¶
func AddConnection(name string, conf OptionsInterface)
func CloseActorSystem ¶
func CloseActorSystem() error
func InitActorSystem ¶
func InitActorSystem(options SystemOptions) error
func InitRemoteConnections ¶
func InitRemoteConnections(configuration map[string]OptionsInterface)
Types ¶
type Actor ¶
type Actor struct {
// contains filtered or unexported fields
}
func (*Actor) Parent ¶
func (actor *Actor) Parent() ActorRefInterface
type ActorOptions ¶
type ActorOptions struct {
// contains filtered or unexported fields
}
func (*ActorOptions) Autoclose ¶
func (options *ActorOptions) Autoclose() bool
func (*ActorOptions) BufferSize ¶
func (options *ActorOptions) BufferSize() int
func (*ActorOptions) DefaultWatcher ¶
func (options *ActorOptions) DefaultWatcher() time.Duration
func (*ActorOptions) Destination ¶
func (options *ActorOptions) Destination() string
func (*ActorOptions) Parent ¶
func (options *ActorOptions) Parent() string
func (*ActorOptions) Remote ¶
func (options *ActorOptions) Remote() bool
func (*ActorOptions) RemoteType ¶
func (options *ActorOptions) RemoteType() string
func (*ActorOptions) SetAutoclose ¶
func (options *ActorOptions) SetAutoclose(b bool) OptionsInterface
func (*ActorOptions) SetBufferSize ¶
func (options *ActorOptions) SetBufferSize(i int) OptionsInterface
func (*ActorOptions) SetDefaultWatcher ¶
func (options *ActorOptions) SetDefaultWatcher(d time.Duration) OptionsInterface
func (*ActorOptions) SetDestination ¶
func (options *ActorOptions) SetDestination(s string) OptionsInterface
func (*ActorOptions) SetRemote ¶
func (options *ActorOptions) SetRemote(b bool) OptionsInterface
func (*ActorOptions) SetRemoteType ¶
func (options *ActorOptions) SetRemoteType(s string) OptionsInterface
func (*ActorOptions) SetUrl ¶
func (options *ActorOptions) SetUrl(s string) OptionsInterface
func (*ActorOptions) Url ¶
func (options *ActorOptions) Url() string
type ActorRef ¶
type ActorRef struct {
// contains filtered or unexported fields
}
func (ActorRef) AskForClose ¶
func (ref ActorRef) AskForClose(sender ActorRefInterface)
type ActorRefInterface ¶
type ActorRefInterface interface { Tell(Context, string, interface{}, ActorRefInterface) error Repeat(string, time.Duration, interface{}, ActorRefInterface) (chan struct{}, error) AskForClose(ActorRefInterface) LogInfo(Context, string, ...interface{}) LogError(Context, string, ...interface{}) Become(string, func(Context)) error Unbecome(string) error Name() string Forward(Context, ...string) }
type Context ¶
type Context struct { MessageType string Data interface{} Sender ActorRefInterface Self ActorRefInterface // contains filtered or unexported fields }
func (Context) MarshalJSON ¶
func (*Context) UnmarshalJSON ¶
type OptionsInterface ¶
type OptionsInterface interface { SetUrl(string) OptionsInterface SetRemote(bool) OptionsInterface SetAutoclose(bool) OptionsInterface Remote() bool Autoclose() bool SetRemoteType(string) OptionsInterface RemoteType() string Url() string SetDestination(string) OptionsInterface Destination() string Parent() string SetBufferSize(int) OptionsInterface BufferSize() int SetDefaultWatcher(time.Duration) OptionsInterface DefaultWatcher() time.Duration // contains filtered or unexported methods }
TODO No interface
type RemoteActor ¶
type RemoteActor struct {
Actor
}
type SystemOptions ¶
type SystemOptions struct { ActorSystemName string ZipkinOptions ZipkinOptions RegistryUrl string }
type TransportInterface ¶
type TransportInterface interface { Configure(string, map[string]string) Connection() error Send(string, []byte) error Receive(string) Close() }
func RemoteConnection ¶
func RemoteConnection(name string) (TransportInterface, error)
Click to show internal directories.
Click to hide internal directories.