Edge data behaviour in graph

edge
#1

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.

0 Likes

#2

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

0 Likes

#3

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.

0 Likes

#4

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?

0 Likes

#5

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?

0 Likes

#6

Lars,

In the Device State Node, you have the option to override the timestamp.

image

Is it possible you’re setting the time via payload path? Also, could you verify that’s correct?

0 Likes

#7

It is set to “Use the time of the current payload”

0 Likes

#8

What about the actual time on the Pi?

0 Likes

#9

Its showing correct time. 20:17 GMT.
Could the docker container have wrong time?

0 Likes

#10

Maybe I should just deploy a small change to the Pi and see what happens?

0 Likes

#11

I just checked the docker containers time and that is correct as well

0 Likes

#12

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

0 Likes

#13

ok, but I’m missing data between 3.24pm 3.52pm

0 Likes

#14

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.

0 Likes

#15

Tim,
How do I disable replay of old data?
Time stamp guard sounds wise.

0 Likes

#16

@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

0 Likes

#17

@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 :wink:

Thanks

Tim

0 Likes

#18

Good point @Tim_Hoffman! I’m going to update this today.

0 Likes