Order Scheduled Tasks
Background jobs for order lifecycle management, allocation, automation, and cleanup
The Order scheduled tasks manage the entire order lifecycle, from inventory allocation and payment settlement through to status automation and cleanup of old orders.
Available Tasks
| Task | Description | Type |
|---|---|---|
| Allocate Order to Purchase Order | Allocate unreserved order lines to incoming purchase orders | Delta |
| Cancel Expired Click and Collect | Cancel click and collect orders that exceed time limits | Delta |
| Cancel Expired Orders | Cancel orders that have exceeded their expiration threshold | Delta |
| Delete Old Orders | Permanently remove orders older than the configured retention period | Delta |
| Order Automation | Automatically transition order status based on configurable conditions | Delta |
| Payment Settlements | Retrieve and record payment settlement data from payment providers | Delta |
| Try Reallocate Orders | Process orders past their reallocation deadline | Delta |
| Try Reserve Order Lines | Reserve inventory for unreserved order lines using FIFO logic | Delta |
| Update Order Status | Process scheduled status transitions for orders | Delta |
| Update Overdue Orders | Mark orders as delayed when they pass their expected delivery date | Delta |
| Update Reservable Orders | Update the reservable status flag on orders | Delta |
Overview
Order tasks work together to manage the complete order lifecycle in Omnium:
- Inventory Allocation - Reserve stock for orders and allocate to purchase orders
- Payment Processing - Track payment settlements from external providers
- Status Automation - Automatically progress orders through workflow states
- Lifecycle Management - Handle expirations, cancellations, and cleanup
- Reallocation - Move inventory between orders when necessary
Common Use Cases
Inventory Reservation
Use Try Reserve Order Lines to ensure older orders are prioritized for available inventory using FIFO logic.
Purchase Order Allocation
Enable Allocate Order to Purchase Order to automatically assign unreserved order lines to incoming stock from suppliers.
Status Automation
Configure Order Automation to automatically progress orders based on conditions like payment status and inventory reservation.
Click and Collect Management
Use Cancel Expired Click and Collect to automatically handle orders not picked up within the allowed time window.
Data Retention
Configure Delete Old Orders with an appropriate retention period to comply with data retention policies.
Recommended Schedules
| Task Type | Recommended Schedule | Reason |
|---|---|---|
| Inventory tasks | */15 * * * * (every 15 minutes) | Keep allocations current |
| Payment tasks | */30 * * * * (every 30 minutes) | Sync settlement data |
| Automation tasks | */10 * * * * (every 10 minutes) | Responsive status updates |
| Cleanup tasks | 0 3 * * 0 (weekly at 3 AM Sunday) | Heavy operation, run off-peak |
| Expiration tasks | */30 * * * * (every 30 minutes) | Timely cancellation handling |
