ESP Workload Automation

  • 1.  Schedule jobs every 90 days

    Posted May 24, 2012 01:14 PM
    Running CA WA EE R11.3

    We are trying to set up a schedule based on the below criteria. Any suggestions would be appreciated.
    All of these are mainframe jobs.

    jobX runs daily

    On 4/2/2012, jobX triggers jobA and jobB
    Next day, 4/3/2012, jobX triggers jobC and jobD (but these also wait for a FileTrigger)

    90 days after jobA and jobB are run (7/2/2012), we want jobX to trigger jobA and jobB again.
    The next day, 7/3/2012, jobX triggers jobC and jobD (but these also wait for a FileTrigger)

    After 90 days from last run of jobA and jobB, we start the cycle again.

    Restrictions:
    jobA and jobB can never run on a FRIDAY, SATURDAY, HOLIDAY or DAY BEFORE A HOLIDAY. They need to wait for a valid Sunday thru Thursday to run.
    jobC and jobD are always scheduled to come in after JobA and jobB have run and will also have a requirement for a file to be created on a server.

    jobA and jobB must wait at minimum 90 days, from the last time they actually ran, before they can run again.
    (They can run between 90 and 95 days from the last time they ran.)


    Thanks
    Sal


  • 2.  RE: Schedule jobs every 90 days

    Posted May 24, 2012 05:23 PM
    Exactly what do mean when you state that jobX triggers jobA and jobB ? Does it mean that job X runs on 04/03/2012 and after a successful completion causes jobA and jobB to be released ? That is to say would it look like the below. Do all the jobs wait for the same file trigger or for a file trigger that is unique for the job in question ?

    I am fuzzy on the exact topology of the network you are describing. It is not obvious to me that the jobX that releases jobA and jobB is the same jobX that releases jobC and jobD or even if release is the proper terminology to use to explain what is happening here. Can you be a bit more specific on the points above.

    Thanks.

    Michael E. Ellis
    Systems Programmer
    Deere & Company


  • 3.  RE: Schedule jobs every 90 days

    Posted May 25, 2012 07:07 AM
    Michael.

    Sorry about my ‘CA7’ terminology. I am not a scheduler – I just install CA WA and know a little bit about scheduling. I am trying to help out our schedulers.

    jobX – is ALWAYS the same job, It runs daily. Every 90 days, Upon successful completion it RELEASES (not triggers) jobA and jobB on one day and 2 different jobs, jobC and jobD the day after jobA and jobB are run.
    jobC and jobD wait for the same file trigger each time.

    I hope that helps clarify.
    Sal


  • 4.  RE: [CA Workload Automation ESP Edition] Schedule jobs every 90 days

    Posted May 24, 2012 11:42 PM
    You pose a very interesting question. It sounds like Michael has some thoughts about this but I'll throw out my ideas too.

    Challenge #1: Only running the jobs every 90 days and on the correct days. By using some logic in the beginning of the application before any jobs are actually generated we can do this. The following solution uses a Global Variable Table to keep track of the last time the series of jobs actually was scheduled. It also uses a series of IF statement to check the other requirements. As soon as a requirement check fails, the logic skips over other processing and generates just JOBX in the application.

    Challenge #2: Running JOBX daily and running JOBC/JOBD the day after JOBA/JOBB

    See if the following meets your requirements. I have simulated the processing for July 2nd/3rd but have not jumped any further ahead. Simulate thoroughly to make sure it works as you expect. There are more comments than code but I have tried to add enough documentation so that the process can be understood.


    APPL COM24MAY

    /* CONTROL WHEN JOBS A/B/C/D RUN WITH A VARIABLE. WHEN SET TO
    /* 'YESTERDAY' THE JOBS WILL NOT RUN. WILL BE CHANGED TO 'TODAY'
    /* WHEN THE PROPER CONDITIONS ARE MET.

    RUNJOBAB='YESTERDAY'
    RUNJOBCD='YESTERDAY'
    GENTIME T90 TODAY

    /* DETERMINE IF IT HAS BEEN 90 DAYS SINCE LAST RUN AND IF TODAY IS A
    /* VALID DAY. USE A GLOBAL VARIABLE TABLE TO SAVE THE LAST TIME THE
    /* JOB RAN. FETCH THE VARIABLE AND TEST IF 90 DAYS HAVE ELAPSED. ALL
    /* TESTS ARE SETUP TO BYPASS ADDITIONAL PROCESSING IF THE REQUIRED
    /* CONDITIONS ARE NOT MET.

    VGET (LASTRUN) TABLE(SAVEDATE) CLANG

    /* CHECK TO SEE IF JOBC/JOBD SHOULD RUN TODAY BECAUSE JOBA/JOBB RAN
    /* YESTERDAY.

    IF YESTERDAY('%LASTRUN') THEN DO
    RUNJOBCD='TODAY'
    JUMPTO JOBX
    ENDDO

    /* THE DAYS_FROM FUNCTION RETURNS A POSITIVE NUMBER REPRESENTING THE
    /* NUMBER OF DAYS FROM A DATE IN THE PAST. TEST IF IT HAS BEEN 90
    /* DAYS SINCE THE LAST RUN. IF NOT, SKIP ALL OTHER PROCESSING.

    IF DAYS_FROM('%LASTRUN') LT 90 THEN JUMPTO JOBX


    /* %T90DOW# CONTAINS A VALUE WHICH REPRESENTS THE CURRENT DAY OF
    /* THE WEEK, STARTING WITH 1 FOR SUNDAY THROUGH 7 FOR SATURDAY. IF
    /* DOW# IS 6 (FRIDAY) OR 7 (SATURDAY) THEN JUMP

    IF %T90DOW# GT 5 THEN JUMPTO JOBX


    /* THE TODAY FUNCTION COMPARES THE SCHEDULE EXPRESSION THAT YOU
    /* SPECIFY TO TODAY'S SCHEDULE DATE. IT RETURNS A TRUE OR A FALSE
    /* VALUE, DEPENDING ON WHETHER THE EXPRESSION MATCHES TODAY. IT
    /* WILL BE USED TO JUMP IF THE CURRENT DAY IS A HOLIDAY OR THE DAY
    /* BEFORE A HOLIDAY.

    IF TODAY('HOLIDAY') THEN JUMPTO JOBX
    IF TOMORROW('HOLIDAY') THEN JUMPTO JOBX


    /* WE MADE IT THIS FAR SO HAVE A VALID DATE TO RUN THE WORK.
    /* BUILD A VARIABLE TO CAPTURE THE RUN DATE AND SAVE IT.
    /* THE VARIABLE WILL BE IF THE FORMAT OF 02APR2012 (DDMMMYYYY).
    /* THIS WORKS UNIVERSALLY REGARDLESS OF THE DATEFORM STATEMENT.
    /* ALSO SET VARIABLE SO THAT JOBA/JOBB WILL RUN

    LASTRUN='%T90DD.%T90MMM.%T90YEAR'
    VPUT (LASTRUN) TABLE(SAVEDATE) CLANG
    RUNJOBAB='TODAY'


    JOBX:

    /* NOW DEFINE THE ACTUAL JOBS AND FILE_TRIGGER. HERE, GOING THROUGH
    /* THE VERBAL DESCRIPTION THINGS WERE A BIT FUZZY. YOU WILL PROBABLY
    /* NEED TO MAKE SOME ADJUSTMENTS.


    JOB JOBX LINK
    RUN TODAY
    RELEASE ADD(JOBA)
    RELEASE ADD(JOBB)
    RELEASE ADD(JOBC)
    RELEASE ADD(JOBD)
    ENDJOB

    JOB JOBA LINK
    RUN %RUNJOBAB
    ENDJOB

    JOB JOBB LINK
    RUN %RUNJOBAB
    ENDJOB

    JOB FILETRIG LINK
    /*CODE THIS AS A FILE TRIGGER. JUST A LINK FOR TESTING...
    /*FILENAME C:\ABC\DEF\GHI.TXT
    RUN %RUNJOBCD
    RELEASE ADD(JOBC)
    RELEASE ADD(JOBD)
    ENDJOB

    JOB JOBC LINK
    RUN %RUNJOBCD
    ENDJOB

    JOB JOBD LINK
    RUN %RUNJOBCD
    ENDJOB


    Hopefully this comes close to satisfying all your requirements. The logic uses generic CLANG statements, no REXX. All you would need to do is define a Global Variable Table (pick your own name) and set the initial value for the LASTRUN variable. You can enter the following from Page Mode:

    VTDEFINE SAVEDATE
    LASTRUN='02APR2012'
    VPUT (LASTRUN) TABLE(SAVEDATE) CLANG
    VTLIST SAVEDATE

    Let us know if this works as expected.


    Gene Budbill
    Associate Engineering Services Architect
    CA Technologies




    From: CA Workload Automation (Mainframe) Global User Community [mailto:CommunityAdmin@communities-mail.ca.com]
    Sent: Thursday, May 24, 2012 1:14 PM
    To: mb.2271275.98175122@myca-email.ca.com
    Subject: [CA Workload Automation ESP Edition] Schedule jobs every 90 days

    Running CA WA EE R11.3

    We are trying to set up a schedule based on the below criteria. Any suggestions would be appreciated.
    All of these are mainframe jobs.

    jobX runs daily

    On 4/2/2012, jobX triggers jobA and jobB
    Next day, 4/3/2012, jobX triggers jobC and jobD (but these also wait for a FileTrigger)

    90 days after jobA and jobB are run (7/2/2012), we want jobX to trigger jobA and jobB again.
    The next day, 7/3/2012, jobX triggers jobC and jobD (but these also wait for a FileTrigger)

    After 90 days from last run of jobA and jobB, we start the cycle again.

    Restrictions:
    jobA and jobB can never run on a FRIDAY, SATURDAY, HOLIDAY or DAY BEFORE A HOLIDAY. They need to wait for a valid Sunday thru Thursday to run.
    jobC and jobD are always scheduled to come in after JobA and jobB have run and will also have a requirement for a file to be created on a server.

    jobA and jobB must wait at minimum 90 days, from the last time they actually ran, before they can run again.
    (They can run between 90 and 95 days from the last time they ran.)


    Thanks
    Sal
    Posted by:sal.costanzo
    --
    CA Communities Message Boards
    98177662
    mb.2271275.98175122@myca-email.ca.com


  • 5.  RE: [CA Workload Automation ESP Edition] Schedule jobs every 90 days

    Posted May 25, 2012 07:14 AM
    Gene,
    Wow - thankss Give us time to play with it and digest it.
    Much appreciated.
    Sal


  • 6.  RE: [CA Workload Automation ESP Edition] Schedule jobs every 90 days
    Best Answer

    Posted May 25, 2012 08:42 AM
    Lucky for you I’m out of town this week, there was nothing on TV last night and you tempted me with a puzzle I couldn’t refuse. It was also a chance to showcase some lesser used features and techniques of scheduling work with ESP. This could be done with ‘special days’ in a calendar but the method supplied does not require annual maintenance.

    I have this running on one of my systems with the interval set to 4 days instead of 90. If I discover any issues I’ll let you know.


    Gene Budbill
    Associate Engineering Services Architect
    CA Technologies

    From: CA Workload Automation (Mainframe) Global User Community [mailto:CommunityAdmin@communities-mail.ca.com]
    Sent: Friday, May 25, 2012 7:14 AM
    To: mb.2271275.98180255@myca-email.ca.com
    Subject: RE: [CA Workload Automation ESP Edition] Schedule jobs every 90 days

    Gene,
    Wow - thankss Give us time to play with it and digest it.
    Much appreciated.
    Sal
    Posted by:sal.costanzo
    --
    CA Communities Message Boards
    98182795
    mb.2271275.98180255@myca-email.ca.com<mailto:mb.2271275.98180255@myca-email.ca.com>


  • 7.  RE: [CA Workload Automation ESP Edition] Schedule jobs every 90 days

    Posted Jun 04, 2012 02:26 PM
    Gene
    Our scheduler set up some testing based on what you provided and it all seems to be going well. Thanks again!
    Sal


  • 8.  RE: [CA Workload Automation ESP Edition] Schedule jobs every 90 days

    Posted Jun 11, 2012 02:40 PM
    No problem. That is what the Community is for.

    My version with the shortened 4-day cycle is still running and seems to be working as expected. JOBX is running daily. This past week JOBA/JOBB ran Monday (June 4th), tried to schedule on Friday (June 8th, not allowed), then Saturday (June 9th, not allowed) and finally ran Sunday. The FILE_TRIGGER and JOBX/JOBY are running the day after JOBA/JOBB.


    2012/06/11 --------- ES21 Application Status BUDGE01 -------- 14:07:15.54
    Basic Filter EXIT:PF03, SWAPfilt:PF04, PREVview:PF05, NEXTview:PF06
    Row 1 to 16 of 16: SNAP:ON XE21 - ESP restarted at 01:07 JUN10
    ApplName Gene Status_Details ................... Object_Summary ...........
    COM24MAY 18 Ended at 08:12 TODAY Total=4 (Ended=4) MON
    COM24MAY 17 Ended at 08:00 JUN10 Total=3 (Ended=3) SUN
    COM24MAY 16 Ended at 08:00 JUN 9 Total=1 (Ended=1) SAT
    COM24MAY 15 Ended at 08:00 JUN 8 Total=1 (Ended=1) FRI
    COM24MAY 14 Ended at 08:00 JUN 7 Total=1 (Ended=1) THU
    COM24MAY 13 Ended at 08:00 JUN 6 Total=1 (Ended=1) WED
    COM24MAY 12 Ended at 08:12 JUN 5 Total=4 (Ended=4) TUE
    COM24MAY 11 Ended at 08:00 JUN 4 Total=3 (Ended=3) MON
    COM24MAY 10 Ended at 08:00 JUN 3 Total=1 (Ended=1) SUN
    COM24MAY 9 Ended at 08:00 JUN 2 Total=1 (Ended=1) SAT
    COM24MAY 8 Ended at 08:12 JUN 1 Total=4 (Ended=4) FRI
    COM24MAY 7 Ended at 08:00 MAY31 Total=3 (Ended=3) THU
    COM24MAY 6 Ended at 08:00 MAY30 Total=1 (Ended=1)



    Gene Budbill
    Associate Engineering Services Architect
    CA Technologies


  • 9.  CA Workload Automation ESP Edition] Refresh Rate in ESP WorkStation

    Posted Jun 13, 2012 01:24 PM
    Hello

    Inquiring what setting in the WSSPARM(WSSSET) needs to be fine-tuned to improve the response time when inserting a wob into an active schedule.

    Response time can vary from immediate to minutes (under 5)

    Production Control inserts multiple requests job a day and a timely visible verification that the Wob inserted successfully is a high value.

    WSSSET INTERVAL(08) /* Default: 5 seconds */
    WSSSET RPOLLINT(300) /* Default: 300 seconds */
    WSSSET RCONNINT(10) /* Default: 10 seconds */
    WSSSET RRSPWAIT(300) /* Default: 300 seconds */
    WSSSET PROXYEXP(300) /* Default: 300 seconds */
    WSSSET TCPWAIT(120) /* Default: 30 seconds */
    WSSSET MAXCON_LOIP(2) /* Default: 2 tasks */
    WSSSET MAXCON_PERIP(8) /* Default: 8 tasks */
    WSSSET MAXCON_TOTAL(250) /* Default: 250 tasks */


    Thanks,


    Brian Lemanski
    ESP OPSMVS Operations Analyst
    Lands' End
    608-935-6726
    Brian.Lemanski@Landsend.com<mailto:Brian.Lemanski@Landsend.com>


  • 10.  RE: [CA Workload Automation ESP Edition] CA Workload Automation ESP Edition

    Posted Jun 13, 2012 01:46 PM
    Brain, here is what we are currently using and seems to be working for us who run about 3.2 million jobs per month.

    WSSCTL SET PARM INTERVAL(5) /* General scoreboard scan int. */
    WSSCTL SET PARM RPOLLINT(300) /* Remote WSS polling interval */
    WSSCTL SET PARM RCONNINT(10) /* Remote WSS conn. retry int. */
    WSSCTL SET PARM RRSPWAIT(300) /* Remote WSS response wait int. */
    WSSCTL SET PARM PROXYEXP(300) /* Proxy task expiration interval */
    WSSCTL SET PARM TCPWAIT(300) /* Remote WSS TCP/IP receive wait */
    WSSCTL SET PARM MAXCON_LOIP(2) /* Max. connections for logons */
    WSSCTL SET PARM MAXCON_PERIP(100) /* Max. connections per IP addr. */
    WSSCTL SET PARM MAXCON_TOTAL(250) /* Max. total connections */

    Regards,

    Allen Thennes
    Safeway Inc.

    ________________________________
    From: CA Workload Automation (Mainframe) Global User Community [mailto:CommunityAdmin@communities-mail.ca.com]
    Sent: Wednesday, June 13, 2012 12:24 PM
    To: mb.2271275.98305906@myca-email.ca.com
    Subject: [CA Workload Automation ESP Edition] CA Workload Automation ESP Edition] Refresh Rate in ESP WorkStation

    Hello

    Inquiring what setting in the WSSPARM(WSSSET) needs to be fine-tuned to improve the response time when inserting a wob into an active schedule.

    Response time can vary from immediate to minutes (under 5)

    Production Control inserts multiple requests job a day and a timely visible verification that the Wob inserted successfully is a high value.

    WSSSET INTERVAL(08) /* Default: 5 seconds */
    WSSSET RPOLLINT(300) /* Default: 300 seconds */
    WSSSET RCONNINT(10) /* Default: 10 seconds */
    WSSSET RRSPWAIT(300) /* Default: 300 seconds */
    WSSSET PROXYEXP(300) /* Default: 300 seconds */
    WSSSET TCPWAIT(120) /* Default: 30 seconds */
    WSSSET MAXCON_LOIP(2) /* Default: 2 tasks */
    WSSSET MAXCON_PERIP(8) /* Default: 8 tasks */
    WSSSET MAXCON_TOTAL(250) /* Default: 250 tasks */


    Thanks,


    Brian Lemanski
    ESP OPSMVS Operations Analyst
    Lands' End
    608-935-6726
    Brian.Lemanski@Landsend.com<mailto:Brian.Lemanski@Landsend.com>
    Posted by:Brian.Lemanski
    --
    CA Communities Message Boards
    98308446
    mb.2271275.98305906@myca-email.ca.com

    "Email Firewall" made the following annotations.
    ------------------------------------------------------------------------------

    Warning:
    All e-mail sent to this address will be received by the corporate e-mail system, and is subject to archival and review by someone other than the recipient. This e-mail may contain proprietary information and is intended only for the use of the intended recipient(s). If the reader of this message is not the intended recipient(s), you are notified that you have received this message in error and that any review, dissemination, distribution or copying of this message is strictly prohibited. If you have received this message in error, please notify the sender immediately.

    ==============================================================================