You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to implement datadog tracing support for pgx (DataDog/dd-trace-go#1537 FYI), and the BatchTracer interface is
// BatchTracer traces SendBatch.typeBatchTracerinterface {
// TraceBatchStart is called at the beginning of SendBatch calls. The returned context is used for the// rest of the call and will be passed to TraceBatchQuery and TraceBatchEnd.TraceBatchStart(ctx context.Context, conn*Conn, dataTraceBatchStartData) context.ContextTraceBatchQuery(ctx context.Context, conn*Conn, dataTraceBatchQueryData)
TraceBatchEnd(ctx context.Context, conn*Conn, dataTraceBatchEndData)
}
I'm just wondering why don't we have the start/end of the individual query, and should we? I'm sorry if this is how batch query works in the protocol, kindly let me know. Without the end, I'm afraid it might be hard to know when the individual query ends.
The text was updated successfully, but these errors were encountered:
That's how the batch system works with the PostgreSQL protocol. All queries are sent at once. We know when we send them all, and we know when we finish receiving any individual query. TraceBatchQuery lets you trace when a query is finished, but there is no way to know when a query started.
I'm trying to implement datadog tracing support for pgx (DataDog/dd-trace-go#1537 FYI), and the BatchTracer interface is
I'm just wondering why don't we have the start/end of the individual query, and should we? I'm sorry if this is how batch query works in the protocol, kindly let me know. Without the end, I'm afraid it might be hard to know when the individual query ends.
The text was updated successfully, but these errors were encountered: