Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions filebeat/input/v2/input.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,11 @@ type Context struct {
Agent beat.Info

// Cancelation is used by Beats to signal the input to shut down.
//
// An input started with a Context parameter, ctx, must shut down when
// <-ctx.Cancelation.Done() does not block or when ctx.Cancelation.Error()
// returns a non-nil error. If an input is started with a specific Context
// it should only shutdown in response to that Context's Cancelation.
Cancelation Canceler

// StatusReporter provides a method to update the status of the underlying unit
Expand Down Expand Up @@ -221,6 +226,11 @@ type TestContext struct {
Agent beat.Info

// Cancelation is used by Beats to signal the input to shut down.
//
// An input started with a Context parameter, ctx, must shut down when
// <-ctx.Cancelation.Done() does not block or when ctx.Cancelation.Error()
// returns a non-nil error. If an input is started with a specific Context
// it should only shutdown in response to that Context's Cancelation.
Cancelation Canceler
}

Expand Down
Loading