Class: AmazonOrderStatusVerificationWorker
- Inherits:
-
Object
- Object
- AmazonOrderStatusVerificationWorker
- Includes:
- Sidekiq::Job
- Defined in:
- app/workers/amazon_order_status_verification_worker.rb
Overview
Scheduled daily at 6 PM Central to verify that recently-invoiced Amazon
orders have reached the expected "Shipped" status on Amazon Seller Central.
Iterates all Amazon Seller Central partners that have
order_status_verification_enabled: true in their orchestrator config
(currently US and CA).
Instance Method Summary collapse
-
#perform ⇒ Object
Runs the job.
Instance Method Details
#perform ⇒ Object
Runs the job.
20 21 22 23 24 25 26 27 28 29 30 |
# File 'app/workers/amazon_order_status_verification_worker.rb', line 20 def perform Edi::Amazon::Orchestrator.orchestrators.each do |orchestrator| next unless orchestrator.active && orchestrator.order_status_verification_enabled? Rails.logger.tagged("OrderStatusVerification", orchestrator.partner) do orchestrator.execute_order_status_verification end rescue StandardError => e ErrorReporting.error(e, "OrderStatusVerification failed for #{orchestrator.partner}") end end |