conneqt / m2-status-monitoring
Conneqt Status Monitoring Module for Magento 2
Package info
git.dev.epartment.nl/conneqt/m2-status-monitoring
Type:magento2-module
pkg:composer/conneqt/m2-status-monitoring
Requires
- conneqt/m2-base: >=1.0
- hyva-themes/module-magento2-admin: *
- magento/framework: >=101.0.0
This package is auto-updated.
Last update: 2026-06-24 11:14:18 UTC
README
Conneqt_StatusMonitoring helps Magento administrators keep track of orders that are stuck before or during ERP synchronisation.
The module has two main jobs:
- send email notifications for orders that have remained in selected statuses for too long;
- retry ERP pickup by refreshing the
updated_attimestamp of selected orders, either automatically or manually from the admin.
What the module does
This module is meant for shops that use Conneqt as part of their order/ERP integration flow.
It monitors orders that appear to be stalled and gives you two ways to react:
- Notification flow: periodically email a list of orders that are still in configured statuses after a configurable amount of time.
- Retry flow: update the order timestamp so external integrations that look at
sales_order.updated_atcan pick the order up again.
It also tracks how many times an order has been retried. When the configured maximum is reached, the module moves the order to a configurable failed status.
How it works
1. Email notification flow
The email notification cron looks for orders that:
- have one of the configured statuses;
- were updated before the configured "Updated Before" value;
- were updated after the configured "Updated After" value;
- were created after the configured "Created After" value.
When matching orders are found, the module sends an email containing the order increment IDs to the configured recipients.
Main files involved:
Cron/OrderStatus.php
Collects the orders, applies the date/status filters, and sends the email.etc/crontab.xml
Registers the scheduled jobconneqt_statusmonitoring_orderstatus. The schedule is read from config.view/frontend/email/conneqt_statusmonitoring_orderstatus.html
Email template used for the notification message.Helper/ScopeConfigHelper.php
Reads the notification-related configuration values and fallback defaults.
2. Automatic retry flow
The retry flow is intended for orders that should be picked up again by Conneqt/ERP processing.
Every minute, the retry cron checks whether the feature is enabled. If it is, the executor searches for orders in the configured statuses whose updated_at value is older than the configured retry interval.
For each matching order, the module:
- records or increments the retry counter in its own table;
- refreshes the order's
updated_attimestamp so downstream integrations can see it as changed again; - if the retry count has reached the configured maximum, changes the order to the configured failed status instead of retrying it again.
Main files involved:
Cron/UpdateOrderTimestamp.php
Small cron wrapper that checks the feature toggle and calls the executor.Executor/UpdateOrderTimestamp.php
Contains the main retry logic: selecting orders, counting attempts, updating timestamps, and setting the failed status when needed.Console/Command/UpdateOrderTimestamp.php
Adds the CLI commandconneqt:update:order:timestampso the retry logic can also be run manually.etc/crontab.xml
Schedules the retry job to run every minute.etc/db_schema.xml
Defines theconneqt_update_timestamp_attemptstable used to store retry counts per order.
3. Manual retry tools in the admin
Besides the cron-based retry process, the module adds admin actions that let a user manually retry orders by updating their updated_at value.
- On the Magento sales order grid, a mass action is added so multiple orders can be retried at once.
- A dedicated Hyvä Admin grid shows orders that are still pending for longer than one hour.
- Both the single-order and mass retry actions update the order timestamp directly in the
sales_ordertable.
Main files involved:
Controller/Adminhtml/Order/Retry.php
Retries a single order by refreshing its timestamp.Controller/Adminhtml/Order/MassRetry.php
Retries multiple selected orders.view/adminhtml/ui_component/sales_order_grid.xml
Adds the "Conneqt Retry Order" mass action to the default Magento sales order grid.view/adminhtml/hyva-grid/pending-grid.xml
Defines the Hyvä Admin grid and its retry actions.Grid/Processor/FilterPendingOrders.php
Applies the pending/stale order filters for the Hyvä grid source.Controller/Adminhtml/Grid/Index.php
Entry controller for the custom admin page.view/adminhtml/layout/conneqt_statusmonitoring_grid_index.xml
Renders the Hyvä grid page in the admin.etc/adminhtml/menu.xmlandetc/adminhtml/routes.xml
Register the admin menu item and route.
Configuration
The module configuration is available in the Magento admin under the Conneqt configuration section.
Main configuration groups:
- Settings
- enable/disable logging;
- Email Notification
- enable notifications;
- configure recipient email addresses;
- choose which order statuses to monitor;
- set the cron expression;
- set the date windows used for filtering orders;
- Update Order Timestamp
- enable automatic retries;
- choose retryable statuses;
- choose the failed status;
- set the retry interval in minutes;
- set the maximum number of retries.
Important config files:
etc/adminhtml/system.xml
Defines the admin configuration fields.etc/config.xml
Provides the default values.Helper/ScopeConfigHelper.php
Central place where those values are read in PHP.
Important files at a glance
| File | Purpose |
|---|---|
etc/module.xml | Registers the module and its dependency order (Conneqt_Base, Hyva_Admin). |
registration.php | Magento module registration entry point. |
Cron/OrderStatus.php | Notification cron logic for stale orders. |
Cron/UpdateOrderTimestamp.php | Cron entry point for the retry flow. |
Executor/UpdateOrderTimestamp.php | Main retry/fail workflow implementation. |
Console/Command/UpdateOrderTimestamp.php | CLI command to trigger retries manually. |
Helper/ScopeConfigHelper.php | Reads module configuration and fallback defaults. |
Helper/LogHandler.php | Writes module logs to Magento logging and optional console output. |
Controller/Adminhtml/Order/Retry.php | Single-order manual retry action. |
Controller/Adminhtml/Order/MassRetry.php | Bulk manual retry action. |
view/adminhtml/ui_component/sales_order_grid.xml | Adds a retry mass action to the Magento sales order grid. |
view/adminhtml/hyva-grid/pending-grid.xml | Defines the custom Hyvä admin grid for pending orders. |
Grid/Processor/FilterPendingOrders.php | Restricts the Hyvä grid to old pending orders. |
etc/db_schema.xml | Creates the retry-attempt tracking table. |
Setup/Patch/Data/AddSapOrderStatuses.php | Creates the custom Conneqt order statuses used by the module. |
view/frontend/email/conneqt_statusmonitoring_orderstatus.html | Email template for stale-order notifications. |
Custom statuses and retry tracking
During setup, the module creates the following order statuses:
conneqt_readyconneqt_acceptedconneqt_failed
These are created in Setup/Patch/Data/AddSapOrderStatuses.php.
Retry attempt counts are stored in the conneqt_update_timestamp_attempts table, defined in etc/db_schema.xml.
Requirements
From this package's metadata:
- Magento 2 framework
conneqt/m2-basehyva-themes/module-magento2-admin
See composer.json for the exact package constraints.