mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
[Archive Migration] x-pack logstash/empty (#135123)
* [Archive Migration] x-pack logstash/empty Migrate x-pack logstash/empty Helps with: #102552 This is sorta odd as the archive only has a config and the default space. * Remove the rest. * Already deleting, no need for the clean standard list call. * Already deleting, no need for the delete test. * Drop the created pipeline. * [CI] Auto-commit changed files from 'node scripts/eslint --no-cache --fix' Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
parent
39af11af42
commit
a6f17d5dd2
6 changed files with 12 additions and 336 deletions
|
@ -1,44 +0,0 @@
|
|||
/*
|
||||
* 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; you may not use this file except in compliance with the Elastic License
|
||||
* 2.0.
|
||||
*/
|
||||
|
||||
import { FtrProviderContext } from '../../../ftr_provider_context';
|
||||
|
||||
export default function ({ getService }: FtrProviderContext) {
|
||||
const supertest = getService('supertest');
|
||||
const esArchiver = getService('esArchiver');
|
||||
describe('delete', () => {
|
||||
const archive = 'x-pack/test/functional/es_archives/logstash/empty';
|
||||
|
||||
before('load pipelines archive', async () => {
|
||||
await esArchiver.load(archive);
|
||||
|
||||
await supertest
|
||||
.put('/api/logstash/pipeline/fast_generator')
|
||||
.set('kbn-xsrf', 'xxx')
|
||||
.send({
|
||||
description: 'foobar baz',
|
||||
pipeline: 'input { generator {} }\n\n output { stdout {} }',
|
||||
})
|
||||
.expect(204);
|
||||
|
||||
await supertest.get('/api/logstash/pipeline/fast_generator').expect(200);
|
||||
});
|
||||
|
||||
after('unload pipelines archive', () => {
|
||||
return esArchiver.unload(archive);
|
||||
});
|
||||
|
||||
it('should delete the specified pipeline', async () => {
|
||||
await supertest
|
||||
.delete('/api/logstash/pipeline/fast_generator')
|
||||
.set('kbn-xsrf', 'xxx')
|
||||
.expect(204);
|
||||
|
||||
await supertest.get('/api/logstash/pipeline/fast_generator').expect(404);
|
||||
});
|
||||
});
|
||||
}
|
|
@ -10,6 +10,5 @@ export default function ({ loadTestFile }: FtrProviderContext) {
|
|||
describe('pipeline', () => {
|
||||
loadTestFile(require.resolve('./load'));
|
||||
loadTestFile(require.resolve('./save'));
|
||||
loadTestFile(require.resolve('./delete'));
|
||||
});
|
||||
}
|
||||
|
|
|
@ -10,16 +10,15 @@ import { FtrProviderContext } from '../../../ftr_provider_context';
|
|||
|
||||
export default function ({ getService }: FtrProviderContext) {
|
||||
const supertest = getService('supertest');
|
||||
const esArchiver = getService('esArchiver');
|
||||
|
||||
describe('save', () => {
|
||||
const archive = 'x-pack/test/functional/es_archives/logstash/empty';
|
||||
after('delete created pipeline', async () => {
|
||||
await supertest
|
||||
.delete('/api/logstash/pipeline/fast_generator')
|
||||
.set('kbn-xsrf', 'xxx')
|
||||
.expect(204);
|
||||
|
||||
before('load pipelines archive', () => {
|
||||
return esArchiver.load(archive);
|
||||
});
|
||||
|
||||
after('unload pipelines archive', () => {
|
||||
return esArchiver.unload(archive);
|
||||
await supertest.get('/api/logstash/pipeline/fast_generator').expect(404);
|
||||
});
|
||||
|
||||
it('should create the specified pipeline', async () => {
|
||||
|
|
|
@ -10,25 +10,26 @@ import { omit } from 'lodash';
|
|||
|
||||
export default function ({ getService, getPageObjects }) {
|
||||
const browser = getService('browser');
|
||||
const esArchiver = getService('esArchiver');
|
||||
const random = getService('random');
|
||||
const pipelineList = getService('pipelineList');
|
||||
const pipelineEditor = getService('pipelineEditor');
|
||||
const PageObjects = getPageObjects(['logstash']);
|
||||
const retry = getService('retry');
|
||||
const supertest = getService('supertest');
|
||||
|
||||
describe('pipeline create new', () => {
|
||||
let originalWindowSize;
|
||||
let id;
|
||||
|
||||
before(async () => {
|
||||
id = random.id();
|
||||
originalWindowSize = await browser.getWindowSize();
|
||||
await browser.setWindowSize(1600, 1000);
|
||||
await esArchiver.load('x-pack/test/functional/es_archives/logstash/empty');
|
||||
});
|
||||
|
||||
after(async () => {
|
||||
await esArchiver.unload('x-pack/test/functional/es_archives/logstash/empty');
|
||||
after('delete created pipeline', async () => {
|
||||
await browser.setWindowSize(originalWindowSize.width, originalWindowSize.height);
|
||||
await supertest.delete(`/api/logstash/pipeline/${id}`).set('kbn-xsrf', 'xxx');
|
||||
});
|
||||
|
||||
it('starts with the default values', async () => {
|
||||
|
@ -39,8 +40,6 @@ export default function ({ getService, getPageObjects }) {
|
|||
describe('save button', () => {
|
||||
it('creates the pipeline and redirects to the list', async () => {
|
||||
await PageObjects.logstash.gotoNewPipelineEditor();
|
||||
|
||||
const id = random.id();
|
||||
const description = random.text();
|
||||
const pipeline = random.longText();
|
||||
const workers = random.int().toString();
|
||||
|
|
Binary file not shown.
|
@ -1,277 +0,0 @@
|
|||
{
|
||||
"type": "index",
|
||||
"value": {
|
||||
"aliases": {
|
||||
".kibana": {}
|
||||
},
|
||||
"index": ".kibana_1",
|
||||
"mappings": {
|
||||
"properties": {
|
||||
"config": {
|
||||
"dynamic": "true",
|
||||
"properties": {
|
||||
"buildNum": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"dateFormat:tz": {
|
||||
"fields": {
|
||||
"keyword": {
|
||||
"ignore_above": 256,
|
||||
"type": "keyword"
|
||||
}
|
||||
},
|
||||
"type": "text"
|
||||
},
|
||||
"xPackMonitoring:showBanner": {
|
||||
"type": "boolean"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dashboard": {
|
||||
"dynamic": "strict",
|
||||
"properties": {
|
||||
"description": {
|
||||
"type": "text"
|
||||
},
|
||||
"hits": {
|
||||
"type": "integer"
|
||||
},
|
||||
"kibanaSavedObjectMeta": {
|
||||
"properties": {
|
||||
"searchSourceJSON": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"optionsJSON": {
|
||||
"type": "text"
|
||||
},
|
||||
"panelsJSON": {
|
||||
"type": "text"
|
||||
},
|
||||
"refreshInterval": {
|
||||
"properties": {
|
||||
"display": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"pause": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"section": {
|
||||
"type": "integer"
|
||||
},
|
||||
"value": {
|
||||
"type": "integer"
|
||||
}
|
||||
}
|
||||
},
|
||||
"timeFrom": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"timeRestore": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"timeTo": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"title": {
|
||||
"type": "text"
|
||||
},
|
||||
"uiStateJSON": {
|
||||
"type": "text"
|
||||
},
|
||||
"version": {
|
||||
"type": "integer"
|
||||
}
|
||||
}
|
||||
},
|
||||
"graph-workspace": {
|
||||
"properties": {
|
||||
"description": {
|
||||
"type": "text"
|
||||
},
|
||||
"kibanaSavedObjectMeta": {
|
||||
"properties": {
|
||||
"searchSourceJSON": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"numLinks": {
|
||||
"type": "integer"
|
||||
},
|
||||
"numVertices": {
|
||||
"type": "integer"
|
||||
},
|
||||
"title": {
|
||||
"type": "text"
|
||||
},
|
||||
"version": {
|
||||
"type": "integer"
|
||||
},
|
||||
"wsState": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"index-pattern": {
|
||||
"dynamic": "strict",
|
||||
"properties": {
|
||||
"fieldFormatMap": {
|
||||
"type": "text"
|
||||
},
|
||||
"fields": {
|
||||
"type": "text"
|
||||
},
|
||||
"intervalName": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"notExpandable": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"sourceFilters": {
|
||||
"type": "text"
|
||||
},
|
||||
"timeFieldName": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"title": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"search": {
|
||||
"dynamic": "strict",
|
||||
"properties": {
|
||||
"columns": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"description": {
|
||||
"type": "text"
|
||||
},
|
||||
"hits": {
|
||||
"type": "integer"
|
||||
},
|
||||
"kibanaSavedObjectMeta": {
|
||||
"properties": {
|
||||
"searchSourceJSON": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"sort": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"title": {
|
||||
"type": "text"
|
||||
},
|
||||
"version": {
|
||||
"type": "integer"
|
||||
}
|
||||
}
|
||||
},
|
||||
"server": {
|
||||
"dynamic": "strict",
|
||||
"properties": {
|
||||
"uuid": {
|
||||
"type": "keyword"
|
||||
}
|
||||
}
|
||||
},
|
||||
"space": {
|
||||
"properties": {
|
||||
"_reserved": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"color": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"description": {
|
||||
"type": "text"
|
||||
},
|
||||
"disabledFeatures": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"initials": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"name": {
|
||||
"fields": {
|
||||
"keyword": {
|
||||
"ignore_above": 2048,
|
||||
"type": "keyword"
|
||||
}
|
||||
},
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"spaceId": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"type": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"url": {
|
||||
"dynamic": "strict",
|
||||
"properties": {
|
||||
"accessCount": {
|
||||
"type": "long"
|
||||
},
|
||||
"accessDate": {
|
||||
"type": "date"
|
||||
},
|
||||
"createDate": {
|
||||
"type": "date"
|
||||
},
|
||||
"url": {
|
||||
"fields": {
|
||||
"keyword": {
|
||||
"ignore_above": 2048,
|
||||
"type": "keyword"
|
||||
}
|
||||
},
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"visualization": {
|
||||
"dynamic": "strict",
|
||||
"properties": {
|
||||
"description": {
|
||||
"type": "text"
|
||||
},
|
||||
"kibanaSavedObjectMeta": {
|
||||
"properties": {
|
||||
"searchSourceJSON": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
},
|
||||
"savedSearchId": {
|
||||
"type": "keyword"
|
||||
},
|
||||
"title": {
|
||||
"type": "text"
|
||||
},
|
||||
"uiStateJSON": {
|
||||
"type": "text"
|
||||
},
|
||||
"version": {
|
||||
"type": "integer"
|
||||
},
|
||||
"visState": {
|
||||
"type": "text"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"settings": {
|
||||
"index": {
|
||||
"number_of_replicas": "1",
|
||||
"number_of_shards": "1"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue