Skip to content

Commit 0fab977

Browse files
authored
contrib/go-pg/pg.v10: remove spankind value (#1624)
1 parent a694524 commit 0fab977

File tree

2 files changed

+0
-6
lines changed

2 files changed

+0
-6
lines changed

contrib/go-pg/pg.v10/pg_go.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ func (h *queryHook) BeforeQuery(ctx context.Context, qe *pg.QueryEvent) (context
4444
tracer.ResourceName(string(query)),
4545
tracer.ServiceName(h.cfg.serviceName),
4646
tracer.Tag(ext.Component, "go-pg/pg.v10"),
47-
tracer.Tag(ext.SpanKind, ext.SpanKindClient),
4847
}
4948
if !math.IsNaN(h.cfg.analyticsRate) {
5049
opts = append(opts, tracer.Tag(ext.EventSampleRate, h.cfg.analyticsRate))

contrib/go-pg/pg.v10/pg_go_test.go

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,6 @@ func TestSelect(t *testing.T) {
6868
assert.Equal("go-pg", spans[0].OperationName())
6969
assert.Equal("http.request", spans[1].OperationName())
7070
assert.Equal("go-pg/pg.v10", spans[0].Tags()[ext.Component])
71-
assert.Equal(ext.SpanKindClient, spans[0].Tags()[ext.SpanKind])
72-
7371
}
7472

7573
func TestServiceName(t *testing.T) {
@@ -109,7 +107,6 @@ func TestServiceName(t *testing.T) {
109107
assert.Equal("gopg.db", spans[0].Tag(ext.ServiceName))
110108
assert.Equal("fake-http-server", spans[1].Tag(ext.ServiceName))
111109
assert.Equal("go-pg/pg.v10", spans[0].Tags()[ext.Component])
112-
assert.Equal(ext.SpanKindClient, spans[0].Tags()[ext.SpanKind])
113110
})
114111

115112
t.Run("global", func(t *testing.T) {
@@ -151,7 +148,6 @@ func TestServiceName(t *testing.T) {
151148
assert.Equal("global-service", spans[0].Tag(ext.ServiceName))
152149
assert.Equal("fake-http-server", spans[1].Tag(ext.ServiceName))
153150
assert.Equal("go-pg/pg.v10", spans[0].Tags()[ext.Component])
154-
assert.Equal(ext.SpanKindClient, spans[0].Tags()[ext.SpanKind])
155151
})
156152

157153
t.Run("custom", func(t *testing.T) {
@@ -190,7 +186,6 @@ func TestServiceName(t *testing.T) {
190186
assert.Equal("my-service-name", spans[0].Tag(ext.ServiceName))
191187
assert.Equal("fake-http-server", spans[1].Tag(ext.ServiceName))
192188
assert.Equal("go-pg/pg.v10", spans[0].Tags()[ext.Component])
193-
assert.Equal(ext.SpanKindClient, spans[0].Tags()[ext.SpanKind])
194189
})
195190
}
196191

0 commit comments

Comments
 (0)