Skip to content

Commit b600ee0

Browse files
authored
Merge pull request #1063 from robertlaurin/record-net-peer-ip
Add net.peer.ip to Do span
2 parents cefe1a4 + fb84ca1 commit b600ee0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

query.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -634,6 +634,7 @@ func (c *Client) Do(ctx context.Context, q Query) (err error) {
634634
semconv.DBStatementKey.String(q.Body),
635635
semconv.DBUserKey.String(c.info.User),
636636
semconv.DBNameKey.String(c.info.Database),
637+
semconv.NetPeerIPKey.String(c.conn.RemoteAddr().String()),
637638
otelch.ProtocolVersion(c.protocolVersion),
638639
otelch.QuotaKey(q.QuotaKey),
639640
otelch.QueryID(q.QueryID),

0 commit comments

Comments
 (0)