Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 9 Next »

This page includes description, setup and examples for EJM Jobs notification functionality. It contains an overview of sending notification parameters, trigger options, examples of control messages with notification and additional parameters.

The EJM Jobs notification functionality allows user to get status of executing Job process thru many delivery types (FTP, email, file and so on). The functionality informs about  4 notification message types, including: 

Notification message types:

  • ACK – Acknowledgement.  Informs you that the execution of the job has just started
  • Extract – Contains extracted data from the database
  • Alert – Informs you about timeout of execution Pace Event or SRM Validation Event
  • TSR  - TaskStatusResponse. Informs you that the execution of Job has finished
It is not necessary at all that the executing Job process contains all of these 4 types above. 

Delivery Methods

See the list of available delivery methods for notifications and configurable options for them.

Sending Notification Parameters

The user can setup notification parameters in two ways:

  • In config file using reserved variables (set default settings for applying to ALL Jobs);
  • In task parameters nodes of initial Control Message (CM) to run EJM Job (to use these settings to run only that specific EJM job).

Notification parameters from Control Message supersede  the same parameters defined in config file when defined in both. This can be especially useful, when you need to apply certain parameters to a stream without affecting all processes of the environment.

Enable/Disable/Run-on-Failure-Only EJM Jobs Notification Functionality

Edit/add w_default_send_notifications global variable to apply the setting to all processes in the environment.
   OR
Use SendNotification control message task parameter to change the behavior of the process you are launching only.

The config file location is /eagle_ml-2-0_custom_cm/w_config_custom.inc

 

Config File Option

Control Message Task Parameter Option

Name

w_default_send_notifications

SendNotification

Values

Options include:

‘ALWAYS’ or ‘1’ to enable   

‘NEVER’ or ‘0’ to disable

‘ONFAILURE’ to send notification on failure case only (TSR has ‘FAILED’ final status).

Example 

<COL TAG="w_default_send_notifications" EXPRESSION="'NEVER'"/>
<taskParameter>
    <name>SendNotification</name>
    <dataType>S</dataType>
    <value>0</value>
</taskParameter>

Default Value

‘ALWAYS’

Additional note

If the “w_default_send_notifications” variable is empty or missing in config file /eagle_ml-2-0_custom_cm/w_config_custom.inc AND SendNotification is empty or missing in the CM then the default value will be used, because the notification parameter value is ‘ALWAYS’.

Examples of Control Messages with Notification

These control messages below can be dropped into the eagle_ml-2-0_default_cm_control_message stream.

This example uses an Entity extract

Remember to change the correlationId.
Extract example with notification (click to expand)
<EagleML xmlns="http://www.eagleinvsys.com/2011/EagleML-2-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="RunTaskRequest" eaglemlVersion="2-0" xsi:schemaLocation="http://www.eagleinvsys.com/2011/EagleML-2-0 eagleml-main-2-0.xsd" eaglemlType="RunTaskRequest">
    <header>
       <messageId>TEST_ENTITY_EXTRACT</messageId>
       <sentBy>http://www.client.com</sentBy>
       <sendTo>http://www.eagleinvsys.com/eagle_ml-2-0_default_cm_control_message</sendTo>
       <replyTo>http://www.client.com/Eagle Control Messages</replyTo>
       <creationTimestamp>2012-08-02T22:13:32.272-05:00</creationTimestamp>
    </header>
    <taskIdentifier>
       <correlationId correlationIdScheme="correlationIdScheme">TEST_ENTITY_EXTRACT_001</correlationId>
       <businessTaskId correlationIdScheme="businessTaskIdScheme">TEST_ENTITY_EXTRACT</businessTaskId>
    </taskIdentifier>
    <taskTypeEnum>NEW</taskTypeEnum>
    <taskParameters>
       <taskParameter>
           <name>ActionType</name>
           <dataType>S</dataType>
           <value>EXTRACT</value>
       </taskParameter>
       <taskParameter>
           <name>StreamName</name>
           <dataType>S</dataType>
           <value>eagle_ml-2-0_default_out_q</value>
       </taskParameter>
       <taskParameter>
           <name>FeedType</name>
           <dataType>S</dataType>
           <value>ENTITYEXTRACT</value>
       </taskParameter>
       <taskParameter>
           <name>BatchMode</name>
           <dataType>S</dataType>
           <value>Y</value>
       </taskParameter>
       <taskParameter>
           <name>maxrows</name>
           <dataType>S</dataType>
           <value>1</value>
       </taskParameter>
       <taskParameter>
           <name>SendNotification</name>
           <dataType>S</dataType>
           <value>ALWAYS</value>
       </taskParameter>
       <taskParameter>
           <name>ACKDeliveryMethod</name>
           <dataType>S</dataType>
           <value>FILE</value>
       </taskParameter>
       <taskParameter>
           <name>ExtractDeliveryMethod</name>
           <dataType>S</dataType>
           <value>EMAIL</value>
       </taskParameter>
       <taskParameter>
           <name>ReplyDeliveryMethod</name>
           <dataType>S</dataType>
           <value>EMAIL</value>
       </taskParameter>
       <taskParameter>
           <name>DeliveryMethod</name>
           <dataType>S</dataType>
           <value>FILE</value>
       </taskParameter>
       <taskParameter>
           <name>ACKEmailDistributionList</name>
           <dataType>S</dataType>
           <value>my_email1@eagleinvsys.com</value>
       </taskParameter>
       <taskParameter>
           <name>ResponseEmailDistributionList</name>
           <dataType>S</dataType>
           <value>my_email2@eagleinvsys.com, my_email1@eagleinvsys.com</value>
       </taskParameter>
       <taskParameter>
           <name>ExtractEmailDistributionList</name>
           <dataType>S</dataType>
           <value>my_email3@eagleinvsys.com</value>
       </taskParameter>
    </taskParameters>
</EagleML>
Load thru ACQUIRE example with notification
Remember to change the correlationId.
Load thru ACQUIRE example with notification (click to expand):
<EagleML xmlns="http://www.eagleinvsys.com/2011/EagleML-2-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="RunTaskRequest" eaglemlVersion="2-0" xsi:schemaLocation="http://www.eagleinvsys.com/2011/EagleML-2-0 eagleml-main-2-0.xsd" eaglemlType="RunTaskRequest">
    <header>
       <messageId messageIdScheme="messageIdScheme"> TEST_NOTIFICATION_MSG_ID</messageId>
       <sentBy>http://www.client.com</sentBy>
       <sendTo>http://www.eagleinvsys.com/eagle_ml-2-0_default_cm_control_message</sendTo>
       <replyTo>http://www.client.com/Eagle Control Messages</replyTo>
       <creationTimestamp>2012-08-02T22:13:32.272-05:00</creationTimestamp>
    </header>
    <taskIdentifier>
       <correlationId correlationIdScheme="correlationIdScheme">TEST_NOTIFICATION_ACQUIRE _LOAD_01</correlationId>
       <businessTaskId correlationIdScheme="businessTaskIdScheme">TEST_NOTIFICATION</businessTaskId>
    </taskIdentifier>
    <taskTypeEnum>LOAD</taskTypeEnum>
    <taskParameters>
       <taskParameter>
           <name>ActionType</name>
           <dataType>S</dataType>
           <value>ACQUIRE</value>
       </taskParameter>
       <taskParameter>
           <name>StreamName</name>
           <dataType>S</dataType>
           <value>eagle_ml-2-0_default_cm_acquire_data</value>
       </taskParameter>
       <taskParameter>
           <name>ACKDeliveryMethod</name>
           <dataType>S</dataType>
           <value>EMAIL</value>
       </taskParameter>
       <taskParameter>
           <name>ReplyDeliveryMethod</name>
           <dataType>S</dataType>
           <value>EMAIL</value>
       </taskParameter>
       <taskParameter>
           <name>Data</name>
           <dataType>S</dataType>
           <value/>
       </taskParameter>
       <taskParameter>
           <name>FileName</name>
           <dataType>S</dataType>
           <value>missed_file.csv.trr.tar.gz.base64.b64</value>
       </taskParameter>
    </taskParameters>
</EagleML>

Manage EJM Notification Filenames 

Default Pattern

Default TSR and ACK names are generated as follows:

1. In case of a simple one step process (for example, a common extract) the user will see the following TSR and ACK messages with the same name: 
[initial corrId] + '_' + [time of generation of the ack or tsr message in hhmmss] + '_'+ [uid] + '-u-' + [login of the user-RTR sender]  + '-u-' + [rtr file name] .xml
For example: coodId17_072915-2G770MFVU0SK2SVE-u-USER-u-rtr_name.xml

2. In case of a multi step process with a lot of ancillary notifications flying back and forward (for example, extraction via generic_extract workflow): 
TSR: [corrId] + [ProcessWorkflowName] + [parent task id] + [task id]+ [datetimestamp in YYYYMMDD_hhmmss format] .xml 
ACK: [corrId] + [ProcessWorkflowName] + [task id]+ [datetimestamp in YYYYMMDD_hhmmss format] .xml

where ProcessWorkflowName is a complex variable linked with the name of the workflow in charge of the launch of the step.

To set a custom name for your TSR and ACK files, you can use several additional task parameters in the control message: TSRNamePatternTSRStrictPattern and ACKStrictPattern.

TSRNamePattern Parameter

TSRNamePattern is used to link the TSR message with the name of the “TSRNamePattern” parameter as part of TSR file name. Global alternative: W_TSR_NAME_PATTERN

The following is an example of the use of the TSRNamePattern.

Example using TSRNamePattern Parameter (click to expand):
<EagleML xmlns="http://www.eagleinvsys.com/2011/EagleML-2-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:SchemaLocation="http://www.eagleinvsys.com/2011/EagleML-2-0 eagleml-main-2-0.xsd" eaglemlVersion="2-0" eaglemlType="RunTaskRequest" xsi:type="RunTaskRequest">
       <header>
              <messageId messageIdScheme="messageIdScheme">MSGId_TSRPattern_01</messageId>
              <sentBy>http://www.client.com</sentBy>
              <sendTo>http://www.eagleinvsys.com/eagleml-2-0_control_messages</sendTo>
              <replyTo>http://www.client.com/Eagle Control Messages</replyTo>
              <creationTimestamp>2014-25-04T22:13:32.272-05:00</creationTimestamp>
       </header>
       <taskIdentifier>
              <correlationId correlationIdScheme="correlationIdScheme">CORRID_TSRPattern_01</correlationId>
              <businessTaskId correlationIdScheme="businessTaskIdScheme">BT_TSRPattern_01</businessTaskId>
       </taskIdentifier>
       <taskTypeEnum>LOAD</taskTypeEnum>
       <taskParameters>
              <taskParameter>
                     <name>DeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ACKDeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ReplyDeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ActionType</name>
                     <dataType>S</dataType>
                     <value>ACQUIRE</value>
              </taskParameter>
              <taskParameter>
                     <name>StreamName</name>
                     <dataType>S</dataType>
                     <value>eagle_ml-2-0_default_cm_acquire_data</value>
              </taskParameter>
              <taskParameter>
                     <name>TSRNamePattern</name>
                     <dataType>S</dataType>
                     <value>TestTSRNmPat</value>
              </taskParameter>
              <taskParameter>
                     <name>WAREHOUSE</name>
                     <dataType>S</dataType>
                     <value>test_ytar_PosWithBatch2.xml</value>
              </taskParameter>
       </taskParameters>
</EagleML>

TSRStrictPattern Parameter

TSRStrictPattern is the parameter that is used to link the TSR message with the name “CorrelationId_TSRStrictPattern” where CorrelationID is the Correlation ID and TSRStrictPattern is the value placed in that parameter.parameter as part of TSR file name. Global alternative: W_TSR_STRICT_PATTERN

The following is an example of the use of the TSRStrictPattern, with the name of the TSR as “CORRID_TSRPattern_01_TSR_ TestTSRNmPat20140710-062456-TestCmTaskPar1.xml”, where CORRID_TSRName_01 is the correlation ID, TestTSRNmPat is the TSRStrictPattern parameter value, and 20140710-062456 is the time stamp the control message was created (as controlled by suffixing the code name “timestamp_” to the end of our TSRStrictPattern.)

Example using TSRStrictPattern Parameter (click to expand):
<EagleML xmlns="http://www.eagleinvsys.com/2011/EagleML-2-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:SchemaLocation="http://www.eagleinvsys.com/2011/EagleML-2-0 eagleml-main-2-0.xsd" eaglemlVersion="2-0" eaglemlType="RunTaskRequest" xsi:type="RunTaskRequest">
       <header>
              <messageId messageIdScheme="messageIdScheme">MSGId_TSRName_01</messageId>
              <sentBy>http://www.client.com</sentBy>
              <sendTo>http://www.eagleinvsys.com/eagleml-2-0_control_messages</sendTo>
              <replyTo>http://www.client.com/Eagle Control Messages</replyTo>
              <creationTimestamp>2014-25-04T22:13:32.272-05:00</creationTimestamp>
       </header>
       <taskIdentifier>
              <correlationId correlationIdScheme="correlationIdScheme">CORRID_TSRName_01</correlationId>
              <businessTaskId correlationIdScheme="businessTaskIdScheme">BT_TSRName_01</businessTaskId>
       </taskIdentifier>
       <taskTypeEnum>LOAD</taskTypeEnum>
       <taskParameters>
              <taskParameter>
                     <name>DeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ACKDeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ReplyDeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ActionType</name>
                     <dataType>S</dataType>
                     <value>ACQUIRE</value>
              </taskParameter>
              <taskParameter>
                     <name>StreamName</name>
                     <dataType>S</dataType>
                     <value>eagle_ml-2-0_default_cm_acquire_data</value>
              </taskParameter>
              <taskParameter>
                     <name>TSRStrictPattern</name>
                     <dataType>S</dataType>
                     <value>TestTSRNm_timestamp_</value>
              </taskParameter>
              <taskParameter>
                     <name>WAREHOUSE</name>
                     <dataType>S</dataType>
                     <value>test_ytar_PosWithBatch2.xml</value>
              </taskParameter>
       </taskParameters>
</EagleML>

ACKStrictPattern Parameter

ACKStrictPattern is the parameter that is used to link the TSR message with the name “CorrelationId_ACKStrictPattern” where CorrelationID is the Correlation ID and ACKStrictPattern is the value placed in that parameter as part of TSR file name. Global alternative: W_ACK_STRICT_PATTERN

The following is an example of the use of the ACKStrictPattern, with the name of the resulting ACK file as “CORRID_ACKName_01_TestACKNm2014711-080449.xml”, where CORRID_TSRName_01 is the correlation ID, TestACKNm is the ACKStrictPattern parameter value, and 20140710-063245 is the time stamp the control message was created (as controlled by suffixing the code name “timestamp_” to the end of our ACKStrictPattern.)

Example using ACKStrictPattern Parameter (click to expand):
<EagleML xmlns="http://www.eagleinvsys.com/2011/EagleML-2-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:SchemaLocation="http://www.eagleinvsys.com/2011/EagleML-2-0 eagleml-main-2-0.xsd" eaglemlVersion="2-0" eaglemlType="RunTaskRequest" xsi:type="RunTaskRequest">
       <header>
              <messageId messageIdScheme="messageIdScheme">MSGId_ACKName_01</messageId>
              <sentBy>http://www.client.com</sentBy>
              <sendTo>http://www.eagleinvsys.com/eagleml-2-0_control_messages</sendTo>
              <replyTo>http://www.client.com/Eagle Control Messages</replyTo>
              <creationTimestamp>2014-25-04T22:13:32.272-05:00</creationTimestamp>
       </header>
       <taskIdentifier>
              <correlationId correlationIdScheme="correlationIdScheme">CORRID_ACKName_01</correlationId>
              <businessTaskId correlationIdScheme="businessTaskIdScheme">BT_ACKName_01</businessTaskId>
       </taskIdentifier>
       <taskTypeEnum>LOAD</taskTypeEnum>
       <taskParameters>
              <taskParameter>
                     <name>DeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ACKDeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ReplyDeliveryMethod</name>
                     <dataType>S</dataType>
                     <value>FILE</value>
              </taskParameter>
              <taskParameter>
                     <name>ActionType</name>
                     <dataType>S</dataType>
                     <value>ACQUIRE</value>
              </taskParameter>
              <taskParameter>
                     <name>StreamName</name>
                     <dataType>S</dataType>
                     <value>eagle_ml-2-0_default_cm_acquire_data</value>
              </taskParameter>
              <taskParameter>
                     <name>ACKStrictPattern</name>
                     <dataType>S</dataType>
                     <value>TestACKNm_timestamp_</value>
              </taskParameter>
              <taskParameter>
                     <name>WAREHOUSE</name>
                     <dataType>S</dataType>
                     <value>test_ytar_PosWithBatch2.xml</value>
              </taskParameter>
       </taskParameters>
</EagleML>
  • No labels