Skip to content

Feature request: maximum size for dbStatement in OTEL #3448

@Cyberax

Description

@Cyberax

Current Behavior

The OTEL instrumentation has support for DB query tracing:

if th.conf.dbStmtEnabled {

This works well until a large object (a large image, in our case) is inserted into Redis. Then it can clog up the metric exporter.

Possible Solution

Add an option to cut the DB statement to a reasonable size. Something like WithDBStatementMaxSize(n int) that would preserve the initial n/2 and the final n/2 characters from the query.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions