Skip to content

Log slow queries as json, not binary. #12992

@vvcephei

Description

@vvcephei

In the Java client, you can compose the query either by adding String source chunks or by using another builder, like the Aggregation builder and adding the aggregation to the query. There is a quirk, though: if you use a builder, the only way to contribute it to the query is to first turn it into a byte[]. When you do this, the query ultimately gets logged as half-json, half-binary-string in the slow query log.

That isn't a problem, per se, but it's annoying when you're trying to analyze the logs.

I have no opinion about how the query objects are stored in memory, but it would be nice if the slow query log (and full query log if #9172 comes to pass) would log a human readable query.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions