Documentation
¶
Index ¶
- Variables
- func CreateDiscoveryRequest(id string, driver string) *global.DiscoveryRequest
- func CreatePushRequest(id string, r *http.Request) *global.PushRequest
- func CreatePushResponse(id string, statusCode int, endOfStreams bool, h http.Header, body []byte) *global.PushResponse
- type EventTypeProcess
- type Interceptor
- type Listener
- type Method
- type MethodMultipleHandler
- type MultipleHandlerOption
- type OnPushMessage
- type OnPushMessageResponse
- type Options
- type Port
- type UseAuthCallback
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func CreateDiscoveryRequest ¶
func CreateDiscoveryRequest(id string, driver string) *global.DiscoveryRequest
func CreatePushRequest ¶
func CreatePushRequest(id string, r *http.Request) *global.PushRequest
func CreatePushResponse ¶
Types ¶
type EventTypeProcess ¶
type EventTypeProcess string
const ( EventTypeProcessSplitter EventTypeProcess = "http.splitter" EventTypeProcessHttpHandler EventTypeProcess = "http.handler" EventTypeProcessHttpController EventTypeProcess = "http.controller" EventTypeProcessGRPCWebController EventTypeProcess = "grpc.web.controller" EventTypeProcessGRPCController EventTypeProcess = "grpc.controller" EventTypeProcessHttpMiddlewareCompress EventTypeProcess = "http.middleware.compress" )
type Interceptor ¶
type Interceptor struct { UnaryServerInterceptor grpc.UnaryServerInterceptor StreamServerInterceptor grpc.StreamServerInterceptor }
type Listener ¶
type Listener interface { Init(opt Options, interceptor ...Interceptor) Run() (err error) RunRouter() (err error) // handle grpc, grpc-web and http RegisterMultipleHandler(MethodMultipleHandler) PushRouterListener(*listener.RouterListener, http.HandlerFunc) SetTracer(tracing.Tracing) //Get from main modules GetServices() []string GetAllServices() (res []*listener.ServicesItems) GetOptions() Options GetTracer() tracing.Tracing GetMonitor() *listener.MonitorResponse }
listener modules interface, using for dynamic modules
type MethodMultipleHandler ¶
type MethodMultipleHandler interface{}
type MultipleHandlerOption ¶
type MultipleHandlerOption interface { GetServiceDesc() []*grpc.ServiceDesc AllowMethod(string) []Method }
MultipleHandlerOption -
type OnPushMessage ¶
type OnPushMessage func(data *global.PushRequest, onMsg OnPushMessageResponse)
type OnPushMessageResponse ¶
type OnPushMessageResponse func(*global.PushResponse)
type UseAuthCallback ¶
Click to show internal directories.
Click to hide internal directories.