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

[8.6] change remote cluster from data to ftr-remote (#145435) #145473

Merged
merged 1 commit into from
Nov 16, 2022
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 @@ -28,12 +28,12 @@ export default function ({ getService, getPageObjects }) {
});
it('it should be able to access remote data', async () => {
await PageObjects.console.enterRequest(
'\nGET data:makelogs工程-*/_search\n {\n "query": {\n "bool": {\n "must": [\n {"match": {"extension" : "jpg"'
'\nGET ftr-remote:makelogs工程-*/_search\n {\n "query": {\n "bool": {\n "must": [\n {"match": {"extension" : "jpg"'
);
await PageObjects.console.clickPlay();
await retry.try(async () => {
const actualResponse = await PageObjects.console.getResponse();
expect(actualResponse).to.contain('"_index": "data:makelogs工程-0"');
expect(actualResponse).to.contain('"_index": "ftr-remote:makelogs工程-0"');
});
});
});
Expand Down
36 changes: 22 additions & 14 deletions x-pack/test/stack_functional_integration/apps/ccs/ccs_discover.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,20 +113,22 @@ export default ({ getService, getPageObjects }) => {
expect(patternName).to.be('local:makelogs工程*');
});

it('create remote data makelogs index pattern', async () => {
log.debug('create remote data makelogs工程 index pattern');
await PageObjects.settings.createIndexPattern('data:makelogs工程*');
it('create ftr-remote makelogs index pattern', async () => {
log.debug('create ftr-remote makelogs工程 index pattern');
await PageObjects.settings.createIndexPattern('ftr-remote:makelogs工程*');
const patternName = await PageObjects.settings.getIndexPageHeading();
expect(patternName).to.be('data:makelogs工程*');
expect(patternName).to.be('ftr-remote:makelogs工程*');
});

it('create comma separated index patterns for data and local makelogs index pattern', async () => {
it('create comma separated index patterns for ftr-remote and local makelogs index pattern', async () => {
log.debug(
'create comma separated index patterns for data and local makelogs工程 index pattern'
'create comma separated index patterns for ftr-remote and local makelogs工程 index pattern'
);
await PageObjects.settings.createIndexPattern(
'ftr-remote:makelogs工程-*,local:makelogs工程-*'
);
await PageObjects.settings.createIndexPattern('data:makelogs工程-*,local:makelogs工程-*');
const patternName = await PageObjects.settings.getIndexPageHeading();
expect(patternName).to.be('data:makelogs工程-*,local:makelogs工程-*');
expect(patternName).to.be('ftr-remote:makelogs工程-*,local:makelogs工程-*');
});

it('create index pattern for data from both clusters', async () => {
Expand All @@ -147,8 +149,8 @@ export default ({ getService, getPageObjects }) => {
});
});

it('data:makelogs(star) should discover data from remote', async function () {
await PageObjects.discover.selectIndexPattern('data:makelogs工程*');
it('ftr-remote:makelogs(star) should discover data from remote', async function () {
await PageObjects.discover.selectIndexPattern('ftr-remote:makelogs工程*');
await retry.tryForTime(40000, async () => {
const hitCount = await PageObjects.discover.getHitCount();
log.debug('### hit count = ' + hitCount);
Expand All @@ -166,8 +168,10 @@ export default ({ getService, getPageObjects }) => {
});
});

it('data:makelogs-star,local:makelogs-star should discover data from both clusters', async function () {
await PageObjects.discover.selectIndexPattern('data:makelogs工程-*,local:makelogs工程-*');
it('ftr-remote:makelogs-star,local:makelogs-star should discover data from both clusters', async function () {
await PageObjects.discover.selectIndexPattern(
'ftr-remote:makelogs工程-*,local:makelogs工程-*'
);
await retry.tryForTime(40000, async () => {
const hitCount = await PageObjects.discover.getHitCount();
log.debug('### hit count = ' + hitCount);
Expand All @@ -176,7 +180,9 @@ export default ({ getService, getPageObjects }) => {
});

it('should reload the saved search with persisted query to show the initial hit count', async function () {
await PageObjects.discover.selectIndexPattern('data:makelogs工程-*,local:makelogs工程-*');
await PageObjects.discover.selectIndexPattern(
'ftr-remote:makelogs工程-*,local:makelogs工程-*'
);
// apply query some changes
await queryBar.setQuery('success');
await queryBar.submitQuery();
Expand All @@ -190,7 +196,9 @@ export default ({ getService, getPageObjects }) => {
});

it('should add a phrases filter', async function () {
await PageObjects.discover.selectIndexPattern('data:makelogs工程-*,local:makelogs工程-*');
await PageObjects.discover.selectIndexPattern(
'ftr-remote:makelogs工程-*,local:makelogs工程-*'
);
const hitCountNumber = await PageObjects.discover.getHitCount();
const originalHitCount = parseInt(hitCountNumber.replace(/\,/g, ''));
await filterBar.addFilter('extension.keyword', 'is', 'jpg');
Expand Down