Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[processor/tailsampling] Cleanly tear down test #9283

Merged
merged 2 commits into from
Apr 18, 2022
Merged
Show file tree
Hide file tree
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
5 changes: 5 additions & 0 deletions processor/tailsamplingprocessor/factory_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,9 @@ func TestCreateProcessor(t *testing.T) {
tp, err := factory.CreateTracesProcessor(context.Background(), params, cfg, consumertest.NewNop())
assert.NotNil(t, tp)
assert.NoError(t, err, "cannot create trace processor")

// this will cause the processor to properly initialize, so that we can later shutdown and
// have all the go routines cleanly shut down
assert.NoError(t, tp.Start(context.Background(), componenttest.NewNopHost()))
assert.NoError(t, tp.Shutdown(context.Background()))
}
3 changes: 2 additions & 1 deletion processor/tailsamplingprocessor/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ require (
go.opencensus.io v0.23.0
go.opentelemetry.io/collector v0.49.0
go.opentelemetry.io/collector/pdata v0.49.0
go.uber.org/goleak v1.1.11
go.uber.org/zap v1.21.0

)

require (
Expand All @@ -29,6 +29,7 @@ require (
go.opentelemetry.io/otel/trace v1.6.3 // indirect
go.uber.org/atomic v1.9.0 // indirect
go.uber.org/multierr v1.8.0 // indirect
golang.org/x/lint v0.0.0-20200302205851-738671d3881b // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
)
Expand Down
Loading