Business Process Automation
How to Create an Automation Agent
An automation agent listens for an event, verifies a user-defined condition, and executes one or more actions that you select from an action library. An agent operates against a specific business object such as order base, order release, shipment, sell side shipment, and so on. It includes a list of events that can occur, optional conditions that are checked, actions that perform a process, and error controls to alert you when problems are encountered with the agent.
For example, you could create an agent that listens for order base modifications from a specific order owner. If modifications are detected (usually through integration although an agent can be configured for other sources) the agent can direct Oracle Transportation Management to:
- Fully propagate the order base change by unassigning its order release from an existing shipment and build a new shipment.
- Acknowledge the order modification and set the appropriate statuses.
- Send the order base in XML format to an interested party.
- Notify the planner via email, fax, or some other communication method.
Creating an Automation Agent
- Navigate to Business Process Automation > Agents and Milestones > Automation Agent.
- Complete the following (required) fields:
- Agent ID
- Agent Type
- Select the Active checkbox if you want the agent to be turned on when you are finished creating it.
- Select a domain for the agent from the Domain Name field.
- Add one or more events to the agent.
Note: If you have chosen multiple events, Oracle Transportation Management initiates action when any one of those events occurs.
- Select
(if it appears) next to any event to set one of the following parameters:
- Source: Use this parameter to identify the way in which an event takes place:
- User: If the event occurs as a result of a person using the Oracle Transportation Management user interface.
- Integration: If the event occurs as a result of an XML document that is imported into Oracle Transportation Management via integration.
- Internal: If the event is caused by standard Oracle Transportation Management workflow processing.
- Before Persist: Use this parameter when you want to use the Persist/Don't Persist actions.
- Status Type and Status Value: Use these parameters for status-related events.
- Source: Use this parameter to identify the way in which an event takes place:
- Use the Saved Condition field to optionally enter (or find) a condition or create a new one. (Before executing any actions for an event, an agent always checks the business object for a saved condition.)
- Select View/Enter Actions to define actions for the agent.
- Select Add Action.
- Select an action from the drop-down list, then complete any parameters that may appear for the action.
- Select Save. Each action appears on a separate line followed by the Insert
icon. Select this icon to insert additional actions and construct the action body to your requirements. - Select the edit (
) icon next to an action to display the parameters you defined and make any necessary changes. - Select the delete (
) icon to remove an action from the list.
- Select Next to define the error actions for the agent.
- Use the Error Handler section to construct a list of actions that will determine how the system reacts to an error condition during agent execution. Select add action and follow steps above under step 9.
Note: By default, the agent error handler is empty, which means that the system does nothing when an error occurs (aside from logging the error).
- Select Finished to save the agent.
Connecting Agents
Connect agents together (use one agent to trigger another agent) through the use of custom (agent) events.
Note that if you use agent events to create complex agents, this can possibly cause adverse effects on Oracle Transportation Management performance. Because all the agents connected by agent events should be turned on in order to work properly (in most cases), it may be preferable to use more detailed saved conditions within an agent to create the same result, instead of using agent events to connect two or more agents together.
Creating an Agent Event
- Create a new Agent Event with these specifications:
- If you want to link the user defined event to the Oracle Transportation Management notification system, enter a contact notification in the Contact Notification ID field.
- Select Finished to save the agent event.
Creating (or modifying) an Agent
- Navigate to Business Process Automation > Agents and Milestones > Automation Agent from the navigation frame.
- Enter an Agent ID and Agent Type.
- Select the Active checkbox if you want the agent to be turned on when you are finished creating it.
- Select a domain from the Domain Name drop-down list.
- Add one or more events to the Agent.
- Use the Saved Condition field to optionally enter (or find) a condition or create a new one. (Before executing any actions for an event, an agent always checks the business object for a saved condition.)
- Select Next to define actions for the agent.
- Select Add Action.
- Select RAISE EVENT from the Action drop-down list.
- Select the agent event you created from the Custom Event drop-down list.
- Select Save.
- Select Finished when you have added all your actions.
- Select Next to define the error actions for the agent.
- Use the Error Handler section to construct a list of actions that will define how the system reacts to an error condition during agent execution. Select Add action.
- Select Finished to save the agent.