Set timeout and memory allocation
1
const runtimeOpts = {
2
timeoutSeconds: 540,
3
memory: '2GB'
4
}
5
​
6
exports.myStorageFunction = functions
7
.runWith(runtimeOpts)
8
.storage
9
.object()
10
.onFinalize((object) = > {
11
// do some complicated things that take a lot of memory and time
12
});
Copied!
The maximum value for timeoutSeconds is 540, or 9 minutes.
​
Last modified 1yr ago
Copy link