Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Is it possible to have a relative time dependency on OPC?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools
View previous topic :: :: View next topic  
Author Message
HammerTime

New User


Joined: 26 Sep 2012
Posts: 14
Location: UK

PostPosted: Fri Jan 16, 2015 9:20 pm    Post subject: Is it possible to have a relative time dependency on OPC?
Reply with quote

Hi folks, got a fairly simple request, but so far i've drawn a blank with a workable solution.

Is it possible for OPC to use a relative time dependency, eg: Job B can only start X minutes after Job A completes?

The issue we are facing is that we have an application created with all of the necessary job dependencies, and also some time dependencies.

We currently have Job A scheduled to run at 00:00.
Job B has a job dependency on Job A, but also has a time dependency of 01:00 to allow some external processing (on another system not scheduled by OPC) to complete before Job B runs. In reality, this gap probably only needs to be 10 mins max, we just schedule an hour for contingency.

This all works perfectly, unless for some reason Job A is delayed (eg: IPL takes place/earlier job failures/etc.) and does not start until >= 01:00, as Job B then triggers immediately following Job A (because it's Time Dependency has been satisfied). This results in a problem for us.

Unfortunately it's not as simple as just allowing a later start time for Job B, as it is critical to have this running as early as possible in an already tight batch window.

I've looked into creating some REXX which performs a Pause, but don't really like that approach.

Surely there must be something possible in OPC which could achieve what I need?
Back to top
View user's profile Send private message

David Robinson

Active User


Joined: 21 Dec 2011
Posts: 175
Location: UK

PostPosted: Fri Jan 16, 2015 10:10 pm    Post subject:
Reply with quote

It depends what release your are on. If I recall correctly, that facility came in with v8.3.
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1609
Location: NY,USA

PostPosted: Sat Jan 17, 2015 12:52 am    Post subject:
Reply with quote

http://publib.boulder.ibm.com/tividd/td/opc/GC32-0402-00/en_US/PDF/GC32-0402-00.pdf

Please have a look at 10.4 or page no-135, I think that should answer what have you asked.
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1609
Location: NY,USA

PostPosted: Sat Jan 17, 2015 1:35 am    Post subject:
Reply with quote

Also you can delay in JCL itself or write a simple COBOL program which does so.

Code:
CBL DATA(24)                                         
IDENTIFICATION DIVISION.                             
PROGRAM-ID.    DELAY                                 
DATE-COMPILED.                                       
ENVIRONMENT DIVISION.                               
DATA DIVISION.                                       
WORKING-STORAGE SECTION.                             
01 WAIT-MODULE  PIC  X(08)  VALUE 'ILBOWAT0'.       
01 WAIT-TIME    PIC  S9(8) COMP VALUE 0.             
PROCEDURE DIVISION.                                 
                                                     
    MOVE +45 TO WAIT-TIME.                           
                                                     
    CALL WAIT-MODULE USING WAIT-TIME.               
                                                     
    GOBACK.
Back to top
View user's profile Send private message
HammerTime

New User


Joined: 26 Sep 2012
Posts: 14
Location: UK

PostPosted: Mon Jan 19, 2015 4:56 pm    Post subject:
Reply with quote

Thanks for the replies. Looks like we are on v8R5 OPC on Z/OS, so there may be a glimmer of hope!

We don't have ILBOWATO on our installation, and I've yet to find a way of performing the delay in JCL. I can do it in REXX without too much trouble, but would prefer to control this delay with OPC if possible.

@David - Don't suppose you have any info on how this can be done on Z/OS OPC? I've drawn a blank after a lot of reading through the manuals.
Back to top
View user's profile Send private message
David Robinson

Active User


Joined: 21 Dec 2011
Posts: 175
Location: UK

PostPosted: Mon Jan 19, 2015 6:46 pm    Post subject:
Reply with quote

You need to set up a new work-station specifically for this purpose. Work-station type is general, reporting attribute is non-reporting, and set the WAIT option to Y.

Then you simply "run" the job on that work-station, setting the duration to the time delay that you want. Dependencies are added as with any other job, i.e.; your second job will be dependent on your "wait" job which will be dependent on your first job.

As a slight aside, if you have TWS anyway you can also use the supplied program EQQRETWM to introduce a delay in to your batch job, e.g.;

EXEC PGM=EQQRETWM,PARM=WT300

will cause your batch job to wait for 5 minutes. Much better to do it with a wait work-station though, especially for long delays.
Back to top
View user's profile Send private message
HammerTime

New User


Joined: 26 Sep 2012
Posts: 14
Location: UK

PostPosted: Mon Jan 19, 2015 6:52 pm    Post subject:
Reply with quote

Fantastic, thanks David. Will give that a go.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Get a job submitted itself every time... arunsoods JCL & VSAM 3 Tue Nov 22, 2016 4:05 pm
No new posts Check System time(Minute) Using TIME1... balaji81_k DFSORT/ICETOOL 5 Fri Nov 11, 2016 10:53 am
This topic is locked: you cannot edit posts or make replies. Get correct date and time when curren... balaji81_k DB2 24 Fri Oct 14, 2016 10:40 pm
No new posts cics & real time monitoring icehat CICS 5 Wed Sep 07, 2016 2:29 am
No new posts Get system time in micro second or cl... lind sh CICS 11 Mon Sep 05, 2016 11:14 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us