-
Notifications
You must be signed in to change notification settings - Fork 107
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 legacy API #390
Deprecate legacy API #390
Conversation
Looks like some documentation changes came along that you didn't mean to? If the API doesn't work (users get an error today if they call it?), you can delete it I think. This is why we need to be using a code generator from spec ... is this code generated by any chance? |
Are you referring to the code 27-31 for the unneeded documentation? I working on another issue to modify/create the generator #284. To my knowledge, this is not generated code. @VachaShah please correct me if I am wrong? |
Yeah for the generator part, this code used to be generated before the fork but not anymore. @tannerjones4075 is working on getting the generator going so these kind of bugs don't crop up. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried to make it clearer.
@dblock or @VachaShah is this good to merge? |
No, you need to rebase this PR and it shouldn't include the unrelated docker documentation change, just the deprecated parts. Look at the GitHub diff to make sure you got the right things - let us know if you need help! |
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
22d0c71
to
48c0af8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM.
Can you explain what "uses a nonexistent legacy REST API (/_template) correct REST API is /_index_template use IndicesPutSettings instead" actually means? When I read it, to me it sounds like these methods use something that doesn't work. What am I missing?
There is a legacy API that currently works but it creates confusion as there is a new API. Deprecating the legacy API that creates confusion among current user will and shift them to the new API. As @Jakob3xD explained that deprecation is correct. |
I'm leaving this to @Jakob3xD to review/merge! Thanks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you also please update all the other template files.
- opensearchapi/api.indices.get_template.go
- opensearchapi/api.indices.exists_template.go
- opensearchapi/api.indices.delete_template.go
Co-authored-by: Jakob <jakob.hahn@hetzner.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
I have added the deprecated statement to above locations. |
…d back in IndicesExistsTemplate that was delete by mistake Signed-off-by: Tanner Jones <alltechguyblog@gmail.com>
* deprecated legacy REST API /_template Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * deprecated legacy REST API /_template Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * removed deprecated header at the top of the doc Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * added deprecated notes to the CHANGELOG.md Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Corrected deprecation statement Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Update CHANGELOG.md Co-authored-by: Jakob <jakob.hahn@hetzner.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> * Updated deprecated message on api.indices.put_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.exists_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.delete_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.get_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updated deprecated message on api.indices.exists_template.go and added back in IndicesExistsTemplate that was delete by mistake Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> --------- Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> Co-authored-by: Jakob <jakob.hahn@hetzner.com>
* deprecated legacy REST API /_template Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * deprecated legacy REST API /_template Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * removed deprecated header at the top of the doc Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * added deprecated notes to the CHANGELOG.md Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Corrected deprecation statement Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Update CHANGELOG.md Co-authored-by: Jakob <jakob.hahn@hetzner.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> * Updated deprecated message on api.indices.put_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.exists_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.delete_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.get_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updated deprecated message on api.indices.exists_template.go and added back in IndicesExistsTemplate that was delete by mistake Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> --------- Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> Co-authored-by: Jakob <jakob.hahn@hetzner.com> Signed-off-by: Vacha Shah <vachshah@amazon.com>
* tannerjones4075- update developer guide (#385) * Updating DEVELOPER_GUIDE.md file to include docker build instructions Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updating DEVELOPER_GUIDE.md file to include docker build instructions Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updating DEVELOPER_GUIDE.md file and CHANGELOG Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Removed link from localhost:9200 Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> --------- Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> Signed-off-by: Vacha Shah <vachshah@amazon.com> * Bump github.com/aws/aws-sdk-go from 1.45.20 to 1.45.24 (#387) * Bump github.com/aws/aws-sdk-go from 1.45.20 to 1.45.24 Bumps [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go) from 1.45.20 to 1.45.24. - [Release notes](https://github.com/aws/aws-sdk-go/releases) - [Commits](aws/aws-sdk-go@v1.45.20...v1.45.24) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Update changelog Signed-off-by: dependabot[bot] <support@github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> * Bump github.com/aws/aws-sdk-go-v2 from 1.21.0 to 1.21.1 (#388) * Bump github.com/aws/aws-sdk-go-v2 from 1.21.0 to 1.21.1 Bumps [github.com/aws/aws-sdk-go-v2](https://github.com/aws/aws-sdk-go-v2) from 1.21.0 to 1.21.1. - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Commits](aws/aws-sdk-go-v2@v1.21.0...v1.21.1) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go-v2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Update changelog Signed-off-by: dependabot[bot] <support@github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> * Bump github.com/aws/aws-sdk-go-v2/config from 1.18.43 to 1.18.44 (#389) * Bump github.com/aws/aws-sdk-go-v2/config from 1.18.43 to 1.18.44 Bumps [github.com/aws/aws-sdk-go-v2/config](https://github.com/aws/aws-sdk-go-v2) from 1.18.43 to 1.18.44. - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Commits](aws/aws-sdk-go-v2@config/v1.18.43...config/v1.18.44) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go-v2/config dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Update changelog Signed-off-by: dependabot[bot] <support@github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> * Bump golang.org/x/net from 0.7.0 to 0.17.0 (#391) * Bump golang.org/x/net from 0.7.0 to 0.17.0 Bumps [golang.org/x/net](https://github.com/golang/net) from 0.7.0 to 0.17.0. - [Commits](golang/net@v0.7.0...v0.17.0) --- updated-dependencies: - dependency-name: golang.org/x/net dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> * Update changelog Signed-off-by: dependabot[bot] <support@github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> * Update DEVELOPER_GUID, Add Coverage + go ling to Makefile, Run CI tests on all branches (#392) * .github: run test workflows for all branches, test against 2.9,2.10 Signed-off-by: Jakob Hahn <jakob.hahn@hetzner.com> * Makefile: use docker golangci-lint, run integration test on `.` folder, change coverage generation Signed-off-by: Jakob Hahn <jakob.hahn@hetzner.com> * Update DEVELOPER_GUIDE Signed-off-by: Jakob Hahn <jakob.hahn@hetzner.com> --------- Signed-off-by: Jakob Hahn <jakob.hahn@hetzner.com> Signed-off-by: Vacha Shah <vachshah@amazon.com> * Updated linter version to 1.54.2 (#394) * Updated linter version to 1.54.2 Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updated CHANGELOG.md Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updated CHANGELOG.md Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updated CHANGELOG.md - moved linter update to Dependencies Bumps Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> --------- Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> Signed-off-by: Daniel (dB.) Doubrovkine <dblock@dblock.org> Co-authored-by: Daniel (dB.) Doubrovkine <dblock@dblock.org> Signed-off-by: Vacha Shah <vachshah@amazon.com> * Deprecate legacy API (#390) * deprecated legacy REST API /_template Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * deprecated legacy REST API /_template Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * removed deprecated header at the top of the doc Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * added deprecated notes to the CHANGELOG.md Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Corrected deprecation statement Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Update CHANGELOG.md Co-authored-by: Jakob <jakob.hahn@hetzner.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> * Updated deprecated message on api.indices.put_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.exists_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.delete_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Added deprecated message on api.indices.get_template.go Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> * Updated deprecated message on api.indices.exists_template.go and added back in IndicesExistsTemplate that was delete by mistake Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> --------- Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> Co-authored-by: Jakob <jakob.hahn@hetzner.com> Signed-off-by: Vacha Shah <vachshah@amazon.com> * Bump github.com/aws/aws-sdk-go-v2/config from 1.18.44 to 1.19.0 (#398) * Bump github.com/aws/aws-sdk-go-v2/config from 1.18.44 to 1.19.0 Bumps [github.com/aws/aws-sdk-go-v2/config](https://github.com/aws/aws-sdk-go-v2) from 1.18.44 to 1.19.0. - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/v1.19.0/CHANGELOG.md) - [Commits](aws/aws-sdk-go-v2@config/v1.18.44...v1.19.0) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go-v2/config dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Update changelog Signed-off-by: dependabot[bot] <support@github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> * Bump github.com/aws/aws-sdk-go from 1.45.24 to 1.45.26 (#397) * Bump github.com/aws/aws-sdk-go from 1.45.24 to 1.45.26 Bumps [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go) from 1.45.24 to 1.45.26. - [Release notes](https://github.com/aws/aws-sdk-go/releases) - [Commits](aws/aws-sdk-go@v1.45.24...v1.45.26) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Update changelog Signed-off-by: dependabot[bot] <support@github.com> --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> * Bump client version to 2.4.0 Signed-off-by: Vacha Shah <vachshah@amazon.com> --------- Signed-off-by: Tanner Jones <alltechguyblog@gmail.com> Signed-off-by: Vacha Shah <vachshah@amazon.com> Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: Jakob Hahn <jakob.hahn@hetzner.com> Signed-off-by: Daniel (dB.) Doubrovkine <dblock@dblock.org> Signed-off-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> Co-authored-by: Tanner Jones <78619684+tannerjones4075@users.noreply.github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com> Co-authored-by: Jakob <jakob.hahn@hetzner.com> Co-authored-by: Daniel (dB.) Doubrovkine <dblock@dblock.org>
Description
Deprecated: uses a nonexistent legacy REST API (/_template). In OpenSearch v2.x the correct REST API is /_index_template, which is accessible by the correct method in the following location: opensearchapi/api.indices.put_index_template.go
Issues Resolved
Removing a legacy API that creates confusion among current use of the API
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.