Skip to content

Deprecate Migration Assistance and Upgrade APIs #40072

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

Merged
merged 9 commits into from
Mar 15, 2019

Conversation

gwbrown
Copy link
Contributor

@gwbrown gwbrown commented Mar 14, 2019

The Migration Assistance API has been functionally replaced with the
Deprecation Info API, and the Migration Upgrade API is not in use for
the 6.x to 7.x upgrade, and may or may not be used for the 7.x to 8.x
upgrade. It is currently only useful for repairing clusters which were not
properly prepared for the 5.x to 6.x upgrade.
Therefore, these APIs are now deprecated, and the docs are updated
to point users to the correct resources for preparing for an upgrade to 7.x.

Relates to #40014

gwbrown added 2 commits March 14, 2019 14:31
The Migration Assistance API has been functionally replaced with the
Deprecation Info API, and the Migration Upgrade API is not in use for
the 6.x to 7.x upgrade, and may not be used for the 7.x to 8.x upgrade.
It is currently only useful for repairing clusters which were not
properly prepared for the 5.x to 6.x upgrade. Therefore, these APIs are
deprecated.
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-features

@gwbrown
Copy link
Contributor Author

gwbrown commented Mar 14, 2019

This also needs to deprecate the appropriate HLRC classes. Done

@@ -6,8 +6,13 @@
<titleabbrev>Migration assistance</titleabbrev>
++++

The Migration Assistance API analyzes existing indices in the cluster and
returns the information about indices that require some changes before the
IMPORTANT: The Migration Assistance API is deprecated, use the
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If someone uses this API in 6.7, will it return correct information ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've made a tweak to this to make sure the behavior aligns, but as of this PR, if used in 6.7, this API will correctly identify which indices need to be reindexed, including internal indices. It will only say that indices need to be "upgraded" if they were not properly upgraded before upgrading the cluster to 6 and need to be fixed using the Migration Upgrade API.

deprecated[6.7, Use the {kibana-ref}/upgrade-assistant.html[{kib} Upgrade
Assistant] or <<reindex-upgrade,Reindex manually>> before upgrading.] The
Migration Upgrade API performs the upgrade of internal indices to make them
compatible with version 6 of Elasticsearch.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If someone uses this API in 6.7 will it work correctly ?

Copy link
Contributor Author

@gwbrown gwbrown Mar 15, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've made a tweak to this to make sure the behavior aligns, but as of this PR, if used in 6.7, the Upgrade API will only upgrade indices that need to be upgraded from their 5.x format (i.e. they were not upgraded before upgrading the cluster). Otherwise, it will just say that the index needs to be reindexed.

That is, if the .watches-6 index was created and upgraded in 5.x, the Upgrade API will refuse to upgrade it and just say that it needs to be reindexed.

@jakelandis
Copy link
Contributor

jakelandis commented Mar 15, 2019

A couple questions, but would also like a thumbs up from @bleskes on this and the related #40075

EDIT: got a SGTM for this direction

Copy link
Contributor

@jakelandis jakelandis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

lcawl and others added 4 commits March 15, 2019 11:26
Co-Authored-By: gwbrown <gordon.brown@elastic.co>
Co-Authored-By: gwbrown <gordon.brown@elastic.co>
Co-Authored-By: gwbrown <gordon.brown@elastic.co>
Co-Authored-By: gwbrown <gordon.brown@elastic.co>
@gwbrown
Copy link
Contributor Author

gwbrown commented Mar 15, 2019

Thanks for the corrections @lcawl!

@lcawl
Copy link
Contributor

lcawl commented Mar 15, 2019

I've created the following PR to make similar changes in the Installation and Upgrade Guide: elastic/stack-docs#247

Copy link
Contributor

@lcawl lcawl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Documentation LGTM and builds successfully

@gwbrown gwbrown merged commit 101d780 into elastic:6.7 Mar 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants