Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Investigate indexing span.context.db.* #1371

Closed
simitt opened this issue Sep 10, 2018 · 13 comments
Closed

Investigate indexing span.context.db.* #1371

simitt opened this issue Sep 10, 2018 · 13 comments
Labels

Comments

@simitt
Copy link
Contributor

simitt commented Sep 10, 2018

Currently span.context.db.* properties are stored but not indexed in ES. This makes it impossible to query/aggregate on them, which might be helpful for multiple use cases (aggregate on them to figure out occurence of queries per type, problematic instances, etc.).

Suggested solution:

attribute type description index type limit (server) limit (agent) note
instance string db instance name keyword 1024 1024  -
user string username for accessing db keyword 1024 1024 -  
type string database type keyword 1024  1024 -
statement string concrete query text none ? should be sanitized for grouping
@alvarolobato
Copy link

We discussed this in the server meeting. Originally these fields were removed from the indexes because we where concerned for the disk space usage. We've decided to document how to add these fields to the index in fields.yml instead of indexing it by default.

@graphaelli
Copy link
Member

After some investigation and discussion with the beats team, the fields.yml approach seems too manual and error prone to be the right long-term solution. Most notably, upgrades become very manual, with merging new fields with user-modified fields.yml.

Adding discuss label for brainstorming alternative solutions.

@roncohen
Copy link
Contributor

any chance the discussion is available somewhere?

@roncohen
Copy link
Contributor

there's setup.template.append_fields which allows users to add arbitrary fields to the template: https://www.elastic.co/guide/en/beats/filebeat/6.x/configuration-template.html

seems slightly better than asking people to edit their fields.yml

@simitt
Copy link
Contributor Author

simitt commented Sep 25, 2018

This is still marked as experimental though (although it landed quite a while ago, see https://github.com/elastic/beats/pull/6024/files). Did you talk to the beats team if there are plans to make this feature stable?

@roncohen
Copy link
Contributor

Related: elastic/beats#8607

@roncohen
Copy link
Contributor

@ruflin @urso any input on the future plans for “append_fields”?

@ruflin
Copy link
Contributor

ruflin commented Oct 13, 2018

+1 on making append_fields GA. The main challenge I see around it is that users will add fields after they did run the Beat for the first and will have to overwrite the template to make use of it. We should solve this by docs and think about other options how to raise awareness.

@simitt
Copy link
Contributor Author

simitt commented Feb 26, 2020

The docs already mention when append_fields can be used, how to overwrite the template and when template changes are applied. With elastic/beats#16576 the experimental flag from append_fields will be removed.

@tobiasstadler
Copy link
Contributor

What is the status? Are their plans to index the fields by default?

@simitt
Copy link
Contributor Author

simitt commented May 18, 2021

@tobiasstadler we don't have any plans to index additional span fields, but the setup.template.append_fields setting has been released as GA for a while. Are you able to achieve what you need by making use of this setting?

@tobiasstadler
Copy link
Contributor

@smith Yes, that works for me. Thank You!

@simitt
Copy link
Contributor Author

simitt commented May 18, 2021

Closing this issue since we don't have plans to work on this.

@simitt simitt closed this as completed May 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants