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

Provide a data sources for ListClusters, ListAvailableRegions and ListDatabases #171

Open
mwillbanks opened this issue Oct 27, 2023 · 1 comment

Comments

@mwillbanks
Copy link

Feature Request

Presently, there exists a way of fetching a cluster by a known id, however, there is no ability to fetch all clusters which exist. It could be great to have a data source for doing this as it allows for more dynamic configuration whereby it is not possible to do this today.

What is the problem right now?

Currently, we need to define out the cluster ID's and set them to internal variables to check against, rather than being able to dynamically create and/or fetch a cluster and get the id value.

Use Case

In our development environments, we prefer to reuse a single cluster (it's wasteful to continually create new clusters for each development environment), therefore, we want to be able to dynamically check against the clusters configurations to check and see if we have a development cluster available or not and then we create different databases for each dev environment since they're utilized very infrequently.

Ideally this would provide back information about each cluster in a list, this method already exists within the go SDK which is the backbone for the terraform provider: ListClusters, likewise, the ListAvailableRegions would certainly aide in associating the proper regions for a cluster. Then we would like to be able to fetch the currently configured databases, this lets us know if we need to create one or not ListDatabases in the event we are sharing this database for a different stack, think of a situation whereby you are reusing the database to test out a hotfix / derived stack.

@marksoper
Copy link
Collaborator

Hi @mwillbanks - thank you for writing this up and sharing. We have been focused on adding functionality by building out resources, now doing a review to look at adding some additional data sources. This will be very helpful for that. We will explore doing list data sources as you've suggested.

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

2 participants