From 6d86b3863b24df65f2bda398bb316edb3fbf5785 Mon Sep 17 00:00:00 2001 From: Liza K Date: Mon, 13 Jul 2020 09:28:32 +0300 Subject: [PATCH] types --- src/plugins/data/server/search/types.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/plugins/data/server/search/types.ts b/src/plugins/data/server/search/types.ts index 509b18f6ce014..88dfd9681fdf5 100644 --- a/src/plugins/data/server/search/types.ts +++ b/src/plugins/data/server/search/types.ts @@ -21,6 +21,13 @@ import { RequestHandlerContext } from '../../../../core/server'; import { IKibanaSearchResponse, IKibanaSearchRequest } from '../../common/search'; import { IEsSearchRequest, IEsSearchResponse } from './es_search'; +export interface ISearchOptions { + /** + * An `AbortSignal` that allows the caller of `search` to abort a search request. + */ + signal?: AbortSignal; +} + export interface ISearchSetup { /** * Extension point exposed for other plugins to register their own search @@ -38,17 +45,10 @@ export interface ISearchStart { search: ( context: RequestHandlerContext, request: IKibanaSearchRequest, - options: any + options: ISearchOptions ) => Promise; } -export interface ISearchOptions { - /** - * An `AbortSignal` that allows the caller of `search` to abort a search request. - */ - signal?: AbortSignal; -} - /** * Search strategy interface contains a search method that takes in a request and returns a promise * that resolves to a response.