diff options
author | Valery Piashchynski <[email protected]> | 2021-07-14 17:22:49 +0300 |
---|---|---|
committer | GitHub <[email protected]> | 2021-07-14 17:22:49 +0300 |
commit | cea3f6ab9faf80637dd23f6b1ca57c0b3309d98e (patch) | |
tree | c70b7058e1682e93e98c9cf006d3584351d73d3b /plugins/websockets/plugin.go | |
parent | 9d018f259b45be9268ae85e089a07f25de894f41 (diff) | |
parent | cb28ad07fadb78e2e77e485cd9b96abeddbf3a5c (diff) |
#749 bug(supervisor, ttl): worker gets into the inconsistent state after TTL was reached
#749 bug(supervisor, ttl): worker gets into the inconsistent state after TTL was reached
Diffstat (limited to 'plugins/websockets/plugin.go')
-rw-r--r-- | plugins/websockets/plugin.go | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/plugins/websockets/plugin.go b/plugins/websockets/plugin.go index ca5f2f59..1115bd10 100644 --- a/plugins/websockets/plugin.go +++ b/plugins/websockets/plugin.go @@ -28,6 +28,9 @@ import ( const ( PluginName string = "websockets" + + RrMode string = "RR_MODE" + RrBroadcastPath string = "RR_BROADCAST_PATH" ) type Plugin struct { @@ -113,7 +116,7 @@ func (p *Plugin) Serve() chan error { AllocateTimeout: p.cfg.Pool.AllocateTimeout, DestroyTimeout: p.cfg.Pool.DestroyTimeout, Supervisor: p.cfg.Pool.Supervisor, - }, map[string]string{"RR_MODE": "http"}) + }, map[string]string{RrMode: "http", RrBroadcastPath: p.cfg.Path}) if err != nil { errCh <- err } @@ -176,7 +179,7 @@ func (p *Plugin) Middleware(next http.Handler) http.Handler { val, err := p.accessValidator(r) p.RUnlock() if err != nil { - p.log.Error("validation error") + p.log.Error("access validation") w.WriteHeader(400) return } @@ -280,7 +283,7 @@ func (p *Plugin) Reset() error { AllocateTimeout: p.cfg.Pool.AllocateTimeout, DestroyTimeout: p.cfg.Pool.DestroyTimeout, Supervisor: p.cfg.Pool.Supervisor, - }, map[string]string{"RR_MODE": "http"}) + }, map[string]string{RrMode: "http", RrBroadcastPath: p.cfg.Path}) if err != nil { return errors.E(op, err) } |