Add detailed parameter tracing + custom prefix (#18518)

* Allow per handler custom prefix.
* Add automatic parameter extraction
This commit is contained in:
Klaus Post
2023-11-26 01:32:59 -08:00
committed by GitHub
parent 11dc723324
commit ca488cce87
6 changed files with 93 additions and 9 deletions

View File

@@ -336,7 +336,7 @@ func (c *Connection) Request(ctx context.Context, h HandlerID, req []byte) ([]by
}
c.outgoing.Delete(client.MuxID)
}()
return client.traceRoundtrip(c.trace, h, req)
return client.traceRoundtrip(ctx, c.trace, h, req)
}
// Request allows to do a single remote request.
@@ -364,7 +364,7 @@ func (c *Subroute) Request(ctx context.Context, h HandlerID, req []byte) ([]byte
}
c.outgoing.Delete(client.MuxID)
}()
return client.traceRoundtrip(c.trace, h, req)
return client.traceRoundtrip(ctx, c.trace, h, req)
}
// NewStream creates a new stream.