From 3acab6601d76337acfcb0de6dd98e319faa10946 Mon Sep 17 00:00:00 2001 From: Mahad Zaryab Date: Tue, 17 Dec 2024 21:41:33 -0500 Subject: [PATCH] Revert Returning Interface Signed-off-by: Mahad Zaryab --- cmd/query/app/querysvc/adjuster/ipattribute.go | 4 +++- cmd/query/app/querysvc/adjuster/resourceattributes.go | 4 +++- cmd/query/app/querysvc/adjuster/spanlinks.go | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/cmd/query/app/querysvc/adjuster/ipattribute.go b/cmd/query/app/querysvc/adjuster/ipattribute.go index 05c98f04de6..cd3b9bb1340 100644 --- a/cmd/query/app/querysvc/adjuster/ipattribute.go +++ b/cmd/query/app/querysvc/adjuster/ipattribute.go @@ -12,6 +12,8 @@ import ( "go.opentelemetry.io/collector/pdata/ptrace" ) +var _ Adjuster = (*IPAttributeAdjuster)(nil) + var ipAttributesToCorrect = map[string]struct{}{ "ip": {}, "peer.ipv4": {}, @@ -20,7 +22,7 @@ var ipAttributesToCorrect = map[string]struct{}{ // IPAttribute returns an adjuster that replaces numeric "ip" attributes, // which usually contain IPv4 packed into uint32, with their string // representation (e.g. "8.8.8.8""). -func IPAttribute() Adjuster { +func IPAttribute() IPAttributeAdjuster { return IPAttributeAdjuster{} } diff --git a/cmd/query/app/querysvc/adjuster/resourceattributes.go b/cmd/query/app/querysvc/adjuster/resourceattributes.go index db0cb262440..e995088d101 100644 --- a/cmd/query/app/querysvc/adjuster/resourceattributes.go +++ b/cmd/query/app/querysvc/adjuster/resourceattributes.go @@ -11,6 +11,8 @@ import ( "github.com/jaegertracing/jaeger/pkg/otelsemconv" ) +var _ Adjuster = (*ResourceAttributesAdjuster)(nil) + var libraryKeys = map[string]struct{}{ string(otelsemconv.TelemetrySDKLanguageKey): {}, string(otelsemconv.TelemetrySDKNameKey): {}, @@ -23,7 +25,7 @@ var libraryKeys = map[string]struct{}{ // attributes from spans to the parent resource so that the UI can // display them separately under Process. // https://github.com/jaegertracing/jaeger/issues/4534 -func ResourceAttributes() Adjuster { +func ResourceAttributes() ResourceAttributesAdjuster { return ResourceAttributesAdjuster{} } diff --git a/cmd/query/app/querysvc/adjuster/spanlinks.go b/cmd/query/app/querysvc/adjuster/spanlinks.go index 84dbf781a37..68c3ef3de62 100644 --- a/cmd/query/app/querysvc/adjuster/spanlinks.go +++ b/cmd/query/app/querysvc/adjuster/spanlinks.go @@ -7,8 +7,10 @@ import ( "go.opentelemetry.io/collector/pdata/ptrace" ) +var _ Adjuster = (*LinksAdjuster)(nil) + // SpanLinks creates an adjuster that removes span links with empty trace IDs. -func SpanLinks() Adjuster { +func SpanLinks() LinksAdjuster { return LinksAdjuster{} }