Skip to content

[EQLSearchStrategy] Clean up and align with other async strategies  #128635

Open

Description

Similar like we did to low level SQL strategy, we should clean up EQL search strategy and align it with other async strategies:

Ideally we should do it before wider adoption in Kibana (unified search).

Here is the list of possible alignment things:

  • Is it Required to return both headers + body in the response?
    export type EqlSearchStrategyResponse<T = unknown> = IKibanaSearchResponse<TransportResult<T>>;
    . Can we do body + warning as in other strategies?
  • Can we better type it using EqlSearchResponse ?
  • Don't use deprecatated typesWithBodyKey format
  • Type search request with EqlSearchRequest and EqlGetRequest
  • Don't provide unsupported by strategies params / options to avoid ts-ignore:
    : // @ts-expect-error optional key cannot be used since search doesn't expect undefined
    . Make params explicit
  • Properly use submit / get async utils
  • Add example plugin
  • Add function test for example plugin
  • Add API test for search strategy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Feature:SearchQuerying infrastructure in KibanaTeam:DataDiscoveryDiscover App Team (Document Explorer, Saved Search, Surrounding documents, Data, DataViews)impact:lowAddressing this issue will have a low level of impact on the quality/strength of our product.loe:mediumMedium Level of Efforttechnical debtImprovement of the software architecture and operational architecture

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions