Closed duboisph closed 8 months ago
Hi @prudhvigodithi, do you have an idea when someone could review this please?
Hey @duboisph thanks for the contribution, lets ship this soon, while I review, can you please fix the unit tests, you should run terrafmt
.
@prudhvigodithi Thank you! Meanwhile the terrafmt should be fixed.
On quick thought, @duboisph do you think we should tell customer to pre-create the repo before create/update the policy ? this way its aware that this feature would tackle the SM policies, not configuring the snapshot repositories. Thank you
Hi @prudhvigodithi. Indeed, good point. I've pushed an udpdate to the example. Would this be clear enough?
Thanks @duboisph, LGTM, approved the PR, please take care of my above 2 comments.
Thank you @prudhvigodithi! I've resolved your comments :)
LGTM, I will merge the PR. Thanks again for your contribution @duboisph.
@prudhvigodithi When will this be released?
Hey @msvticket, thanks for following up I will do a quick short release today to get this feature out. Thanks
This feature should be now in the v2.2.0 https://registry.terraform.io/providers/opensearch-project/opensearch/2.2.0, please check, thanks @duboisph for you contribution.
Description
Added support for Snapshot Management policies, largely based off the ISM code, but with a slightly different API.
An important difference is that a policy's Name is not the same as it's ID (
<policy_name>
+-sm-policy
suffix), however the name is used for API requests. Within the provider code, I opted to use the policy ID for the TF state'sid
, but everything else uses thepolicy_name
(resource definition, import, api requests).Also this API uses
POST
for create andPUT
to update, using the same body data. Responses forGET
,POST
andUPDATE
are all the same.Issues Resolved
Closes #70.
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.