approach was to schedule a firebase function that triggers on the date when a user subscription is supposed to expire.
Is it possible to dynamically schedule multiple firebase functions on the fly in another firebase function?
No, but you can record in the collection projected timestamp and on minute interval check subscription state
Like I should read the collection every minute for expired subscriptions?
Meaning I should schedule a cloud function that runs every minute and does the checks?
This was my initial idea. My thoughts are that it might be expensive
Apply filter to check only valid subscriptions and remove invalid from the future checks
Thank you sir. Another question Scheduling a function function to run every minute, will it function like triggering the function every minute. My reason for this is because only 2million free invokes are given for a month. So invoking it every minute will consume all the invokes
Every minute is a 720 invocations a day
Обсуждают сегодня