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

Deprecate _upgrade API (#47678) #50484

Merged
merged 2 commits into from
Jan 17, 2020
Merged

Conversation

timoninmaxim
Copy link
Contributor

@timoninmaxim timoninmaxim commented Dec 24, 2019

Issue comment #47678

Suggest deprecate Upgrade API instead of implementing high-level API for it.

@timoninmaxim timoninmaxim changed the title Deprecates _update API (#47678) Deprecates _upgrade API (#47678) Dec 24, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-features (:Core/Features/Java High Level REST Client)

@martijnvg martijnvg requested a review from dakrone January 9, 2020 15:34
Copy link
Member

@dakrone dakrone left a comment

Choose a reason for hiding this comment

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

Thanks for opening this @timoninmaxim, I left a couple of comments. I don't think we need to rename the classes here, just annotate them with @Deprecated

Copy link
Member

@dakrone dakrone left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@dakrone dakrone left a comment

Choose a reason for hiding this comment

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

LGTM

@dakrone
Copy link
Member

dakrone commented Jan 10, 2020

@elasticmachine ok to test

Copy link
Member

@dakrone dakrone left a comment

Choose a reason for hiding this comment

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

Looks like there are some test failures as a result of this change.

@@ -47,6 +47,10 @@
"default":"open",
"description":"Whether to expand wildcard expression to concrete indices that are open, closed or both."
}
},
"deprecated":{
Copy link
Member

Choose a reason for hiding this comment

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

It appears that this field causes all sorts of test failures. I believe only the "parts" sub-objects support deprecations in the REST spec for now, so this should be removed and "DEPRECATED" added to the description

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is my fault, I used wrong gradle check command and missed this tests. So, I've fixed it and some other tests in new commit.

Copy link
Contributor Author

@timoninmaxim timoninmaxim Jan 11, 2020

Choose a reason for hiding this comment

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

I used this doc for deprecation: https://github.com/elastic/elasticsearch/tree/master/rest-api-spec#deprecations. Currenlty it incorrectly shows how to deprecate entire API. Is it a inaccuracy in the documentation or bug in a code?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

hi @dakrone ! Could you please check my last comment above? Should we do smth with that the doc is incorrect?

@@ -55,6 +55,10 @@
"type":"boolean",
"description":"If true, only ancient (an older Lucene major release) segments will be upgraded"
}
},
"deprecated":{
Copy link
Member

Choose a reason for hiding this comment

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

Same comment about deprecation here

Copy link
Member

@dakrone dakrone left a comment

Choose a reason for hiding this comment

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

LGTM

@dakrone dakrone merged commit 09ebc11 into elastic:master Jan 17, 2020
@dakrone
Copy link
Member

dakrone commented Jan 17, 2020

Thanks for iterating on this @timoninmaxim!

@timoninmaxim timoninmaxim deleted the fork/master branch January 20, 2020 07:38
SivagurunathanV pushed a commit to SivagurunathanV/elasticsearch that referenced this pull request Jan 23, 2020
* Deprecates _upgrade API

Ref elastic#47678

* Move deprecation flags to path section. Add deprecation warning tests for _upgrade API.

Ref elastic#47678
@danhermann danhermann added :Data Management/Indices APIs APIs to create and manage indices and templates backport pending v7.11.0 labels Nov 5, 2020
@elasticmachine elasticmachine added the Team:Data Management Meta label for data/management team label Nov 5, 2020
danhermann pushed a commit to danhermann/elasticsearch that referenced this pull request Nov 5, 2020
* Deprecates _upgrade API

Ref elastic#47678

* Move deprecation flags to path section. Add deprecation warning tests for _upgrade API.

Ref elastic#47678
@pugnascotia pugnascotia changed the title Deprecates _upgrade API (#47678) Deprecate _upgrade API (#47678) Jan 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Data Management/Indices APIs APIs to create and manage indices and templates >deprecation Team:Data Management Meta label for data/management team v7.11.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants