Hi, one question / feature request, would it be possible to preserve original message when using openhab2-get node?
One typical scenario would be flow control, based on the control/override switches.
F.eks. presence is detected, complex rule is formatting appropriate action and message that needs to be sent to the openhab2-out node, but ONLY if a "ManualOverride" virtual switch in openhab is set to OFF.
Flow would look like this:
input_event -> complex_logic_that_constructs_final_message -> openhab2-get(controlItem) -> openhab2-out(desiredItem)
This works fine to a point, but the original message payload is overwritten by openhab2-get.
One workaround is to:
input -> logic -> store_message_globaly -> openhab2-get(controlItem) -> restore_global_message -> openhab2-out(desiredItem)
Another is to use openahb2-get earlier in the flow, before the complex logic, but that is impossible/unpractical when making subflows or links or some "general logic". Another example is notifications logic, where it is difficult to implement controlItem check beforehand, as input to a subflow can come from meny other flows.
Any thoughts about how this could be solved? Perhaps some sort of msg.origianal_payload output, or another out channel?
Hi, one question / feature request, would it be possible to preserve original message when using openhab2-get node? One typical scenario would be flow control, based on the control/override switches. F.eks. presence is detected, complex rule is formatting appropriate action and message that needs to be sent to the openhab2-out node, but ONLY if a "ManualOverride" virtual switch in openhab is set to OFF. Flow would look like this: input_event -> complex_logic_that_constructs_final_message -> openhab2-get(controlItem) -> openhab2-out(desiredItem)
This works fine to a point, but the original message payload is overwritten by openhab2-get. One workaround is to: input -> logic -> store_message_globaly -> openhab2-get(controlItem) -> restore_global_message -> openhab2-out(desiredItem)
Another is to use openahb2-get earlier in the flow, before the complex logic, but that is impossible/unpractical when making subflows or links or some "general logic". Another example is notifications logic, where it is difficult to implement controlItem check beforehand, as input to a subflow can come from meny other flows.
Any thoughts about how this could be solved? Perhaps some sort of msg.origianal_payload output, or another out channel?