diff --git a/processor/resourcedetectionprocessor/factory.go b/processor/resourcedetectionprocessor/factory.go index 8c76023506e9..05ff7934f81b 100644 --- a/processor/resourcedetectionprocessor/factory.go +++ b/processor/resourcedetectionprocessor/factory.go @@ -49,7 +49,7 @@ type factory struct { } // NewFactory creates a new factory for ResourceDetection processor. -func NewFactory() processorprofiles.Factory { +func NewFactory() processor.Factory { resourceProviderFactory := internal.NewProviderFactory(map[internal.DetectorType]internal.DetectorFactory{ aks.TypeStr: aks.NewDetector, azure.TypeStr: azure.NewDetector, diff --git a/processor/resourcedetectionprocessor/generated_component_test.go b/processor/resourcedetectionprocessor/generated_component_test.go index 1010de92d7c5..98196c23550b 100644 --- a/processor/resourcedetectionprocessor/generated_component_test.go +++ b/processor/resourcedetectionprocessor/generated_component_test.go @@ -62,7 +62,7 @@ func TestComponentLifecycle(t *testing.T) { { name: "profiles", createFn: func(ctx context.Context, set processor.Settings, cfg component.Config) (component.Component, error) { - return factory.CreateProfiles(ctx, set, cfg, consumertest.NewNop()) + return factory.(processorprofiles.Factory).CreateProfiles(ctx, set, cfg, consumertest.NewNop()) }, }, } diff --git a/processor/resourcedetectionprocessor/resourcedetection_processor_test.go b/processor/resourcedetectionprocessor/resourcedetection_processor_test.go index 9ef993a0678c..a61c8a4efaaf 100644 --- a/processor/resourcedetectionprocessor/resourcedetection_processor_test.go +++ b/processor/resourcedetectionprocessor/resourcedetection_processor_test.go @@ -22,6 +22,7 @@ import ( "go.opentelemetry.io/collector/pdata/pprofile" "go.opentelemetry.io/collector/pdata/ptrace" "go.opentelemetry.io/collector/processor" + "go.opentelemetry.io/collector/processor/processorprofiles" "go.opentelemetry.io/collector/processor/processortest" "github.com/open-telemetry/opentelemetry-collector-contrib/processor/resourcedetectionprocessor/internal" @@ -364,7 +365,7 @@ func BenchmarkConsumeLogsAll(b *testing.B) { func benchmarkConsumeProfiles(b *testing.B, cfg *Config) { factory := NewFactory() sink := new(consumertest.ProfilesSink) - processor, _ := factory.CreateProfiles(context.Background(), processortest.NewNopSettings(), cfg, sink) + processor, _ := factory.(processorprofiles.Factory).CreateProfiles(context.Background(), processortest.NewNopSettings(), cfg, sink) b.ResetTimer() for n := 0; n < b.N; n++ {