* remove unnecessary ts-ignore * add context propagation to x-opaque-id header tests * run tests on CI * simplify logging. the action purpose follows from the context name * extend tests with the assertion against execution_context from the Kibana logs * split JSON log records only * apply suggestions proposed by Spencer
34 lines
1 KiB
TypeScript
34 lines
1 KiB
TypeScript
/*
|
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
* Side Public License, v 1.
|
|
*/
|
|
|
|
import { EsArchiver } from '@kbn/es-archiver';
|
|
import { FtrProviderContext } from '../ftr_provider_context';
|
|
import * as KibanaServer from './kibana_server';
|
|
|
|
export function EsArchiverProvider({ getService }: FtrProviderContext): EsArchiver {
|
|
const config = getService('config');
|
|
const client = getService('es');
|
|
const log = getService('log');
|
|
const kibanaServer = getService('kibanaServer');
|
|
const retry = getService('retry');
|
|
|
|
const esArchiver = new EsArchiver({
|
|
client,
|
|
log,
|
|
kbnClient: kibanaServer,
|
|
});
|
|
|
|
KibanaServer.extendEsArchiver({
|
|
esArchiver,
|
|
kibanaServer,
|
|
retry,
|
|
defaults: config.get('uiSettings.defaults'),
|
|
});
|
|
|
|
return esArchiver;
|
|
}
|