amazon-auroraaws-serverlessaws-aurora-serverless

does aws rds serverless scaling help current running query?


I have an aws aurora severless rds. Once in awhile, i have queries run which involve a large number of records being joined and/or updated.

When a resource intensive query kicks off, and the serverless environment scales up.. does the query that is currently running actually get to make use of the new resources, or is it only for future queries?

I am testing this out right now (if i can).. I ran the large query and it wasn't returning after 30 minutes.. (i have seen this query return in 5 minutes in the past). I'm not sure how to tell what 'scaling' has occurred.. but assuming it has scaled up while this query has been running.. I killed the query, and then just ran the process again. Unfortunately this is a many-part process.. so I'm now waiting to see if it runs any faster.

So I guess its a 2 part question: is there a simple way to see the current scaling 'level'? eg. see that it has raised, and then later, see it lower itself back down..

when the scaling increases, and a query is currently running.. will that query actually get to take advantage of the scaling, or only future queries?

Thanks


Solution

  • It will not help currently running queries, because in order to scale, Aurora has to find a scaling point. This is defined as a period with no active transactions/queries. If a scaling point cannot be found before the timeout is reached, scaling would either be abandoned or forced, depending on the configured TimeoutAction (https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_ScalingConfiguration.html). Forced scaling would kill any open connections. Your running query would therefore block scaling until it completes.

    You can see the current capacity of your cluster in the Amazon RDS console. https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/aurora-serverless.viewing.html