Bump metrics updater functions to 1GB memory
This commit is contained in:
parent
789c9aa32a
commit
1ab17bbbf0
|
@ -10,8 +10,9 @@ const firestore = admin.firestore()
|
|||
|
||||
const oneDay = 1000 * 60 * 60 * 24
|
||||
|
||||
export const updateContractMetrics = functions.pubsub
|
||||
.schedule('every 15 minutes')
|
||||
export const updateContractMetrics = functions
|
||||
.runWith({ memory: '1GB' })
|
||||
.pubsub.schedule('every 15 minutes')
|
||||
.onRun(async () => {
|
||||
const contractDocs = await firestore.collection('contracts').listDocuments()
|
||||
await batchedWaitAll(
|
||||
|
|
|
@ -11,8 +11,9 @@ import { calculatePayout } from '../../common/calculate'
|
|||
|
||||
const firestore = admin.firestore()
|
||||
|
||||
export const updateUserMetrics = functions.pubsub
|
||||
.schedule('every 15 minutes')
|
||||
export const updateUserMetrics = functions
|
||||
.runWith({ memory: '1GB' })
|
||||
.pubsub.schedule('every 15 minutes')
|
||||
.onRun(async () => {
|
||||
const [users, contracts, bets] = await Promise.all([
|
||||
getValues<User>(firestore.collection('users')),
|
||||
|
|
Loading…
Reference in New Issue
Block a user