Replace the FILE_TRIGGER WOB with an OS native job that checks for the file and use the conditional release.Listed below is an example for Linux:
LINUX_JOB LINCHECK AGENT CIL001 CMDNAME /bin/bash USER <valid user> ARGS -c 'ls -l /apps/files/dev/indicator1_go' EXITCODE 0 SUCCESS EXITCODE 2 SUCCESS RUN ANYDAY RELEASE ADD(FOUND) COND(RC(0)) RELEASE ADD(NOTFOUND) COND(RC(2))ENDJOB JOB FOUND TASK SELFCOMPLETING SEND 'File exists!' U(*) RUN ANYDAY ENDJOB JOB NOTFOUND TASK SELFCOMPLETING SEND 'File does NOT Exist.' U(*) RUN ANYDAY ENDJOB
Hi Loren,Could you try with A option? Like:
RELEASE ADD(NO_FILE_PATH(A))It means to release NO_FILE_PATH when the FILE_TRIGGER fails.Another way is to define two FILE_TRIGGER wobs: one with EXIST on FILENAME, and another with NOTEXIST on FILENAME. The success one will release related wobs.Hope this helps,Lucy
I have tried using what you describe but if I have 2 WOBs FILE_TRIGGER EXIST and FILE_TRIGGER NOTEXIST won't one complete and the other will FAIL with Status "File Exists/File does not Exist"?I created a PROC with 4 WOBs:
JOB TYPE-JOBNAME---HC-RELEASES FileTrig EXIST 0 FOUND FileTrig NOTEXIST 0 NOTFOUND TASK FOUND 1 (NONE) TASK NOTFOUND 1 (NONE)
When I trigger it and the file exists
Job Name Agent Name ApplName Gen# CCode Job Status EXIST LJ_GALPCLU00014 FINDFILE 23 0 File Exists NOTEXIST LJ_GALPCLU00014 FINDFILE 23 1 File Exists FOUND FINDFILE 23 0 COMPLETED AT 15.39 14 NOV NOTFOUND FINDFILE 23 - WAITING, HC=1
When I trigger and the file does NOT exist
EXIST LJ_GALPCLU00014 FINDFILE 22 1 File does not Exist NOTEXIST LJ_GALPCLU00014 FINDFILE 22 0 File does not exist FOUND FINDFILE 22 - WAITING, HC=1 NOTFOUND FINDFILE 22 0 COMPLETED AT 15.37 14 NOV
In both cases I have a failed job and incomplete jobs in the ESP PROC.
How would you handle that?
Lucy, for your suggestion, I use the letter A, just as you typed? ADD(<JOBNAME>(A))
RELEASE ADD(NO_FILE_PATH(A))FILE_TRIGGER EXIST fails when I try that thought. If I am using it correctly.