How to run scheduled task in less 1 minutes interval in orchardcms. E.g. in 20 seconds - scheduled-tasks

I know orchard has its default scheduler running in every minutes. Does it mean that the minimal interval is 1 minutes?
If I want a task to run in every 20 seconds, how can I make it.
Thanks

You can open the file src\Orchard.Web\Config\Sites.config to uncomment the Delay between background services executions paragraph. Here you can set the interval.

Related

Runnig a cronjob every two and half hours

I just want to run a cronjob every 2 and half hour time gaps, I tried 30 */2 * * * but this not working, any idea how to do this?
Posting this as a community wiki, feel free to edit and expand.
As it was pointed out in comments, it's not possible to setup cronjob with simple expression to run every 2.5 hours.
Workaround is to have two separate jobs which run every 5 hours.
Or as you mentioned in comments that you can't have two jobs, then as #larsks said you will need to implement some logic in your script:
The easiest solution would be to run your script every 30 minutes,
then have the script check the elapsed time since the last run and
only run when the elapsed time >= 2.5 hours.
Please find some already asked and answered questions about this topic:
How to execute a cron expression for every 2.5 hours?
Schedule a cronjob to run every 2 1/2hours
Running a cron job every 2:30 on every day?

is it possible to define Must Start Times for dependent jobs in AutoSys

I'm looking for an option in autosys to send an alert if the dependant jobs don't start within 10 min of the avg run time, for example, the last 30 days. The dependant jobs, do not have a fixed starting condition. They might have run at varying times in the last 30 days based on the completion of starting jobs. Would it be possible in autosys, to dynamically set the must start time for the jobs which don't have starting time rather they are dependant on starting conditions?
I use something like this in my critical jobs. You can try them too, if you want :
must_start_times: "19:01"
days_of_week: mo,tu,we,th,fr,sa,su
start_times: "19:00"

Why does Gatling still sends requests when scenario injection is on nothingFor?

So I have the following scenario:
setUp(scenario.inject(
nothingFor(30 seconds), // 1
rampUsers(10) during (30 seconds),
nothingFor(1 minute),
rampUsers(20) during (30 seconds)
).protocols(httpconf)).maxDuration(3 minutes)
I expected this scenario to start by doing nothing for 30 seconds, ramping up 10 users over 30 seconds, do nothing(pause) for a minute and finish by ramping up 20 users for 30 seconds.
But what I got is a 30 second pause, ramp up 10 users over 30 seconds, steady state of 10 users for a minute and then an additional ramp up of 20 users. (I ended up running 30 users)
What am I missing here?
The injection profiles only specify when users start a scenario, not how long they're active for - that will be determined by how long it takes for a user to finish the scenario. So when you ramp 10 users over 30 seconds one user will start the scenario every 3 seconds, but they keep running until they finish (however long that is). I'm guessing your scenario takes more than a couple of minutes for a user to complete.

Gatling during explanation

I´m using Gatling, and I want to repeat a command for an hour so I see there´s one operator during.
The documentation it´s not clear enough
during
.during(duration, counterName, exitASAP) {
myChain
}
duration can be an Int for a duration in seconds, or a duration expressed like 500 milliseconds.
My question is, during will execute the task in 1 hour duration, or it will repeat the task for an hour.
I know we have repeat operator as well, but that it will require me to know how much time it takes my task to finish and then calc the number of repeats.
The code in the during block will run for the duration of seconds you give.
When the scenario is executed then the iterations in the during block are run until the duration.
Using .during() with amount of seconds. you can constantly increase the users, ramp, split the users but cannot repeat the task

Quartz Service - Simple Triggers

I have a Quartz Job that I want to fire every minute. The job itself contains logic to check to see if there is a process to run and if there is, this job could take 45 minutes to complete.
Using a Simple Trigger, will Quartz fire this job off every minute even if there is one already running? Or if the interval is set to 1 minute, does that mean that Quartz will wait 1 minute after the job is done before it fires the next job?
If the trigger is set to fire every minute, it will fire every minute (and a new job instance will be created and invoked).
Unless the related job is marked #DisallowConcurrentExecution.