Automic Workload Automation

 View Only
  • 1.  Email notification for failed objects using SLO

    Posted Feb 15, 2024 04:33 AM

    Hello Community,

    Is there any possible way to get the notification for all the failed objects in a client using an SLO object?

    We configured the SLO object and selected the condition as JOBS but in some cases we don't receive a notification if jobs activated by a JSCH.

    So, we need notification for failure of any type of JOBS and JOBP that is triggered by JSCH or EVNT or C_Period.
    Please let us know if can we achieve this by SLO.

    Or if there is any script which does the work, please let me know

    Thank you!



  • 2.  RE: Email notification for failed objects using SLO

    Posted Feb 15, 2024 11:05 AM

    Try Using Any instead of All. 

    You can add Criterion to add another Object type, if you want. 

    I prefer "ends with Any_Ok" and "On violation send email using a Call Notify object". 

    That way if it's anything other than Any_Ok, it will send an email. 

    Create the Call Notification object, don't forget to add who you want the email to go to. 

    I also like to update the Process tab to individualize the Subject line:

    Another example:

    I also use it to send emails to ServiceNow to create incidents for failed jobs

    You can update the Notification page of a Call Object as well. 

    Be sure you Set the variable in the Process tab as well. 

    this is the email the above sends:




  • 3.  RE: Email notification for failed objects using SLO

    Posted Feb 16, 2024 01:10 AM

    Hi Marilyn,

    thanks for your suggestion,

    we have configured the slo object the same way you have explained above, we are not sure about the call object, can you please provide us the script for the call object configuration that you have mentioned in the process tab of the call object?

    Thanks,

    Abhishek




  • 4.  RE: Email notification for failed objects using SLO

    Posted Feb 16, 2024 03:49 PM

    Create a Notification (Call)

    Drop down the SLM

    Create Fullfillment_Mail_Notification. 

    Then update it to your specifications:

    In the Process field of the Call Notify object. I use the following: you can update it to your specifications. 

    !Get Script variable values
    :read &uc_slm_slo_name#,,
    :read &uc_slm_service_name#,,
    :read &uc_slm_service_status#,,
    :read &uc_slm_service_runid#,,
    :read &uc_slm_service_time#,,

    !:if &uc_slm_service_status# = "1897"
    !:  read &uc_slm_violation_msg_number#,,
    !:  read &uc_slm_violation_msg_insert#,,
    !:  set &slm_violation# = get_msg_txt(&uc_slm_violation_msg_number#,&uc_slm_violation_msg_insert#)
    !:  put_att CO_PRIORITY = "HIGH"
    !:else
    !:  set &slm_violation# = "-"
    !:  put_att CO_PRIORITY = "HIGH"
    !:endif

    :set &system# = GET_UC_SYSTEM_NAME()
    :set &client# = SYS_ACT_CLIENT()
    :set &lang# = SYS_USER_LANGUAGE()
    !
    !:set &slm_statustext# = get_msg_txt(&uc_slm_service_status#,'')
    !:set &slm_statustext# = "&slm_statustext# (&uc_slm_service_status#)"

    !:if &lang# = 'E'
    :  put_att SUBJECT = "SIT/AUT Job Failure Notification, &uc_slm_service_name#, RunID: &uc_slm_service_runid#, Client: &$client#"
    !:  set &tt = "Notification"
    !:  set &ht = "Service &slm_statustext#"
    !:  set &c1#="AE System"
    !:  set &c2#="Client"
    !:  set &c3#="SL Objective"
    !:  set &c4#="Service Name"
    !:  set &c5#="Service RunID"
    !:  set &c6#="Status"
    !:  set &c7#="Detection Time"
    !:  set &c8#="Message"
    !:endif
    !
    !:if &lang# = 'D'
    !:  put_att SUBJECT = "Service &slm_statustext#: &uc_slm_service_name#, RunID: &uc_slm_service_runid#, Mandant: &$client#"
    !:  set &tt = "Benachrichtigung"
    !:  set &ht = "Service &slm_statustext#"
    !:  set &c1#="AE System"
    !:  set &c2#="Mandant"
    !:  set &c3#="SL Objective"
    !:  set &c4#="Service Name"
    !:  set &c5#="Service RunID"
    !:  set &c6#="Status"
    !:  set &c7#="Feststellungszeitpunkt"
    !:  set &c8#="Meldung"
    !:endif
    !
    !:if &lang# = 'F'
    !:  put_att SUBJECT = "Service &slm_statustext#:'&uc_slm_service_name#' RunID:'&uc_slm_service_runid#' Client:'&$client#'"
    !:  set &tt = "Notification#"
    !:  set &ht = "Service &slm_statustext#"
    !:  set &c1#="AE système"
    !:  set &c2#="Client"
    !:  set &c3#="SL Objectif"
    !:  set &c4#="Nom du service"
    !:  set &c5#="RunID du service"
    !:  set &c6#="Statut"
    !:  set &c7#="Temps de détection"
    !:  set &c8#="Message"
    !:endif
    !

    In the Notification Field, I use this

    "SIT/AUT Job Failure Notification, &uc_slm_service_name#, RunID: &uc_slm_service_runid#, Client: &$client#"




  • 5.  RE: Email notification for failed objects using SLO

    Posted Sep 04, 2024 11:17 AM

    I am trying something similar, but trying to get more granular details.  Has anyone found a way to pass values like queue and cause?  I can pass the "caused by" value only if I have a post process in the job that gets that value. I would rather not modify all my jobs to need a post processing process.