ESP Workload Automation

Expand all | Collapse all

OPS/JES/ESP

  • 1.  OPS/JES/ESP

    Posted Apr 03, 2012 02:36 PM
    Hi All,
    In our shop we use OPS to issue certain commands to ESP. I recently decided to make some changes to these commands and have come up with some undesirable results.

    The old command that was issued was "F ESPP,AJ JOBNAME COMPLETE APPL(APPLNAME) This worked fine but I no longer want to force complete the job.

    I now want to remove the hold from the job. We changed the OPS issued command to "F ESPP,AJ JOBNAME RELEASE APPL(APPLNAME) This receives an error of invalid keyword Release

    When I tested this command, I used a self completing task that issued ESP AJ JOBNAME RELEASE APPL(APPLNAME) This worked well and removed the hold from my job.

    So the issue is that when issuing this command thru ESP, it works with the RELEASE but when issued thru OPS/JES it does not work.

    Why does COMPLETE work but RELEASE will not? I am at a loss.

    Any ideas?

    Sherri


  • 2.  RE: [CA Workload Automation ESP Edition] OPS/JES/ESP

    Posted Apr 03, 2012 02:47 PM
    See the note in the Command Reference for the APPLJOB command:




    You can issue the APPLJOB command from a system console only to complete an application or a job within an application. This functionality requires USERMOD 35.



    Gene Budbill
    Sr Services Consultant
    CA Technologies

    From: CA Workload Automation (Mainframe) Global User Community [mailto:CommunityAdmin@communities-mail.ca.com]
    Sent: Tuesday, April 03, 2012 2:37 PM
    To: mb.2271275.97780527@myca-email.ca.com
    Subject: [CA Workload Automation ESP Edition] OPS/JES/ESP

    Hi All,
    In our shop we use OPS to issue certain commands to ESP. I recently decided to make some changes to these commands and have come up with some undesirable results.

    The old command that was issued was "F ESPP,AJ JOBNAME COMPLETE APPL(APPLNAME) This worked fine but I no longer want to force complete the job.

    I now want to remove the hold from the job. We changed the OPS issued command to "F ESPP,AJ JOBNAME RELEASE APPL(APPLNAME) This receives an error of invalid keyword Release

    When I tested this command, I used a self completing task that issued ESP AJ JOBNAME RELEASE APPL(APPLNAME) This worked well and removed the hold from my job.

    So the issue is that when issuing this command thru ESP, it works with the RELEASE but when issued thru OPS/JES it does not work.

    Why does COMPLETE work but RELEASE will not? I am at a loss.

    Any ideas?

    Sherri
    --
    CA Communities Message Boards
    97783067
    mb.2271275.97780527@myca-email.ca.com<mailto:mb.2271275.97780527@myca-email.ca.com>


  • 3.  RE: [CA Workload Automation ESP Edition] OPS/JES/ESP

    Posted Apr 03, 2012 03:08 PM
    Dang...that was so NOT the answer I was hoping for.

    This has caused us so many issues when our batch is running late. A new appl gets loaded before the older appl is totally complete (due to the outstanding jobs.) The AJ command tries to issue against the newest appl rather than finding the correct job in the older appl. I have tried to put the jobs on hold but because the force command overrides the hold, that doesn't keep the newer jobs from being marked. I can't put a new job out there because then it has to have a qualifier and the message issued from ops will not match. I have tried to reload the jobs with a new appl but then the outstanding jobs in the old appl don't get force completed, it just marks the ones in the newest appl.
    I had decided that putting the jobs on a delaysub and hold plus changing the complete to release would allow the operators better control when batch was running late. See, even if the wrong job was released it wouldn't go anywhere. The older job could then be released manually, the newer job could just have the manual hold put back on. Still a bit clunky but no issues later this way.

    Back to the drawing board.


  • 4.  RE: [CA Workload Automation ESP Edition] OPS/JES/ESP

    Posted Apr 03, 2012 03:19 PM
    Well, it sounds like your OPS routine is parsing out the JOB and APPL name. You could TRIGGER an event to do the RELEASE and pass the JOB and APPL in the USER1/USER2 fields.

    The better solution is to examine the issue as you have outlined it and see if there is a better way to solve the problem.


    Gene Budbill
    Sr Services Consultant
    CA Technologies

    From: CA Workload Automation (Mainframe) Global User Community [mailto:CommunityAdmin@communities-mail.ca.com]
    Sent: Tuesday, April 03, 2012 3:08 PM
    To: mb.2271275.97780586@myca-email.ca.com
    Subject: RE: [CA Workload Automation ESP Edition] OPS/JES/ESP

    Dang...that was so NOT the answer I was hoping for.

    This has caused us so many issues when our batch is running late. A new appl gets loaded before the older appl is totally complete (due to the outstanding jobs.) The AJ command tries to issue against the newest appl rather than finding the correct job in the older appl. I have tried to put the jobs on hold but because the force command overrides the hold, that doesn't keep the newer jobs from being marked. I can't put a new job out there because then it has to have a qualifier and the message issued from ops will not match. I have tried to reload the jobs with a new appl but then the outstanding jobs in the old appl don't get force completed, it just marks the ones in the newest appl.
    I had decided that putting the jobs on a delaysub and hold plus changing the complete to release would allow the operators better control when batch was running late. See, even if the wrong job was released it wouldn't go anywhere. The older job could then be released manually, the newer job could just have the manual hold put back on. Still a bit clunky but no issues later this way.

    Back to the drawing board.
    Posted by:SherriDoerflein
    --
    CA Communities Message Boards
    97783126
    mb.2271275.97780586@myca-email.ca.com<mailto:mb.2271275.97780586@myca-email.ca.com>


  • 5.  RE: OPS/JES/ESP

    Posted Apr 04, 2012 10:21 AM
    Not sure what you are really trying to do or solve.
    It looks like if you have application A1 with jobs 1,2,3 in it running late and a new application A1 is generated, you want to release the hold on the jobs in the first application A1. Is that correct?


  • 6.  RE: OPS/JES/ESP

    Posted Apr 04, 2012 11:02 AM
    It's confusing, I know.
    This was all set up before my time at W&S. When we had Jobtrac, the job had a manual hold on it. CICS issued a system message that OPS captured. OPS then would issue a command to Jobtrac telling it to release the manual hold on the job.
    When we converted to ESP, CA's solution to this was to schedule a task (dummy job) that would release the actual job. CICS issues a system message to OPS, OPS issues a command to ESP to force complete the task. The job is then released. The OPS rule issued is "F 'ESP',AJ 'JOBTASK' COMPLETE APPL('APPL')"


    APPL TODAY

    Job JOBA.1 TASK
    RUN WORKDAY
    RELEASE ADD(JOBA)
    ENDJOB

    Job JOBA
    RUN WORKDAY
    RELEASE ADD(JOBB)
    ENDJOB


    JOBA.1 is loaded in schedule TODAY. CICS is running behind and has not yet issued the message for JOBA.1 task to be force completed. Schedule TODAY is loaded again. We now have two occurances of JOBA.1 task. The default in ESP is to find the newest appl. You can change this to oldest but you have the same problem in reverse. The CICS message is issued, OPS captures it and marks the newest task complete.

    My solution (that will not work) was to get rid of the tasks and just put the job on hold along with a delaysub. I wanted OPS to issue a command to release the job. If the wrong job was released due to the ESP default and CICS being behind, the delaysub would keep the job from running and a hold could be put back on.


  • 7.  RE: [CA Workload Automation ESP Edition] RE: OPS/JES/ESP

    Posted Apr 04, 2012 11:40 AM
    So, does the APPL need to be scheduled in advance or could it be triggered in by OPS in response to the CICS message?

    If all of the jobs in the APPL are related to processing that should happen whenever CICS issues the message this might be an option. Remove the SCHEDULE statement from the EVENT and change the AJ jobtask COMPLETE to a TRIGGER cics.event. Where this would not work is if the JOBA.1 TASK is in the middle of an application that is waiting on the CICS message.

    With this approach you only have a generation of the application active when it is really needed. Even if CICS is running late, no problem. When the CICS message is issued the APPL is built to submit the job(s).


    Gene Budbill
    Sr Services Consultant
    CA Technologies

    From: CA Workload Automation (Mainframe) Global User Community [mailto:CommunityAdmin@communities-mail.ca.com]
    Sent: Wednesday, April 04, 2012 11:06 AM
    To: mb.2271275.97784483@myca-email.ca.com
    Subject: [CA Workload Automation ESP Edition] RE: OPS/JES/ESP

    It's confusing, I know.
    This was all set up before my time at W&S. When we had Jobtrac, the job had a manual hold on it. CICS issued a system message that OPS captured. OPS then would issue a command to Jobtrac telling it to release the manual hold on the job.
    When we converted to ESP, CA's solution to this was to schedule a task (dummy job) that would release the actual job. CICS issues a system message to OPS, OPS issues a command to ESP to force complete the task. The job is then released. The OPS rule issued is "F 'ESP',AJ 'JOBTASK' COMPLETE APPL('APPL')"


    APPL TODAY

    Job JOBA.1 TASK
    RUN WORKDAY
    RELEASE ADD(JOBA)
    ENDJOB

    Job JOBA
    RUN WORKDAY
    RELEASE ADD(JOBB)
    ENDJOB


    JOBA.1 is loaded in schedule TODAY. CICS is running behind and has not yet issued the message for JOBA.1 task to be force completed. Schedule TODAY is loaded again. We now have two occurances of JOBA.1 task. The default in ESP is to find the newest appl. You can change this to oldest but you have the same problem in reverse. The CICS message is issued, OPS captures it and marks the newest task complete.

    My solution (that will not work) was to get rid of the tasks and just put the job on hold along with a delaysub. I wanted OPS to issue a command to release the job. If the wrong job was released due to the ESP default and CICS being behind, the delaysub would keep the job from running and a hold could be put back on.
    --
    CA Communities Message Boards
    97787023
    mb.2271275.97784483@myca-email.ca.com<mailto:mb.2271275.97784483@myca-email.ca.com>


  • 8.  RE: [CA Workload Automation ESP Edition] RE: OPS/JES/ESP

    Posted Apr 04, 2012 12:15 PM
    Gene,
    I wish I could use that approach. Unfortunately these jobs are a part of a big application that waits to continue to process based on when the CICS message is issued. The appls themselves are fairly large also, one has about 1300 jobs, the other around 3500.
    Sherri


  • 9.  RE: OPS/JES/ESP

    Broadcom Employee
    Posted Apr 04, 2012 01:20 PM
    I personally like use resource to control jobs that may be in different APPL or generation. In you case:
    APPL TODAY

    Job JOBA.1 TASK SELFCOMPLETING
    RUN WORKDAY
    RESOURCE (1,CICSA)
    RELEASE ADD(JOBA)
    ENDJOB

    Job JOBA
    RUN WORKDAY
    RELEASE ADD(JOBB)
    ENDJOB

    And OPS will issue "/F ESP,RESDEF CICSA SET AVAIL(1)" when CICS issued the message, which will complete the TASK. For the condition that more than one gens are active, the TASK in oldest gen should be the first in the resource waiting queue and therefore complete. Note: you need to define the resource as DEPLETABLE, which means it only allows one TASK satisfied with the resource.

    Hope it helps,

    Lucy


  • 10.  RE: OPS/JES/ESP

    Posted Apr 04, 2012 01:27 PM
    Thanks Lucy!
    I like using resources also.This is certainly worth exploring!!
    Sherri


  • 11.  RE: OPS/JES/ESP

    Posted Apr 09, 2012 01:55 PM
    Ok, see a little better now...

    So in our case, we do this.

    OPS calls CYBESDT1 with parm CICS1DN.IS.DOWN or CICS1DN.IS.UP

    Event triggers a BR14 job with dummy input.

    EVENT ID(SCHPROD.CICS1DN) SYSTEM(x) REPLACE
    INVOKE 'x.ESP.SCHD(CICS1DN)'
    DSTRIG CICS1.IS.DOWN EXPLICIT
    ENDDEF

    Application is coded with an external and post oldest.

    APPL xxxxxxxx POST_OLDEST JOB_ANCESTOR_WAIT(ANY)

    JOB CICS1DN EXTERNAL SCOPE(-05:00)
    RUN LAST WORKDAY OF MONTH
    RELEASE (xxxxxxx)
    ENDJOB


  • 12.  RE: OPS/JES/ESP

    Posted Apr 09, 2012 02:18 PM
    Thanks!!! Another approach that I can try.
    Sherri