Skip to content

Aurora Serverless v2 - The request was throttled because of insufficient resources on the database

0

Hello

I have an PostgresSQL Aurora Serverless v2 database. I have recently been getting continual error messages when I try to do any sort of query in a lambda function using the Data API. The errors are of the form given below.

I have looked at Performance Insights for the db and nothing jumps out as being overloaded and it is certainly not clear what the "insufficient resources" might be.

Any ideas?

Thanks!

ThrottlingException: Throttling error: The request was throttled because of insufficient resources on the database.
    at throwDefaultError (/var/runtime/node_modules/@aws-sdk/node_modules/@smithy/smithy-client/dist-cjs/index.js:838:20)
    at /var/runtime/node_modules/@aws-sdk/node_modules/@smithy/smithy-client/dist-cjs/index.js:847:5
    at de_CommandError (/var/runtime/node_modules/@aws-sdk/client-rds-data/dist-cjs/index.js:830:14)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async /var/runtime/node_modules/@aws-sdk/node_modules/@smithy/middleware-serde/dist-cjs/index.js:35:20
    at async /var/runtime/node_modules/@aws-sdk/node_modules/@smithy/core/dist-cjs/index.js:165:18
    at async /var/runtime/node_modules/@aws-sdk/node_modules/@smithy/middleware-retry/dist-cjs/index.js:320:38
    at async /var/runtime/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:33:22
    at async /var/task/index.js:169:24 {
  '$fault': 'client',
  '$metadata': {
    httpStatusCode: 400,
    requestId: '16658f30-ad70-4ab8-9246-3f91aae230e3',
    extendedRequestId: undefined,
    cfId: undefined,
    attempts: 3,
    totalRetryDelay: 522
  }
}

UPDATE - I also get the same error when querying the db via the Query Editor in AWS Console. However, it works connecting to the db via hostname/address in pgAdmin and querying. It was all working until a couple of days ago. There was a period of high CPU usage which may have triggered something but the usage is normal now.

asked 2 years ago1.6K views
3 Answers
1
Accepted Answer

I did finally manage to sort this issue. Disabling and then re-enabling the RDS Data API in AWS Console seemed to get it up and running again! I have no idea why and it is rather worrying that this could happen again at some point and completely stop my database working in production.

I will open a Support case once I get my support set up to see if they can diagnose why it failed.

answered 2 years ago
EXPERT
reviewed a year ago
  • Sure, please do - it's important they know that something was wrong to make it work better for everyone else.

  • I just experienced exactly the same issue and can confirm that turning the Data API on and off solved it.

0

Hello,

You might be trying to return more than 1 MB of data? - this is a limitation of Data API. (The query editor is using Data API behind the scene so this is why you're seeing the same message there.)

AWS
answered 2 years ago
  • Hi.

    Thanks for your help but I don't think it's that, since even a SELECT query limited to one row generates the error.

  • In this case I would also recommend bringing this to support.

0

I would recommend that you open a support case to have this investigated.

AWS
EXPERT
answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.