Skip to content

Query Analytics logging docs#5039

Open
smalyshev wants to merge 26 commits intomainfrom
logs-docs
Open

Query Analytics logging docs#5039
smalyshev wants to merge 26 commits intomainfrom
logs-docs

Conversation

@smalyshev
Copy link
Contributor

@smalyshev smalyshev commented Feb 6, 2026

Documents Query Analytics logging - the capability to log every query run on the cluster.

@smalyshev smalyshev requested a review from a team as a code owner February 6, 2026 02:08
@smalyshev smalyshev added the documentation Improvements or additions to documentation label Feb 6, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Feb 6, 2026

Vale Linting Results

Summary: 4 warnings, 11 suggestions found

⚠️ Warnings (4)
File Line Rule Message
deploy-manage/monitor/logging-configuration/query-logs.md 56 Elastic.DontUse Don't use 'Note that'.
deploy-manage/monitor/logging-configuration/query-logs.md 153 Elastic.Latinisms Latin terms and abbreviations are a common source of confusion. Use 'for example' instead of 'e.g'.
deploy-manage/monitor/logging-configuration/query-logs.md 157 Elastic.DontUse Don't use 'Thus'.
deploy-manage/monitor/logging-configuration/query-logs.md 157 Elastic.DontUse Don't use 'very'.
💡 Suggestions (11)
File Line Rule Message
deploy-manage/monitor/logging-configuration/query-logs.md 32 Elastic.WordChoice Consider using 'deactivates, deselects, hides, turns off, makes unavailable' instead of 'disables', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 32 Elastic.WordChoice Consider using 'deactivated, deselected, hidden, turned off, unavailable' instead of 'disabled', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 34 Elastic.WordChoice Consider using 'deactivates, deselects, hides, turns off, makes unavailable' instead of 'disables', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 35 Elastic.WordChoice Consider using 'deactivates, deselects, hides, turns off, makes unavailable' instead of 'disables', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 56 Elastic.WordChoice Consider using 'can, might' instead of 'may', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 56 Elastic.WordChoice Consider using 'can, might' instead of 'May', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 56 Elastic.WordChoice Consider using 'can, might' instead of 'may', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 65 Elastic.WordChoice Consider using 'can, might' instead of 'may', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 67 Elastic.WordChoice Consider using 'can, might' instead of 'may', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 157 Elastic.WordChoice Consider using 'deactivate, deselect, hide, turn off' instead of 'disable', unless the term is in the UI.
deploy-manage/monitor/logging-configuration/query-logs.md 159 Elastic.WordChoice Consider using 'can, might' instead of 'may', unless the term is in the UI.

The Vale linter checks documentation changes against the Elastic Docs style guide.

To use Vale locally or report issues, refer to Elastic style guide for Vale.

@github-actions
Copy link
Contributor

github-actions bot commented Feb 6, 2026

@shainaraskas
Copy link
Collaborator

@smalyshev still WIP? if so, please mark this as a draft until it's ready for review

@smalyshev smalyshev marked this pull request as draft February 6, 2026 22:51
@github-actions github-actions bot requested a deployment to docs-preview February 12, 2026 21:00 Abandoned
@smalyshev smalyshev changed the title Query Analytics logging docs [WIP] Query Analytics logging docs Feb 13, 2026
Copy link
Contributor

@consulthys consulthys left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added some comments

Copy link
Contributor

@naj-h naj-h left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've done a first round of reviews. Let me know once ready for another review!

- `elasticsearch.activitylog.type`: The type of operation (`search`, `esql`, etc.).
- `elasticsearch.activitylog.took`: How long (in nanoseconds) the request took to complete.
- `elasticsearch.activitylog.took_millis`: How long (in milliseconds) the request took to complete.
- Additional fields specific to {{es}} environment may be added, for example:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hum.. I don't understand why we put this sentence

  • elasticsearch.activitylog.query is an additional field specific to ES -> isn't it the case of all of the other fields starting with elasticsearch.activitylog?
  • and why do we say "may" -> isn't it always added?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Elastic logging module adds all kinds of stuff like this:

  "elasticsearch.cluster.uuid": "gjYgb-uQQAuLmDoKlQInZw",
  "elasticsearch.node.id": "juurGSfgRYGwTP2ttZbtOQ",
  "elasticsearch.node.name": "node-1",
  "elasticsearch.cluster.name": "querying"

we don't really have any control over it, so I don't want to get into too much details here.

@shainaraskas shainaraskas requested a review from a team March 5, 2026 20:07
elasticsearch.actionlog.enabled: true
```

By default, search (`dsl`) queries that query only system indices are not logged. To enable logging of such queries, use the `elasticsearch.actionlog.search.include.system_indices` setting described below.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why only DSL? why would we make a differential behaviour between search and ES|QL?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This behavior does not happen on ESQL for several reasons:

  1. It's irrelevant since Kibana (main source of system noise) does not use ESQL for that
  2. It's harder to find out which indices ESQL is using, since you need to parse the query for it.

smalyshev and others added 3 commits March 11, 2026 10:45
Co-authored-by: Najwa Harif <90753689+naj-h@users.noreply.github.com>
Co-authored-by: Najwa Harif <90753689+naj-h@users.noreply.github.com>
Co-authored-by: Najwa Harif <90753689+naj-h@users.noreply.github.com>
smalyshev and others added 3 commits March 11, 2026 10:49
Co-authored-by: Najwa Harif <90753689+naj-h@users.noreply.github.com>
Co-authored-by: Najwa Harif <90753689+naj-h@users.noreply.github.com>
Co-authored-by: Najwa Harif <90753689+naj-h@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants