[V5] Cron Job
#2033
-
Hello folks! I need to run some kind of cron job. Is there any support for AdonisJS V5 for node-schedule or node-cron packages? Can I use one of these packages directly with TypeScript? By the way, which package do you suggest to use or prefer to use, why? |
Beta Was this translation helpful? Give feedback.
Answered by
ruanitto
Dec 15, 2020
Replies: 2 comments 4 replies
-
I am using adonis5-schedule that meets all my requirements. |
Beta Was this translation helpful? Give feedback.
0 replies
-
For automatic execution, I am calling the service execution as soon as the application is ready within providers/AppProvider.ts public async ready() {
// App is ready
const scheduler = this.app.container.use('Adonis/Addons/Scheduler')
scheduler.run()
} |
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
remidosol
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For automatic execution, I am calling the service execution as soon as the application is ready within providers/AppProvider.ts