rubrikinc / rubrik-sdk-for-python

Rubrik SDK for Python
https://build.rubrik.com/sdks/python/
MIT License
29 stars 38 forks source link

Add option for cluster name in configure_replication_private #248

Open KowMangler opened 4 years ago

KowMangler commented 4 years ago

Is your feature request related to a problem? Please describe.

I can't specify a cluster name in configure_replication_private and that prevents me from making the function itself idempotent since the value returned from the "GET" method returns whatever the current delegation is for the remote/central communication pairing.

i.e.

Describe the solution you'd like

Allow me to specify the targetClusterName in the function (even though in the API call it would be unused) in order to measure whether or not the call would effect a change.

EDIT: (Otherwise the call returns an error.) <- statement is untrue. all that happens is the cluster returns the response that the replication target has been created.

Describe alternatives you've considered

Additional context

Add any other context or screenshots about the feature request here.

drew-russell commented 4 years ago

@KowMangler will dig into this later today

KowMangler commented 4 years ago

Correcting the original statement that an error occurs. No error occurs, just the call returns 200 and the replication target is "set" even though it was already set. This is inconsistent with a majority of the API calls where via the SDK where if the configuration is identical nothing is set.

What I'm trying to do is get more ansible modules built. I can move logic to the ansible modules for this particular module but I want to see what the opinion of maintainers are.

KowMangler commented 4 years ago

The real issue is how to handle the validation check. I can think of two options:

KowMangler commented 4 years ago

opted for first option creating the ansible module. can change it depending on what comes of this issue.