Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Flask with Asyncrounus Script in the Background

So what i am trying to do is, to host my Flask API and have a script running on the Server in the background all the time, even when there is no user that is accessing the API.

The script in the background should be executed once a minuite to update things in the Database.

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

What you’re interested in are "cronjobs".

You can check out a library like Celery to get started. In particular, you’ll want to look at Celery "beat".

Hope this helps.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading