Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Ingest Manager] stop creating events-* index pattern and placeholder index #74683

Merged
merged 2 commits into from
Aug 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ export interface IndexPatternField {
export enum IndexPatternType {
logs = 'logs',
metrics = 'metrics',
events = 'events',
}
// TODO: use a function overload and make pkgName and pkgVersion required for install/update
// and not for an update removal. or separate out the functions
Expand Down Expand Up @@ -111,11 +110,7 @@ export async function installIndexPatterns(
const installedPackagesInfo = await Promise.all(installedPackagesFetchInfoPromise);

// for each index pattern type, create an index pattern
const indexPatternTypes = [
IndexPatternType.logs,
IndexPatternType.metrics,
IndexPatternType.events,
];
const indexPatternTypes = [IndexPatternType.logs, IndexPatternType.metrics];
indexPatternTypes.forEach(async (indexPatternType) => {
// if this is an update because a package is being unisntalled (no pkgkey argument passed) and no other packages are installed, remove the index pattern
if (!pkgName && installedPackages.length === 0) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,6 @@ export default function (providerContext: FtrProviderContext) {
id: 'metrics-*',
});
expect(resIndexPatternMetrics.id).equal('metrics-*');
const resIndexPatternEvents = await kibanaServer.savedObjects.get({
type: 'index-pattern',
id: 'events-*',
});
expect(resIndexPatternEvents.id).equal('events-*');
const resDashboard = await kibanaServer.savedObjects.get({
type: 'dashboard',
id: 'sample_dashboard',
Expand All @@ -111,6 +106,18 @@ export default function (providerContext: FtrProviderContext) {
});
expect(resSearch.id).equal('sample_search');
});
it('should have installed placeholder indices', async function () {
const resLogsIndexPatternPlaceholder = await es.transport.request({
method: 'GET',
path: `/logs-index_pattern_placeholder`,
});
expect(resLogsIndexPatternPlaceholder.statusCode).equal(200);
const resMetricsIndexPatternPlaceholder = await es.transport.request({
method: 'GET',
path: `/metrics-index_pattern_placeholder`,
});
expect(resMetricsIndexPatternPlaceholder.statusCode).equal(200);
});
it('should have created the correct saved object', async function () {
const res = await kibanaServer.savedObjects.get({
type: 'epm-packages',
Expand Down