Order Archive agent
- ENTITY_NAME is ORDER_HEADER, which is the entity name of Order entity.
- ARCHIVE_ON_DATE is less than the current date.
- LAST_FAILED_DATE is null or 30 days before the current date.
- ENTERPRISE_CODE matches the agent criteria.
- ARCHIVED_DATE is null.
- Configure the
osi.order.service.urlproperty to connect to Archive Service. - Configure the
osi.archive.enabledproperty to enable the integration with Archive Service. - Configure the history order retention days for each document type to define the retention period for history orders in Sterling Order Management System Software.
- Orders are purged and moved to history tables and a record is inserted in the
OSI_AWAITING_ARCHIVE table with the
EntityName=Order_Header, EntityKey=<value of OrderHeaderKey>andArchiveOnDate=<Calculated using Order Purge Date and Order History retention days and additional purge criteria >. For more information about the Order Purge agent, see Order purge.
- Archive orders
The Order Archive agent archives purged orders from Sterling Order Management System Software to the Archive Service by setting the criteria parameter Mode=Archive.
The system stamps an ArchivedDate on each archived order
- Delete Archived Orders
In a subsequent run, the Order Archive agent deletes previously archived orders by setting the criteria parameter Mode=Delete. Deletion occurs only after the configured delay period specified in the osi.archive.delayDeletion.days runtime property.
osi.archive.delayDeletion.days is set to 3. If the
agent runs in Mode=Delete on 14‑Jan‑2025 or later, then ORD1 becomes eligible for deletion,
according to following conditions:- ArchivedDate < (Current_Date – osi.archive.delayDeletion.days)
- Validation:
2025/01/10 < (2025/01/14 - 3)
2025/01/10 < 2025/01/11 ✓ Condition met
Attributes
| Attribute | Value |
|---|---|
| Base Transaction ID | OSI_ORDER_ARCHIVE |
| Base Document Type | GENERAL |
| Base Process Type | GENERAL |
| Abstract Transaction | None |
| APIs called | archiveOrder API This API is available in Archive Service, which is used for archiving an order and related entities to Archive Service. |
| User Exits called |
|
Criteria parameters
| Parameter | Description |
|---|---|
| Action | This parameter triggers the transaction. The default value is "Get". |
| Number of records to buffer | Optional. Indicates the number of records to retrieve and process at one time. If left blank or specified as 0 (zero), it defaults to 5000. |
| EnterpriseCode | Optional. Enterprise for which the Order Archive agent needs to be run. If not passed, all enterprises are monitored. |
| Colony Id | If the colony ID is passed without the enterprise code, the agent is triggered for all enterprises that are configured in that colony. |
| Collect Pending Jobs | This agent does not provide the pending jobs count for monitoring it in the System Management Console. Hence, this parameter is set to N and cannot be modified. |
| Mode | This parameter specifies how the Order Archive time‑triggered transaction deletes orders from
Sterling Order Management System Software, once these orders are archived to the Archive Service. Supported
values are blank, archive, and delete. The default mode value is blank Note:
Default mode and Archive/Delete modes are mutually inclusive and must not be used together. Either use Mode as blank to archive the order to the Archive Service and delete it from Sterling Order Management System Software immediately or use the two-step delayed deletion approach by running
Mode='Archive' to archive the purge order and then Mode='Delete' to delete the archived order from
Order Management System after the delay configured by
|
Statistics tracked
| Statistic Name | Description |
|---|---|
| NumberOfOrdersArchived | Number of history orders archived. |
| NumberOfOrderArchiveFailures | Number of failures occurred during archival. |
Pending job count
None.
Events raised
| Transaction/Event | Data Published | Template Support |
|---|---|---|
| ON_FAILURE | OSI_ORDER_ARCHIVE.ON_FAILURE.xml | Yes |
Tables archived
- YFS_ADDNL_LINE_PRICE_H
- YFS_ANSWER_SET_TRAN_H
- YFS_ANSWER_TRAN_H
- YFS_CHARGE_BREAKUP_H
- YFS_CHARGE_TRAN_DIST_H
- YFS_CHARGE_TRAN_REQUEST_H
- YFS_CHARGE_TRAN_RQ_MAP_H
- YFS_CHARGE_TRANSACTION_H
- YFS_CREDIT_CARD_TRANSACTION_H
- YFS_ENTITY_ADDRESS_H
- YFS_HEADER_CHARGES_H
- YFS_INSTRUCTION_DETAIL_H
- YFS_INVOICE_COLLECTION_H
- YFS_NOTES_H
- YFS_ORDER_APPROVAL_H
- YFS_ORDER_APPROVAL_DTL_H
- YFS_ORDER_AUDIT_H
- YFS_ORDER_AUDIT_DETAIL_H
- YFS_ORDER_AUDIT_LEVEL_H
- YFS_ORDER_DATE_H
- YFS_ORDER_HEADER_EXTENSION_H
- YFS_ORDER_HOLD_TYPE_H
- YFS_ORDER_HOLD_TYPE_LOG_H
- YFS_ORDER_INVOICE_H
- YFS_ORDER_INVOICE_DETAIL_H
- YFS_ORDER_LINE_RELATIONSHIP_H
- YFS_ORDER_LINE_REQ_TAG_H
- YFS_ORDER_OVERRIDE_H
- YFS_ORDER_PROD_SER_ASSOC_H
- YFS_ORDER_RELEASE_H
- YFS_ORDER_SEARCH_CONDITION_H
- YFS_ORDER_TAG_H
- YFS_PAYMENT_H
- YFS_PMNT_TRANS_ERROR_H
- YFS_PROM_AWARD_REF_MAP_H
- YFS_PROMOTION_H
- YFS_PROMOTION_AWARD_H
- YFS_PROMOTION_REFERENCE_H
- YFS_RECEIVING_DISCR_DTL_H
- YFS_RECEIVING_DISCREPANCY_H
- YFS_REFERENCE_TABLE_H
- YFS_STOP_DEL_REQ_DTL_H
- YFS_STOP_DEL_REQ_HDR_H
- YFS_TAX_BREAKUP_H
- YFS_TRANSACTIONAL_RELATION_H
- YFS_LINE_CHARGES_H
- YFS_ORDER_KIT_LINE_H
- YFS_ORDER_KIT_LINE_SCHEDULE_H
- YFS_ORDER_LINE_EXTENSION_H
- YFS_ORDER_LINE_H
- YFS_ORDER_LINE_OPTION_EXTN_H
- YFS_ORDER_LINE_OPTION_H
- YFS_ORDER_LINE_RELATIONSHIP_H
- YFS_ORDER_LINE_SCHEDULE_H
- YFS_ORDER_LINE_SRC_CNTRL_H
- YFS_ORDER_RELEASE_STATUS_H
- YFS_ORDER_SER_PROD_ITEM_H
- YFS_ORDER_HEADER_H
- YFS_ORDER_LINE_PRICE_MATCH_H
- YIC_BOM_LINE_H
- YIC_BOM_HEADER_H
- YIC_BOM_MESSAGE_H
- YIC_BOM_PROP_H
- PLT_FILE_ATTACHMENT_H
- PLT_FILE_DATA_H