diff options
author | Valery Piashchynski <[email protected]> | 2021-02-08 23:21:54 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2021-02-08 23:21:54 +0300 |
commit | da64d9fbab7d73e203e7dbbb9503f4d422feaab0 (patch) | |
tree | 3dc3d5dd4a8c4de7d4b57baf2eeb1089f831bc1c /plugins/http | |
parent | 3e92e3df723ca1c4f152d8526eebfd7184e6fcec (diff) |
BaseProcess interface as a return type in the worker_watcher,pool and
worker interface
Diffstat (limited to 'plugins/http')
-rw-r--r-- | plugins/http/plugin.go | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/plugins/http/plugin.go b/plugins/http/plugin.go index ff0c1c30..bab03edc 100644 --- a/plugins/http/plugin.go +++ b/plugins/http/plugin.go @@ -305,12 +305,7 @@ func (s *Plugin) ServeHTTP(w http.ResponseWriter, r *http.Request) { func (s *Plugin) Workers() []worker.BaseProcess { s.Lock() defer s.Unlock() - workers := s.pool.Workers() - baseWorkers := make([]worker.BaseProcess, 0, len(workers)) - for i := 0; i < len(workers); i++ { - baseWorkers = append(baseWorkers, worker.FromSync(workers[i].(*worker.SyncWorkerImpl))) - } - return baseWorkers + return s.pool.Workers() } // Name returns endure.Named interface implementation |