How To Set Up Milestone Templates and Monitors

An automation agent listens to and filters events, and then performs agent actions based on those events.

A milestone template monitors the execution and event management of your supply chain. It defines the expected and unexpected milestones during entire business object life cycles and how the milestones should unfold. A milestone template is a list of anticipated events for a business object. It is a template; an outline of what is expected to occur. It does not attach to a business object and does not monitor the business object.

A milestone monitor is a copy of a milestone template that attaches to a business object and then monitors it.

For example, a milestone template may be defined to monitor new shipments. When a new shipment is created, the system creates a copy of that milestone template and attaches the copy to the new shipment. The copy is called a milestone monitor. The milestone monitor is what monitors the new shipment.

One milestone template can assign milestone monitors to several shipments. A milestone template can be used again and again. Criteria can also be defined to limit the shipments to which a milestone template is assigned.

Setting Up Milestone Templates and Monitors

  1. Create a Milestone Template.
    1. On the template, enter the Assignment Criteria. The assignment criteria determines when a milestone template copies itself and attaches to a business object and thus begins monitoring the business object.

    2. Also create the template Milestones. These outline what you want to monitor on the business object. It defines what is expected to occur and not expected to occur.

      1. You can optionally record agent actions that perform specific tasks when the milestone occurs.
      2. You can introduce some tolerance for the arrival and departure times of a milestone. For example, you can allow a shipment to arrive an hour earlier than planned and two hours later than planned.
      3. A milestone can be configured to model scenarios that are time-sensitive.
      4. Milestone links are predecessor/successor relationships between milestones. Milestone links are optional and there can be one or more links between two milestones.
      5. To limit the replication of milestone parameters to stops and order lines that meet specific criteria, use a From-Where Clause, and then enter appropriate SQL statements defining the criteria.
  2. Both the assignment criteria and the milestones on a milestone template are defined with an event. When this event takes place, the assignment criteria or the milestone occurs. The milestone is automatically assigned when the assignment criteria is fulfilled.
  3. Alternatively, you can use the Assign Milestone Monitor action to attach a milestone template to a business object. When you manually assign a milestone template to a business object, the assignment criteria for the template is ignored.
  4. When a milestone template is tied to the business object, a copy of the milestone template is created and attached. The attached template is called a milestone monitor The template remains unchanged. All milestone transactions will occur in the milestone monitor and not affect the milestone template.

Scenario: Using Timer-Based Milestones

You send a tender to the service provider. The sending of the tender assigns a milestone monitor to the shipment. This milestone monitor has one timer-based milestone that is initialized based on the tender response time of 30 minutes. If the tender response comes in before the timer expires, the timer milestone is deactivated and milestone monitor marked as complete. If the timer expires, two notifications are sent out. The first warns the service provider that they need to respond in 30 minutes and the second warns the user that the service provider has not responded yet.

  1. Create a Milestone Template.
  2. Select the Data Query Type of "Shipment".
  3. Select the Deactivate On Completion check box.
  4. Add Assignment Criteria with the following specifications. Suggested assignment criteria name: "On Tender".
    1. Event: "SHIPMENT - STATUS CHANGED"
    2. Restrictions - Source: Select "INTEGRATION", "INTERNAL", and "USER"
    3. Restrictions - Status Value: "SECURE RESOURCES", "SECURE RESOURCES_TENDERED", "Same As"
    4. Save Assignment Criteria.
  5. Add a milestone with the following specifications. Suggested name: "RESPONSE WATCHER".
    1. Select the Time Based Event check box.
    2. Select the Monitor Event check box.
    3. Select the Perform Action check box.
    4. Add agent actions:
      1. Action 1: "NOTIFY SERVICE PROVIDER"
      2. Action 1 Subject: "Response Time for Shipment $gid is expiring within 30 minutes."
      3. Action 2: "NOTIFY CONTACT"
      4. Action 2 Contact: Enter a contact.
      5. Action 2 Subject: "So far, no response on Shipment $gid. Tender time out in 30 minutes."
    5. Enter Time Details:
      1. Based On: Saved Query
    6. Saved Query: Create a saved query with the following details:
      1. Suggested User Query Name: "RESPONSETIME_MINUS_30"
      2. Objet Type ID: "Shipment"
      3. Check One SQL: select expected_response-numtodsinterval(30,'MINUTE') from tender_collaboration where shipment_gid = ?
      4. Find All SQL: select expected_response-numtodsinterval(30,'MINUTE') from tender_collaboration where shipment_gid = ?
    7. Save the milestone.
  6. Add a milestone with the following specifications. Suggested name: "RECEIVED RESPONSE".
    1. Select the Last Milestone Event check box.
    2. Select the Monitor Event check box.
    3. Select the Perform Action check box.
    4. Add an event:
      1. Event: "SHIPMENT - STATUS CHANGED"
      2. Restrictions - Source: Select "INTEGRATION", "INTERNAL", and "USER"
      3. Restrictions - Status Value: "SECURE RESOURCES", "SECURE RESOURCES_ACCEPTED", "Same As"
    5. Save the milestone.
  7. Save the milestone template.

Related Topics