Flush Queue not reset to zero after this webhook was received by subscriber

This one has me stumped - an ideas why this happened?
IsRunning_FlushQueue was not reset to 0 when the following was received by the Subscriber:
{“code”:“woocommerce_rest_shop_order_invalid_id”,“message”:“Invalid ID.”,“data”:{“status”:404}}

The Subscriber returned a no error message:
{“messages”:[{“code”:0,“message”:" No error"}]}

but because the flush queue remained at 1 nothing else was processed for days!

I’ve searched around for why this might have happened to no avail so all help gratefully received :slight_smile:
Very best
John

Hello,

One possible answer is that the PSOS thread processing the SimpleQ queue crashed before it finished and was able to reset the field to zero. I thought we has some mitigations for that in place, but I am not sure.

The PSOS thread could have just got hung up also, and never committed the record.

Or the server crashed

SimpleQ is pretty good at maintaining it’s queue state as long as the system doesn’t crash or hang in someway.

Does that help?

Todd

Hello Todd
Thanks for taking the time to respond :slight_smile:
SimpleQ is running on your Ottomatic server so maybe not a crash or hang.
Is there a way I can check? I’m keen to avoid this happening in the future.
Thanks again
Very best
John

In case it helps, I’ve attached a screenshot of the script event log for the time it stopped working correctly. You’ll see the 20min delay in flush queue works but nothing happens ie it doesn’t seem to process the queue.

Also, once I discovered the problem, I got everything going again by manually setting the field: IsRunning_FlushQueue to 0

Hello

A PSOS script can hang on any server running on any platform even ours. But thank you for thinking so highly of us :slight_smile:

The script is doing something every 20 minutes. You get error 3 and a error 400. Are you sure that script is hanging in an endless loop?

Todd

Hi, and why would I think otherwise :sunglasses:

Those 2 error happen all the time like those generated by SimpleQ : flush queue itself.
I think the 20 min delay is built in to the flush queue script so keeps happening because the field IsRunning_FlushQueue never gets reset to 0 - do I have that right?

In the meantime I’ll keep investigating :slight_smile:

Very best
John