[Solved] Goroutine loop not completing


Finally figured the answer…

The problem was that I needed to close my monitoringChan in the first goroutine and then monitor (Defer wg.close()) in the second goroutine. Worked great when I did that!

https://play.golang.org/p/fEaZXiWCLt-

solved Goroutine loop not completing