Message Filters
The default behavior for modules in Crosser Flows is to process every message they receive. Sometimes this is not desirable, this is where message filters come into play. Message filters are added on the ‘Common’ tab (soon ‘General’), available in the settings dialog of all modules. You can add multiple filters and in this case a message must pass all criterias (AND).
The first use case is to block messages with invalid data, so that they don’t continue along the Flow and create issues in other modules. The output of each module contains a ‘crosser’ object that has a ‘success’ property that can be used in message filters to check that the data received from a previous module is generated by that module without issues. That doesn’t necessarily mean that the actual content of the message is without issues, but at least you know that the previous module operated without issues. This is especially useful with modules that make external requests to get data, like database queries, HTTP requests or pulling data from a PLC. If these modules report a failure it is very unlikely that the output will contain valid data, hence it makes sense to block these messages in the next module.
Another scenario is when you want to apply different processing based on message data. Connecting multiple modules to the output of one module and configuring them with different filters allows messages to be routed along different paths. This type of routing can also be achieved with the Split module, that offers the same kind of filter conditions, but with the advantage that it’s more visually apparent what is happening.