SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
A few questions

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
A few questions
Author Message
Jonathan



Joined: 08 Oct 2003
Posts: 13

Post A few questions Reply with quote

I'm evaluating schedulars now and came across 24x7 and have a couple of questsions

the help file says:

Asynchronous Process

For program and document file jobs:
The 24x7 Scheduler executes the specified program asynchronously in background using a separate job thread, and keeps monitoring the running program (process) until it is complete or the time-out interval elapses.

but in step 3 of the Job Wizzard if I check Asyncronous the timeout box is dissabled

So if I have a job to run asyncronously and I want to consider that if it has been executing for 2 hours and not completed it is hung I I should fail the job and notify someone, what do I do?

Thu Sep 29, 2005 4:34 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7850

Post Re: A few questions Reply with quote

Assuming that are working with the 24x7 Windows version you can chnage the job type to asynchrnous JAL script and in the script code the following

Dim process_id, number
RunAndWait "c:\\mybatch.bat", "", 7200, process_id

In the job properties enable notification action "on error", select email or other action type and complete the rest of properties. Thats'it. Similar method is available with VBScript job types. For example

Dim vb24x7
Set vb24x7 = CreateObject("vb24x7.Process")
ProcessId = vb24x7.RunAndWait("c:\mybatch.bat", 7200)
If ProcessId < 0 Then

'handle the notification here or failed the job and let 24x7 do the rest

Err.Raise 1001, "my job", "Timeout error message"
End If
Set vb24x7 = Nothing

: I'm evaluating schedulars now and came across 24x7 and have a couple of
: questsions

: the help file says: Asynchronous Process

: For program and document file jobs: The 24x7 Scheduler executes the specified
: program asynchronously in background using a separate job thread, and
: keeps monitoring the running program (process) until it is complete or the
: time-out interval elapses.

: but in step 3 of the Job Wizzard if I check Asyncronous the timeout box is
: dissabled

: So if I have a job to run asyncronously and I want to consider that if it has
: been executing for 2 hours and not completed it is hung I I should fail
: the job and notify someone, what do I do?

Thu Sep 29, 2005 5:20 pm View user's profile Send private message
Jonathan



Joined: 08 Oct 2003
Posts: 13

Post Re: A few questions Reply with quote

: Assuming that are working with the 24x7 Windows version you can chnage the
: job type to asynchrnous JAL script and in the script code the following

So what your saying is that No I can't set a time limit on a job run Asyncronously.

Can I parameterize the JAL script so I dont have to rewrite it for each job?

So i have a script RunJob.jal
and give it 2 parameters, the executable to run and the mo0unt of time to wait


Mon Oct 03, 2005 6:29 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7850

Post Re: A few questions Reply with quote

Yes, you can use either an existing template or make your own. This way when you create a job you can simply browse for the executable file name, enter timeout and then set the appropriate job schedule.
For details, see File/New/Job From Template menu and also Tools/Template Builder menu.

Note that both JSL and VBScript jobs can be used for that purpose.

Also please note that instad of doing all that you can simply use a sync. job running with a timeout in a separate job queue. This is much better solution from a job management point of view.

: So what your saying is that No I can't set a time limit on a job run
: Asyncronously.

: Can I parameterize the JAL script so I dont have to rewrite it for each job?

: So i have a script RunJob.jal
: and give it 2 parameters, the executable to run and the mo0unt of time to
: wait

Mon Oct 03, 2005 8:11 am View user's profile Send private message
Jonathan



Joined: 08 Oct 2003
Posts: 13

Post Re: A few questions Reply with quote

: Also please note that instad of doing all that you can simply use a sync. job
: running with a timeout in a separate job queue.

This was my original posted question.

Why is it if I try to run a program a sync is the timeout control dimmed an in accessablle?

Why can't I set a timeout if a program is executed a sync?

Mon Oct 03, 2005 10:58 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7850

Post Re: A few questions Reply with quote

This is because in that mode the process is kicked off and "let go" Monitoring such process would require another resident process (a spawned thread in this case) which in turn would require more system resources, system load and CPU time. Is it possible to do that? Yes. Is it needed? Not sure. You will have a hard-time convincing me why you need to go that way and not simply run synchronous processes in several parallel job queues.

: This was my original posted question.

: Why is it if I try to run a program a sync is the timeout control dimmed an
: in accessablle?

: Why can't I set a timeout if a program is executed a sync?

Mon Oct 03, 2005 12:30 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.