Shilpa Done
Shilpa Done

Reputation: 15

how to send a mail when workflow not triggered at given time in informatica

I have a workflow which gets triggered everyday in the Morning at 07:15 AM.I want to get an email to my Id from Informatica when the workflow doesn't get trigerred within 3 min from the start time.

Upvotes: 0

Views: 231

Answers (1)

Koushik Roy
Koushik Roy

Reputation: 7387

You have two options -

  1. easiest would be - create another workflow(scheduled at 7:18 AM) with a command task which will check a file. After command task, put a condition to the task link status=1 and then add a email task.
    Add a touch command as pre session to the main workflow. New workflow will be like -
start -->cmd task -->|--link status<>0--> email task

command task will be like -

#!/bin/sh
if [ -r /somedir/ind.txt ]; then
  exit 0
  rm /somedir/ind.txt
else
  exit 1
fi

Now, in real time, at 7:15 the wkflow will start and crete the file, second workflow will detect and do nothing. Now , if file doenst exist, it will mail.

  1. second option will be, you can create a cron script that starts around 7:18AM, check if file exist or not - if file is absent, it will mail and delete the file. Your command file should be like this -
#!/bin/sh
if [ -r /somedir/ind.txt ]; then
  exit 0
  rm /somedir/ind.txt
  mail -s <...some command...>
else
  exit 1
fi

Upvotes: 1

Related Questions