lovoo / goka

Goka is a compact yet powerful distributed stream processing library for Apache Kafka written in Go.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bug: `PartitionProcessor.VisitValues` does not clean up `Signal.waiters`, causing a memory leak

chrisfjones opened this issue · comments

If Signal.WaitForState* is called multiple times for a state like "stopping", the waiters will remain in the signal's queue forever and their channel will remain open. This has happened in my case while calling PartitionProcessor.VisitValues multiple times. This was causing Signal.waiters to grow indefinitely and cause a memory leak.
A potential fix is here: #397