Fix go routine leak in channel client
When requests timeout, the routines listening on
the 'complete' channel exit while the writers
block forever. Making this a buffered channel will
resolve this issue.
@@ -173,7 +173,7 @@ func (cc *Client) InvokeHandler(handler invoke.Handler, request Request, options
),
)
- complete := make(chan bool)
+ complete := make(chan bool, 1)
go func() {
_, _ = invoker.Invoke(
func() (interface{}, error) {
