elastic / elastic/apm-server

Index span.db.statement as text

Open
#6,586 24 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Go
Stars
1.3k
Forks
543
Avg merge
1d 18h
Merged PRs (30d)
109

Description

The db statement is really useful, but it would be even more amazingly useful if we could search on it.

So by adding this mapping:

![Screen Shot 2021-11-11 at 13 59 51](https://user-images.githubusercontent.com/690/141240579-b54e520b-acf0-4541-959a-16f6c0acbf94.png)

We should be able to search for spans which have a certain db query structure.

![Screen Shot 2021-11-11 at 14 05 04](https://user-images.githubusercontent.com/690/141240600-ce7c0a29-deee-494d-b4f1-db19d820cf41.png)

One gotcha I seem to be hitting in this test is that I can't search for `jvm` or `heap` . Seems like maybe I'm catching an "ignore_above" but I didn't think they were supposed to kick in on text fields.

Either way, I imagine it'd be quite useful to do things like highlight traces that involved specific query structures (indices, tables, etc).

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.