forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[UA] Support Deprecated Data Streams Migrations (elastic#202204)
## Summary - [x] Fix UA currently failing to return upgrade status - [x] Support surfacing `data_streams` migrations in UA under the ES tab - [x] Refactor code for better readablity - [x] Add more test cases across the board for all the es migrations status feature in UA - [x] Add a `featureSet.migrateDataStreams` to enable surfacing data streams migrations - [x] Surface data streams in UA UI - [x] Take screenshots for a product review discussions - [x] Unskip api_integration test cases ### Imporant Notes ES deprecations are hidden behind the `featureSet` flag and will only be shown in `8.last` for users. This gives us time to review the copy and implement the corrective action for reindexing data streams which is still pending implementaiton from ES side. For now we will merge this to unblock upgrades in `8.17` and support surfacing data_streams deprecations and add tests. Follow up work for `8.18` - Add integration Tests - Update copy of flyout and documentation link - Reindexing data streams corrective action closes elastic/kibana-team#1293 ## Screenshots #### Overview Page <img width="683" alt="image" src="https://github.com/user-attachments/assets/246d89ac-02cd-4813-ba38-e2e28df00c8d"> #### Elasticsearch deprecation issues Page <img width="1453" alt="image" src="https://github.com/user-attachments/assets/b5fd5f15-fa44-4acb-b7ff-4973593dcfbb"> #### Data streams deprecation details flyout <img width="778" alt="image" src="https://github.com/user-attachments/assets/af343f69-7e76-4c91-a6e3-cff29e26df59"> --------- Co-authored-by: kibanamachine <[email protected]>
- Loading branch information
1 parent
3765479
commit 3e7fb18
Showing
19 changed files
with
743 additions
and
502 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
77 changes: 77 additions & 0 deletions
77
x-pack/plugins/upgrade_assistant/server/lib/__fixtures__/es_deprecations.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
/* | ||
* 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. | ||
*/ | ||
|
||
export const getMockEsDeprecations = () => { | ||
return { | ||
cluster_settings: [], | ||
node_settings: [], | ||
ml_settings: [], | ||
index_settings: {}, | ||
data_streams: {}, | ||
}; | ||
}; | ||
|
||
export const getMockMlSettingsDeprecations = () => { | ||
return { | ||
ml_settings: [ | ||
{ | ||
level: 'warning', | ||
message: 'Datafeed [deprecation-datafeed] uses deprecated query options', | ||
url: 'https://www.elastic.co/guide/en/elasticsearch/reference/master/breaking-changes-7.0.html#breaking_70_search_changes', | ||
details: | ||
'[Deprecated field [use_dis_max] used, replaced by [Set [tie_breaker] to 1 instead]]', | ||
// @ts-ignore | ||
resolve_during_rolling_upgrade: false, | ||
}, | ||
{ | ||
level: 'critical', | ||
message: | ||
'model snapshot [1] for job [deprecation_check_job] needs to be deleted or upgraded', | ||
url: '', | ||
details: 'details', | ||
// @ts-ignore | ||
_meta: { snapshot_id: '1', job_id: 'deprecation_check_job' }, | ||
// @ts-ignore | ||
resolve_during_rolling_upgrade: false, | ||
}, | ||
], | ||
}; | ||
}; | ||
|
||
export const getMockDataStreamDeprecations = () => { | ||
return { | ||
data_streams: { | ||
'my-v7-data-stream': [ | ||
{ | ||
level: 'critical', | ||
message: 'Old data stream with a compatibility version < 8.0', | ||
url: 'https://www.elastic.co/guide/en/elasticsearch/reference/master/breaking-changes-9.0.html', | ||
details: | ||
'This data stream has backing indices that were created before Elasticsearch 8.0.0', | ||
resolve_during_rolling_upgrade: false, | ||
_meta: { | ||
backing_indices: { | ||
count: 52, | ||
need_upgrading: { | ||
count: 37, | ||
searchable_snapshot: { | ||
count: 23, | ||
fully_mounted: { | ||
count: 7, | ||
}, | ||
partially_mounted: { | ||
count: 16, | ||
}, | ||
}, | ||
}, | ||
}, | ||
}, | ||
}, | ||
], | ||
}, | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.