It's all about the answers!

Ask a question

Submit a JOB with JCL that is created dynamically in RTC


Jorge Nagasaki (17512217) | asked Sep 12 '12, 10:34 p.m.
I have a customer that needs to run a JOB (big job with compile, link , with many custom steps ) during the build process of RTC on z/OS.  I tried to run a REXX program and tried to submit the JOB , but looks like I cannot run a submit JOB command from this environment  ( error: trying to run invalid function in dynamic TSO environment error message).  
I looked in to the .submitJCL command on RTC , but this is very limited , as I could not figure out how to return the condition code of the JOB to RTC, to validate if the JOB was run successfully)  , please any suggestion on this matter?  tks

4 answers



permanent link
Tami Takamiya (2011110) | answered Sep 14 '12, 2:35 p.m.
JAZZ DEVELOPER
Jorge,

I am not sure about the details of what you are trying to do with the .submitJCL command.  If you are trying to issue the .submitJCL command from one of translators, I say it is not possible.  If you need to submit a single JCL after a dependency build is done, you can use the .submitJCL command as a post-build command.

Tami

Comments
Jorge Nagasaki commented Sep 14 '12, 3:22 p.m.

Hi Tami,

I am actually using the submitJCL in Pre-processing command. The problem is that the submitJCL is not returning the MAXCC from the submitted JOB..

The Job that is submitted are getting Condition Code 12 , and for this it has MAXCC=12... BUT the submitJCL returns return code = 0.


permanent link
Tami Takamiya (2011110) | answered Sep 14 '12, 4:05 p.m.
JAZZ DEVELOPER
As far as I looked at the bfagent code, I believe it is designed to return MAXCC.  Since I am not the owner of the code, I cannot tell you more about that.  I recommend you to report this as a PMR.

You can take the bfagent activity log with setting the BF_DEBUG_JOBMON environment variable. .e.g. insert the following line to your startbfa.sh script:
====
export BF_DEBUG_JOBMON=1
====
and comment out the activity_log line in your bfagent.conf file with a file path to the activity log file before restarting your bfagent.  If you could send the log file when you open a PMR, it would be helpful to determine the case of the problem.

Tami

permanent link
Donald Poulin (2249119107) | answered Sep 17 '12, 7:55 a.m.
You can code a REXX to use file tailoring which is a capability to "read" in to a REXX a set of "skeleton" JCL and then add parameters and job card and submit to JES. The weakness with this is that the job after submit, runs asynchronously to the REXX so you need to add a step on the end of the submitted job to create a file that indicates if the job ended successfully. Then in your REXX after the submit command you can execute a loop to check for the existence of the file on a periodic bases (like every 10 seconds).

permanent link
Jorge Nagasaki (17512217) | answered Sep 17 '12, 10:16 a.m.

REXX code cannot submit JOBs in the "RTC " environment ( Dynamic TSO environment) , in other TSO environments is Ok . But we learned late that RTC "creates " a dynamic TSO environment and this has restrictions on some commands ( including submit )

About .submiJCL command submitted a PMR for the return code . Looks like .submitJCL are setting maxcc to zero always:  For reference PMR 44911,999,631.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.