Node-red-contrib-queue-gate is a node for controlling message flow, including message queueing capability. This update adds three new commands, suggested and implemented by @colin. The
status command refreshes the node status. This allows a flow to request the status of the gate at any time and trigger appropriate action with a
status node. In particular, the initial status of the gate at startup or the number of messages in the queue can be obtained,
Two other new actions are available only in the
queueing state. The
peek command sends the oldest message in the queue without removing it from the queue, and
drop deletes the oldest message from the queue without sending it. Together, the two commands may be used to obtain the oldest message, perform some action, and then remove the message from the queue only when it has been successfully serviced.
Also, it is no longer necessary for all control messages to be transmitted as strings. The values defining these messages are still set by the user in in the configuration dialog in the form of strings, but if the payload of a control messages is a number or boolean, the payload is converted to a string before being tested against the command definitions.
These changes are intended to be backward compatible with the previous version, so that users who do not want the new features will not need to upgrade. Please report bugs or issues here or on GitHub.