supervisor-go icon indicating copy to clipboard operation
supervisor-go copied to clipboard

Ignore context.Canceled?

Open gust1n opened this issue 2 years ago • 0 comments

Raising it here for discussion, should we really try to restart a service if canceled by the context and returning context.Canceled? I just wrote some services that basically did:

select {
case <-ctx.Done():
  return ctx.Err()
}

which would then have supervisor-go try to restart them, while I think that could be ignored (e.g. if !errors.Is(err, context.Canceled))

WDYT?

gust1n avatar Mar 24 '22 14:03 gust1n