A newer version of this documentation is available: View the Latest Version

Setup

Order export activation

After installation, you can enable Order Export in the Magento backend under Pacemaker  Order Workflow Configuration  Order Export Settings  Enable Order Export.

order export activation
Based on the described configuration values, it detects what orders are to be exported and uses the configured settings
to process the orders and perform the export

Magento-Consumer/Pipeline-Runner

Ensure that the Pacemaker Process Pipelines are up and running.

At a minimum, one Magento consumer must get started that processes the pipelines

Magento consumers get triggered with the following CLI command:
bin/magento queue:consumers:start pipeline.runner.ampq
When using MySQL-MQ, the runner provided as well gets started:
bin/magento queue:consumers:start pipeline.runner.db
  • For processing messages (--max-messages=1) in productive environments, the use of a Supervisor is recommended to control the consumer processes better

  • The module Supervisor Consumer is available as an alternative, which controls the consumers with a cron daemon

Heartbeat

Make sure that the Pacemaker Process Pipelines are running.

To be able to execute pipelines, the heartbeat must get executed:
bin/magento pipeline:heartbeat
  • The heartbeat is a cron job that gets executed every minute

  • On productive systems, a heartbeat can get configured with the crontab

Export

After the execution of a heartbeat, the export gets triggered.

The following changes are now visible:
  1. In the Magento backend pipeline overview, you can see Pacemaker Order Export pipelines get processed.

    export 1
    The pipeline overview takes place under Pacemaker  Process Pipelines
  2. The processed orders can get viewed in the steps of the pipelines.

    export 2
    The pipeline step detail view with the order ID 89. The export ID is 000000010.
  3. By default, only JSON export files get created.

    export 3
    Default export directory and default json export format view
  4. The database table pacemaker_order_export contains the processed orders with status.

    export 4
    Sample from the db table pacemaker_order_export
  5. The export status can get viewed in the admin backend of the order detail view.

    export 5
    Detail view of the order with entity ID 89
  6. If the line item configuration is activated, this information gets found in the pacemaker_order_line_item table.

    export 6
    Sample from the "pacemaker_order_line_item" table
  7. As a default, a file with the following name and content can now get created in the directory var/pacemaker/import.

    • We understand this as the response of an OMS/ERP.

    • Name: order-update-0000010.json

    • Content: {"order_id": "000000010", "external_id": "1543"}

  8. When a Pacemaker heartbeat gets started, the response in the handle response step of the pipeline is also processed. The information of the external ID gets stored in the DB.

    export 8
    Sample from the table sample from the table pacemaker_order_export with the ID filter 89 with the ID filter 89