elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.99k stars 8.24k forks source link

[ResponseOps][Connectors] Improve error logging for ES query #150450

Open jonathan-buttner opened 1 year ago

jonathan-buttner commented 1 year ago

The searchSource.fetch used here: https://github.com/elastic/kibana/blob/main/x-pack/plugins/stack_alerts/server/rule_types/es_query/lib/fetch_search_source_query.ts#L74 logging should be improved to include more details when an error is returned by Elasticsearch. For example when an error is returned by Elasticsearch because a time range filter fails based on the date format within the mapping, a generic error message is displayed: has resulted in Error: status_exception - Error: status_exception at getKbnServerError

This error message should be improved to include more details that will help triage exactly what is causing the error.

elasticmachine commented 1 year ago

Pinging @elastic/response-ops (Team:ResponseOps)

elasticmachine commented 1 year ago

Pinging @elastic/kibana-data-discovery (Team:DataDiscovery)

kertal commented 1 year ago

removing @elastic/kibana-data-discovery because it's already assigned to @JiaweiWu , feed free to reach out if you've got questions about this

ymao1 commented 2 months ago

@JiaweiWu Is this something you're working on?