overflow_probes/client/central/probe/client_handlers.go

32 lines
745 B
Go
Raw Normal View History

2017-12-02 03:13:08 +00:00
package probe
2017-12-01 16:17:44 +00:00
import (
"fmt"
"git.loafle.net/commons_go/logging"
crc "git.loafle.net/commons_go/rpc/client"
crr "git.loafle.net/commons_go/rpc/registry"
oogwc "git.loafle.net/overflow/overflow_gateway_websocket/client"
)
2017-12-08 08:31:45 +00:00
func newClientHandler(rpcInvoker crr.RPCInvoker) oogwc.ClientHandler {
2017-12-01 16:17:44 +00:00
ch := &ClientHandlers{}
ch.ClientHandler = oogwc.NewClientHandler(rpcInvoker)
return ch
}
type ClientHandlers struct {
oogwc.ClientHandler
}
func (ch *ClientHandlers) Init(clientCTX crc.ClientContext) error {
logging.Logger().Info(fmt.Sprintf("Probe: client has been initialized"))
return nil
}
func (ch *ClientHandlers) Destroy(clientCTX crc.ClientContext) {
logging.Logger().Info(fmt.Sprintf("Probe: client has been destroyed"))
}