File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -99,6 +99,11 @@ type Context struct {
9999 Agent beat.Info
100100
101101 // Cancelation is used by Beats to signal the input to shut down.
102+ //
103+ // An input started with a Context parameter, ctx, must shut down when
104+ // <-ctx.Cancelation.Done() does not block or when ctx.Cancelation.Error()
105+ // returns a non-nil error. If an input is started with a specific Context
106+ // it should only shutdown in response to that Context's Cancelation.
102107 Cancelation Canceler
103108
104109 // StatusReporter provides a method to update the status of the underlying unit
@@ -221,6 +226,11 @@ type TestContext struct {
221226 Agent beat.Info
222227
223228 // Cancelation is used by Beats to signal the input to shut down.
229+ //
230+ // An input started with a Context parameter, ctx, must shut down when
231+ // <-ctx.Cancelation.Done() does not block or when ctx.Cancelation.Error()
232+ // returns a non-nil error. If an input is started with a specific Context
233+ // it should only shutdown in response to that Context's Cancelation.
224234 Cancelation Canceler
225235}
226236
You can’t perform that action at this time.
0 commit comments