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

AIP-216 and custom methods #345

Open
rcolline opened this issue Oct 23, 2019 · 0 comments
Open

AIP-216 and custom methods #345

rcolline opened this issue Oct 23, 2019 · 0 comments

Comments

@rcolline
Copy link
Contributor

AIP-216 suggests that all state transitions should be modeled as custom methods. It sustains this reasoning with "should not have side effects" which I see as a reference to starting and stopping. E.g "One should not have to update a VM instance metadata to start the VM. Instead one should call the custom method instance:start"

Custom methods should only be used when absolutely necessary as they make APIs more difficult to understand and to map to declarative actuators such as terraform, ansible, chef etc.

Balancing both of these issues, I suggest the following update:
AIP-216 should say only use custom methods for state transitions that deal with true lifecycle status e.g "start, stop, pause, etc". States indicating external process recording (e.g 'approved', 'reviewed', etc) should be modeled through update.

Thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant