sls-db-warmer
v1.0.2
Published
TS package that uses the data API to query AWS Aurora Serverless databases & prevent auto pause.
Downloads
5
Readme
sls-db-warmer
TS package that uses the data API to query AWS Aurora Serverless databases & prevent auto pause.
Usage
Invocation of sls-db-warmer
should be scheduled according to how long your Aurora Serverless database is configured to wait before automatically pausing.
See sls-db-warmer-template for example use with scheduled lambdas using Serverless Framework.
import { warmDatabases } from "sls-db-warmer";
const databasesToWarm = {
[firstDbName]: {
secretArn: "",
resourceArn: "",
region: "",
credentials: {
accessKeyId: "",
secretAccessKey: "",
},
},
[secondDbName]: {
...
}
};
await warmDatabases(databasesToWarm);