MQTT Store & Forward

Good morning,

Thank you to those who have answered my beginner questions so far, they have been quite helpful in building my confidence with the platform.

The current dilemma I am facing:

I am passing an analog value from ignition edge to the ignition gateway through MQTT. Store & Forward is enabled.

In the designer, on the gateway side, the tag populates under "MQTT Engine", and then I have created a reference tag monitoring the source tag path. The history is enabled on this reference tag, and it properly records history, until there is a connection interruption to the edge node, and the history does not populate when connection is re-established.

The question is, would the reference tag "see" all the values coming in batches, after connection is re-established, and log it to the configured historian? Or would I have to set-up history on the original tag that the MQTT system is publishing ?

The latter option. Ref tags don't receive backfill data to log into history which is a big issue! And mqtt tags disappear from the tag provider if a connection is down long enough... And when they come back, historic configuration on the tags is lost, so you'll need to setup a script to add the history config again. It's a big pita

Thanks for your reply!

So I should be able to set up tag history on the original MQTT tag, and disable it on the reference tag, and still be able to use the reference tag in components such as a power chart, and it will pull the history from the original tag?

Also, additionally, if I loose the tag history configuration and require a script to reconfigure on it's own, will tagid change in the DB ?

:grimacing:Nope, you'll need to use the path to the mqtt tag

I'm 99% sure the old tag will be retired and a new row will be created, so yes, tag id will change. But it's the tagpath that is used to join history together, not the tag id, so you will still see retired tags' history

I'm successfully using reference tags with MQTT data on store/forward, but the catch is that all data must be flushed in chronological order, and the history settings require minimum time between samples set to 0.

See this article for details (there's others as well in the menu to get more info): MQTT History Back-Fill with Reference Tags - MQTT Modules for Ignition 8.x - Confluence

Here's another one that explains more as well: MQTT History - MQTT Modules for Ignition 8.x - Confluence

Have you tried the setting on the gateway to allow backfill out of order?

This is good to know though, I speak with 2nd hand experience only

Yeah, I tried it, and it didn't work for me, even though it says on 8.1.4 and newer you can flush it out of order. I could be doing something wrong, but I still feel more work needs to be done in coordination between Ignition and CirrusLink on the module and reference tags. I feel like when setting the minimum time between samples is set to 0, of course it's going to record everything as it's flushed even though I really only want slower data for history compared to the live data, I couldn't find a way around it besides having MQTT transmision on the edge poll OPC tags directly using a slower rate since I also can't use reference tags with a slower rate referencing the OPC tags, since reference tags don't respect the polling rate of the tag group they're assigned to.