I have the edge compute agent running a workflow and device states are being posted, but the live graphs on dashboard seem to have a 30 min delay in showing up!
Not sure why and what’s going on.
Hi Lars,
It looks as though you you might not be updating your device state as frequently for some of your values. The Time Series Graph, when updating live, will only update when a new state comes through for the value. I would recommend checking your edge device to see when it is reporting state for these specific attributes, and looking around in the Data Explorer for more information on when the attribute is reported.
Let me know if this helps!
Julia
It’s set to a timer of 10 seconds, and I can see data come in if I look at the Application Log for this application. The data explorer is showing the same delay.
I looked at the time stamp that just came in and it was 1550170457000, which is about 30 min ago.
Is the agent time stamping wrong?
it looks like my edge agent device (Pi) rebooted around 11 am. I’m sure that had something to do with it. But why would it post data now that has an old timestamp on it?
Lars,
In the Device State Node, you have the option to override the timestamp.
Is it possible you’re setting the time via payload path? Also, could you verify that’s correct?
It is set to “Use the time of the current payload”
What about the actual time on the Pi?
Its showing correct time. 20:17 GMT.
Could the docker container have wrong time?
Maybe I should just deploy a small change to the Pi and see what happens?
I just checked the docker containers time and that is correct as well
Hi Lars,
When an edge device goes down and disconnects from the platform, the device will store the data until it can report to Losant. What you were seeing is the queuing of offline messages, which defaults as true. When your device went down, it began sending the offline messages when it came back on. The Docker/Losant edge documentation can be found here.
Thanks!
Julia
ok, but I’m missing data between 3.24pm 3.52pm
Something to note, I wouldn’t use “Use Current Time” and not disable replay of stored data when a link is resumed. That old data isn’t current and is then interleaved with current data. Which can really play havoc with workflows for instance .
And in fact you may also wish to put a guard in workflows to check that the payload timestamp is current, otherwise you could be triggering events for notifications on really old data. People getting the SMS 6 hours late on something that has cleared does confuse people.
Old data being streamed in does also play havoc with realtime gauges.
Tim,
How do I disable replay of old data?
Time stamp guard sounds wise.
@Lars_Andersson, there is an environment variable called QUEUE_OFFLINE_MESSAGES
or in your config file, you can set gateway.queueOfflineMessages
. Setting this to false
will disable the offline message queuing.
You can check out all the config options here:
https://cloud.docker.com/u/losant/repository/docker/losant/edge-agent#all-available-options
@anaptfox that link you provided doesn’t resolve to anything (at least for me).
It would be good if that option could be added to the documentation on https://docs.losant.com/edge-compute/edge-agent-usage/#agent-configuration-options as well as any other new ones
Thanks
Tim
Good point @Tim_Hoffman! I’m going to update this today.