Running long time means: eg image below


The job start running at 2.52pm, but by the time we check it at 5pm it is still RUNNING.. no DONE was stated, then can follow below steps:



1. Close Service HWMS_StockcardProcess


2. Run query below in hwms-api database

update `hwms-api`. jobs set attempts=0, reserved_at=NULL where attempts=1;

update `hwms-api`.process_consolidates set status='open' where status='locked';


3. Start Service HWMS_StockcardProcess




Check pending job queue:

SELECT count(*) FROM `hwms-api`.process_consolidates where status <> 'closed' and created_at between "2024-09-19 00:00:00" and "2024-09-19 23:59:59";