Cleanup after #59886

This commit is contained in:
Rudolf Meijering 2020-03-17 12:35:58 +01:00
parent 5b7039a855
commit 06c19f57b4
2 changed files with 13 additions and 6 deletions

View file

@ -33,7 +33,12 @@ import { CoreService } from '../../types';
import { merge } from '../../utils';
import { CoreContext } from '../core_context';
import { Logger } from '../logging';
import { ClusterClient, ScopeableRequest } from './cluster_client';
import {
ClusterClient,
ScopeableRequest,
IClusterClient,
ICustomClusterClient,
} from './cluster_client';
import { ElasticsearchClientConfig } from './elasticsearch_client_config';
import { ElasticsearchConfig, ElasticsearchConfigType } from './elasticsearch_config';
import { InternalHttpServiceSetup, GetAuthHeaders } from '../http/';
@ -57,12 +62,14 @@ export class ElasticsearchService
implements CoreService<InternalElasticsearchServiceSetup, ElasticsearchServiceStart> {
private readonly log: Logger;
private readonly config$: Observable<ElasticsearchConfig>;
private subscription: Subscription | undefined;
private subscription?: Subscription;
private stop$ = new Subject();
private kibanaVersion: string;
createClient: InternalElasticsearchServiceSetup['createClient'] | undefined;
dataClient: InternalElasticsearchServiceSetup['dataClient'] | undefined;
adminClient: InternalElasticsearchServiceSetup['adminClient'] | undefined;
private createClient?: (
type: string,
clientConfig?: Partial<ElasticsearchClientConfig>
) => ICustomClusterClient;
private adminClient?: IClusterClient;
constructor(private readonly coreContext: CoreContext) {
this.kibanaVersion = coreContext.env.packageInfo.version;

View file

@ -186,7 +186,7 @@ export class Server {
uiSettings: uiSettingsStart,
};
const pluginsStart = await this.plugins.start(this.coreStart!);
const pluginsStart = await this.plugins.start(this.coreStart);
await this.legacy.start({
core: {