Documentation ¶
Index ¶
Constants ¶
View Source
const ( // Publisher is the service(s) publisher Publisher = "example" // ServiceEcho is the echo service ServiceEcho = "echo.v1.0" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type MessageReply ¶
type MessageReply struct { *MessageRequest Signature string }
MessageReply is the message replied by server, with Num+1 and a signature of "yours echo.v1.0".
type MessageRequest ¶
MessageRequest is the message sent by client. Return MessageReply.
func (*MessageRequest) Handle ¶
func (msg *MessageRequest) Handle(stream as.ContextStream) (reply interface{})
Handle handles msg.
type MessageTimeout ¶ added in v0.9.17
type MessageTimeout struct{}
MessageTimeout is for timeout test
func (MessageTimeout) Handle ¶ added in v0.9.17
func (msg MessageTimeout) Handle(stream as.ContextStream) (reply interface{})
Handle handles msg.
type SubWhoElseEvent ¶
type SubWhoElseEvent struct{}
SubWhoElseEvent is used for clients to subscribe who else event which reports new incoming connection to the server. Return string.
func (SubWhoElseEvent) Handle ¶
func (msg SubWhoElseEvent) Handle(stream as.ContextStream) (reply interface{})
Handle handles msg.
Click to show internal directories.
Click to hide internal directories.