Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
2 Odpovědi
4062 Zobrazení

Can we run multiple crons at a time in Odoo?

Avatar
Zrušit

Hi,
It is possible to run multiple crons simultaneously in odoo.
Please refer to this forum answer to understand how to do it without having a heavy load on the system.
https://www.odoo.com/forum/help-1/odoo-configuration-for-multiple-cron-jobs-214041

Hope it helps

Nejlepší odpověď

Yes, in Odoo, it is possible to run multiple cron jobs simultaneously. Odoo's cron system is designed to handle multiple cron jobs running concurrently.

For example, let's say you have two cron jobs defined in your Odoo module:

  1. Job A: Scheduled to run every hour using a cron expression of 0 * * * *.
  2. Job B: Scheduled to run every day at midnight using a cron expression of 0 0 * * *.

In this case, Job A will run every hour, and Job B will run once every day at midnight. Since their schedules do not overlap, they can run concurrently without any issues.

However, if two cron jobs have the same cron expression and are scheduled to run at the same time, Odoo will run them sequentially, one after the other. Odoo ensures that the jobs do not run concurrently to prevent any conflicts or concurrency-related issues.


Avatar
Zrušit
Nejlepší odpověď

Hi Guiles,

Reply : In Odoo, by default, multiple cron jobs can run simultaneously. The Odoo scheduler manages the execution of cron jobs, and it allows multiple cron jobs to be executed concurrently, as long as they meet the conditions specified in their cron expressions.

If multiple cron jobs have overlapping intervals or their conditions are met simultaneously, they will be executed concurrently.

However, please note that concurrent execution of cron jobs can impact system performance, especially if the jobs involve resource-intensive tasks or database operations. Therefore, it's important to design your cron jobs carefully and consider any potential conflicts or performance implications when running multiple cron jobs simultaneously.

Regards,

Ksolves Team!

Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
1
led 24
2527
0
dub 22
4180
0
led 17
4490
0
pro 15
4794
1
zář 15
17081