Hi All,
I have created an event to send out success email notifications to the business owners. I want this event to be triggered once the job has finished. How can I do it ?
I have included this event inside the job, but that is of no use.
Thanks!
Quote from: praveenb77 on 13 Aug 2015 02:36:06 PM
I have included this event inside the job, but that is of no use.
Why is it of no use? If you run the job contents sequentially and the event is the last thing in the list, won't it do exactly what you need?
MF.
Just stumbled across this and never thought to include the EventStudio agent inside the job! Will give this a test and see if it resolves my issue...
The job that (even as last step) runs the agent is not yet finished when the agent is running. I suspect that's why the original poster said it's of no use.
Hi Hespora,
I tried what MFGF suggested and it worked for me. Setting the steps inside the job to run sequentially, rather than all at once, ensures that the EventStudio agent only runs once all previous steps have finished. So far it has been working as expected, however I am doing further tests and monitoring to make sure it does what it's supposed to.
Cheers,
Dev
Hi Dev,
that is weird (working differently in the C10 instance I'm working with), but I think we may just be speaking of different things here. Doesn't matter; only matters that it works for you and gets you what you need! :)
Well, it looks like it may be a little short-lived....
The agent works and I get an e-mail when the job completes, however when it fails it still says it's successful. I've updated the agent so that it is only monitoring the job (where previously I set it to monitor the job AND ensure the completion state was "Success") and the status is included in the e-mail that is sent out. I figure this would work, so that it will e-mail the user with the status of the job, whether it passes or fails. What it is doing is including BOTH success and failure states in the e-mail, regardless of whether the job is successful or not.
What I want is for it to say that it's failed when it fails and that it's succeeded when it is successful. What am I missing? As mentioned above, the agent is set to monitor the particular job, the e-mail is configured with "[Job Status]" in the text and the Task Execution is set to "New Events" only. Any suggestions?
Cheers!
Dev
Can still only suggest to use the procedure outlined in my other post: http://www.cognoise.com/index.php/topic,30712.msg104275.html#msg104275
Yes, that one will always send you the "job finished" mail regardless of the outcome, but it will additionally send the "job failed" mail in case of failure. I have that setup for a daily report going out to ~100 recipients each with their own job, and the setup so far has never failed me.
Thanks Hespora, will give your solution a try and see if that works better.
Hi Hespora,
I've tried your solution and have found that it works when the job completes successfully, however when it fails it still sends out the success e-mail along with the failed e-mail. I've followed the exact steps in your other post, is there anything else that I'm missing?
Cheers,
Dev
no; like I said, that one will be sent always. It's basically just a notice that the job is *complete*, not that it *succeeded*.
Thought so. Thanks for your help, much appreciated.