ing
This commit is contained in:
parent
210cdfec3f
commit
911e6ec1d7
|
@ -1,6 +1,9 @@
|
|||
package fasthttp
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"git.loafle.net/commons_go/logging"
|
||||
"git.loafle.net/commons_go/rpc"
|
||||
"git.loafle.net/commons_go/rpc/protocol"
|
||||
cwf "git.loafle.net/commons_go/websocket_fasthttp"
|
||||
|
@ -16,6 +19,7 @@ type ServletReadWriteCloseHandlers struct {
|
|||
}
|
||||
|
||||
func (srwch *ServletReadWriteCloseHandlers) ReadRequest(servletCTX rpc.ServletContext, codec protocol.ServerCodec, conn interface{}) (protocol.ServerRequestCodec, error) {
|
||||
logging.Logger().Debug(fmt.Sprintf("ReadRequest: conn %v", conn))
|
||||
soc := conn.(cwf.Socket)
|
||||
_, r, err := soc.NextReader()
|
||||
|
||||
|
@ -25,6 +29,7 @@ func (srwch *ServletReadWriteCloseHandlers) ReadRequest(servletCTX rpc.ServletCo
|
|||
}
|
||||
|
||||
func (srwch *ServletReadWriteCloseHandlers) WriteResponse(servletCTX rpc.ServletContext, conn interface{}, requestCodec protocol.ServerRequestCodec, result interface{}, err error) error {
|
||||
logging.Logger().Debug(fmt.Sprintf("WriteResponse: conn %v", conn))
|
||||
soc := conn.(cwf.Socket)
|
||||
|
||||
wc, wErr := soc.NextWriter(websocket.TextMessage)
|
||||
|
@ -46,6 +51,7 @@ func (srwch *ServletReadWriteCloseHandlers) WriteResponse(servletCTX rpc.Servlet
|
|||
}
|
||||
|
||||
func (srwch *ServletReadWriteCloseHandlers) WriteNotification(servletCTX rpc.ServletContext, conn interface{}, codec protocol.ServerCodec, method string, params interface{}) error {
|
||||
logging.Logger().Debug(fmt.Sprintf("WriteNotification: conn %v", conn))
|
||||
soc := conn.(cwf.Socket)
|
||||
|
||||
wc, wErr := soc.NextWriter(websocket.TextMessage)
|
||||
|
|
Loading…
Reference in New Issue
Block a user