The sync request business object (BO) contains the rules that govern the processing of a sync request. The algorithms in this BO control what data elements are synchronized to an external system; how this data is to be communicated to the external system; and how the communication of this information is controlled chronologically to ensure that changes are processed in the right order. The base product provides the BO F1-SyncRequest, which contains the following life cycle.
-
Pending. The initial state of the sync request BO. At this point, a pre-processing algorithm would have already taken a snapshot of what the relevant information looked like prior to the change. A deferred monitor algorithm is specified on this state so as to accumulate all changes prior to sending the sync request to the external system. Furthermore, in order to prevent the sync request from transitioning to the next state while another sync request may not have completed its processing yet, the base package provides the monitor algorithm F1-WAITRELSR that skips transitioning if it detects another instance of the same BO in a non-final state for the same MO and primary key combination.
-
Determine If Sync Needed. This transitory state will contain the algorithm that takes the final snapshot of the relevant information so that it may be compared against the initial snapshot to see if the change affected any of the relevant data elements. The base product provides the algorithm F1-COMPSNAPS for this purpose. Your implementation may also add your own rules here to discard the sync request if certain criteria are met.
-
Discarded. If the comparison of the initial and final snapshots yields no changes, or if it fails any other checks your implementation has introduced, the sync request is transitioned to this state. If any processes are dependent on the sync request transitioning to a final state, your implementation may plug in an enter algorithm on this state to kick off the dependent process.
-
Send Request. This transitory state is used to hold the algorithm that facilitates the sending of the sync request to the external system. The algorithm used here may write a message to a JMS Queue or write a record to the general process MO or perform any other task that is suited to how your implementation communicates the change.
-
Awaiting Acknowledgement. This state can be used to hold the sync request from further state transitions until an acknowledgement is received from the external system. We strongly recommend designing some form of acknowledgement that the external system has processed the information as this helps control the chronological flow of information. The base package provides the business service F1-UpdateSyncRequest that transitions the sync request to either the next default state (in this case the Synchronized state) if a positive acknowledgement is received; or the state associated with the Rejection transition condition (in this case the Error state) if a negative acknowledgement is received.
-
Synchronized. Once the information has been processed and acknowledged by the external system, the sync request is transitioned to this state. If any processes are dependent on the sync request processing successfully, your implementation may want to plug in an enter algorithm on this state to kick off the dependent process.
-
Error. If a negative acknowledgement is received or if the acknowledgement is not received within the prescribed period of time, the sync request is transitioned to this state. Your implementation may wish to create a to do entry when the sync request transitions to this state. The base product provides the enter algorithm F1-TDCREATE for this purpose. The exit algorithm F1-TODOCOMPL has also been provided to complete any to do entries when leaving this state.
-
Canceled. A user may transition the sync request to this state from either the Awaiting Acknowledgement state or the Error state if he wishes to discontinue processing of the sync request for any reason. Your implementation will have to configure your own cancel reasons to document the transition. If any processes need to be triggered when the sync request reaches this state, your implementation can plug in an enter algorithm containing such logic.
Copyright © 2007, 2016, Oracle and/or its affiliates. All rights reserved. Documentation build: 2.5.2016 10:21:45 [T1_1454696505000]