Documentation
¶
Index ¶
- Constants
- type Config
- type Plugin
- func (p *Plugin) Init(cfg config.Configurer, log *zap.Logger, server server.Server, ...) error
- func (p *Plugin) Middleware(next http.Handler) http.Handler
- func (p *Plugin) Name() string
- func (p *Plugin) Reset() error
- func (p *Plugin) Serve() chan error
- func (p *Plugin) Stop() error
- func (p *Plugin) Workers() []*process.State
Constants ¶
View Source
const ( PluginName string = "websockets" RrMode string = "RR_MODE" RrBroadcastPath string = "RR_BROADCAST_PATH" OriginHeaderKey string = "Origin" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// http path for the websocket
Path string `mapstructure:"path"`
AllowedOrigin string `mapstructure:"allowed_origin"`
Broker string `mapstructure:"broker"`
// Pool with the workers for the websockets
Pool *pool.Config `mapstructure:"pool"`
// contains filtered or unexported fields
}
Config represents configuration for the ws plugin
func (*Config) InitDefault ¶
InitDefault initialize default values for the ws config
Click to show internal directories.
Click to hide internal directories.