[#1227] morph/event: Release ants.Pool on listener stopping

Signed-off-by: Denis Kirillov <d.kirillov@yadro.com>
This commit is contained in:
Denis Kirillov 2024-07-04 12:09:18 +03:00 committed by Evgenii Stratonikov
parent 62cbb72a5e
commit cfd5e3d403

View file

@ -621,6 +621,7 @@ func (l *listener) RegisterNotaryHandler(hi NotaryHandlerInfo) {
func (l *listener) Stop() { func (l *listener) Stop() {
l.stopOnce.Do(func() { l.stopOnce.Do(func() {
l.subscriber.Close() l.subscriber.Close()
l.pool.Release()
}) })
l.wg.Wait() l.wg.Wait()
} }