I'm doing an assignment for the university using the Firebase real-time database in Ionic and Angular 2. I don't have any problem in the typical crud, but I need to make a change to a data in the database, and a some time later (an hour, for example) to change the value again. Is there a way to update a data at a scheduled time in firebase using (correct me if I'm wrong) its backend? This action should be firebase's own. I tell you that I do not have much knowledge of firebase in this regard. I hope the problem has been understood. Thank you very much in advance. [I add this]: The doubt is also in which event to use to start this task, the idea of this is to modify a value of a node (onChange) and 20 min later return it to its original state. Seeing that logic, when activating it with the change, I don't know how to change the data again. I could use a setTimeout to execute the change 20 minutes later, but it wouldn't affect performance? And more considering that I have the free firebase plan
You may be interested in finding out about cloud functions, this is programmed in javascript and runs on the server side, since we do not have to set up any server, we say that it is serverless. Here I leave you a video I made of how to implement a function to firebase that runs on the server side
https://www.youtube.com/watch?v=vsQw-1zS3mY
In the same way as in the video, it can be configured to work with timestamps and do things from different times (cron jobs). I leave you the repo of all the public functions so far, following the video you can implement any. Also this video on how to use cron jobs with functions is very good https://www.youtube.com/watch?v=fEBPAMSk5_8
https://github.com/firebase/functions-samples