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

aws/rds: Be a bit more interactive when creating/deleting db instance #1097

Closed
radeksimko opened this issue Mar 2, 2015 · 3 comments
Closed

Comments

@radeksimko
Copy link
Member

Creating or destroying an RDS instance in AWS is a very slow process, sometimes may take even half an hour.

Terraform's current behaviour (which is very similar if not same as CloudFormation's):

  1. Trigger the creation
  2. Wait and let user starring XX minutes to aws_db_instance.default: Creating...
  3. After XX minutes, say "OK" or "FAIL"

1. Make blocking optional

First of all I think that in many cases, user just may not want to wait for the RDS if it's really not a blocker in the dependency graph (i.e. you're not building other resources on the top of it).

2. Make waiting shorter + nicer

If we're waiting for the endpoint URL, then that's something, that becomes available already when the instance status becomes backing-up and the back-up process takes another ~10 mins or so, so we're IMO merely waiting for API response available, but we may not need to.

If the endpoint is actually useful (DB is in useful state) for another resource is a question I don't know answer to (yet).

3. Use the DBInstanceStatus

Even if you don't agree with any of the two points above, I think the user should at least be able to see what's happening behind the scenes if the API is able to give it. As mentioned above, there are three stages during the initial start in which instance can be:

  • creating
  • backing-up
  • available

and we're only representing two stages which makes a huge difference in UX if we're talking about XX minutes.


Over and over, I wish AWS would be offering better API for this, something like Twitter Streaming API - one just listens on a socket and doesn't waste HTTP traffic on asking if it's ready when 90% of the time API says no. I may ask the AWS support about this.

@JeanMertz
Copy link
Contributor

I am highly in favour of option 2.

We need the endpoint as an output variable, but there is no reason for us to wait for the backup to finish. This would greatly speed-up our deployment process. 👍

@catsby
Copy link
Contributor

catsby commented Nov 8, 2016

Hey @radeksimko – I'm going to close this for now.

First of all I think that in many cases, user just may not want to wait for the RDS if it's really not a blocker in the dependency graph (i.e. you're not building other resources on the top of it).

This is a really interesting idea (possible optimizations if a resource can know that it's a end vertex in the graph) I'll bring it up internally, thanks!

@catsby catsby closed this as completed Nov 8, 2016
@ghost
Copy link

ghost commented Apr 20, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants