This documentation supports an earlier version of BMC Helix Operations Management.

To view the documentation for the latest version, select 23.3 from the Product version picker.

Example: Retrieve the timestamp as a date format

Scenario

Sarah is an administrator at Apex Global. She wants to perform event diagnosis and track event logging. To achieve this goal, she wants to retrieve the current time in the MM/dd/YYYY format (for example) and enrich the message slot of the event with the retrieved timestamp value by using an advanced enrichment policy.

To enrich the event message, perform the following steps:

  1. Define the event selection criteria.
  2. Build the policy workflow.

Actions used in the example

The following actions are used in the example:

  • Variable
  • Enrich

For more information about actions, see Actions for advanced and time-based enrichment.

To define the event selection criteria

  1. Select Configuration > Event Policies and click Create.
  2. In the Event Selection Criteria, define a condition to select events from the class EVENT that contain the message "testTime".

The following image illustrates how the event selection criteria will look:

To learn how to construct the event selection criteria, see Creating and enabling event policies.

To build the policy workflow

On the Advanced Enrichment page, perform the following steps to build the policy workflow:
The page .Example: Add operation note for event assignment vDec_2021 was not found  -- Please check/update the page name used in the MultiExcerpt-Include macro

  1. Add the Variable action to retrieve the current timestamp in the specified date format and to store the result of the CurrentFormattedTimeStamp function as the variable value.


  2. Add an Enrich action to enrich the message with the formatted timestamp.

Results

The resulting policy workflow retrieves the timestamp as a date format as shown in the following image:

Was this page helpful? Yes No Submitting... Thank you

Comments