Cross-Provider Enforcement
- Dominant language
- Python
- Stars
- 117
- Forks
- 51
- Avg merge
- 9h 17m
- Merged PRs (30d)
- 5
Description
We talked about this quickly at the last Zoom meeting in 2018, so I'm documenting the idea here for further discussion and to see whether it'd be a good one to potentially implement for 2.0 with GCE, and/or work on during this CollabFest.
We had already discussed a few months ago adding decorators (similar to the deprecated decorator) that would issue either a warning or an error (with severity set in the .cloudbridge settings file) when any provider-specific code is being used (an easy example would be invoking az.resource_group, a property specific to Azure and inexistent in other providers). As an extension of this idea, I also was suggesting adding an option to specify for what providers the function should be available. This would thus allow us to add some provider-specific services/functions, even if they are not available across all of our supported providers. A specific use-case which brought this up would be implementing the native Kubernetes services (Azure K8S Service, AWS EKS, GKE) although I don't think an equivalent would exist in OpenStack.
So the final idea would be having two new settings options:
```
providers: [aws, azure, os, gce]
severity: [ignore, warning, error]
```
I would suggest defaulting them to be across all providers (as that is the main point of CloudBridge) and to warning (as to not frustrate new users with figuring out error codes if they are starting to learn CloudBridge on a specific provider).
I believe creating the decorator should be fairly straightforward, and it might take a little bit of time to go back and tag previous functions, but would be much easier if done alongside #109.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.