How long do I have to get data from Particle Cloud?

Hello—I know that there isn’t true, long-term persistence or storage in the Particle Cloud. And I see in the docs (https://docs.particle.io/reference/webhooks/#sequence-of-events) that History and Logs will show 30 days of webhook attempts/failures and 10 requests/errors in the Console.

What I can’t quite figure out is how long I have to correct a problem if one surfaces (on my server, for example) that results in webhook errors. The case I’m imagining is this: my E-Series/Electron-powered devices (which store data locally for some time) get a cell connection and publish relatively big chunks of data (KB to 10s of KB) in consecutive messages which in turn trigger a webhook but the webhook returns an error.

So far I’ve been having great success with webhooks and I hope my luck doesn’t change. But if my server goes down or I get an error for any reason, I’d like to know if I can do an HTTP GET or come up with some other sort of error handling mechanism to retrieve data sent to the cloud that didn’t make it to the server for any reason.

Is there any recommended way to do this? How long do I have to rescrape the Particle Cloud before published data are gone forever? Thanks!

Currently, events aren’t stored in the cloud. If you don’t pick them up as they’re sent out, you’ll lose them.

1 Like

Thanks for the quick reply, @Moors7. I’ve seen that answer, in one form or another, over the past few months but was hopeful that because I can see a certain amount of persistence in the Console I might be able to recover something.

And any error handling would have to take place between the server and the device firmware, I suppose, and not rely on the Particle Cloud to help much other than pass messages back and forth.

Okay, guess what I’d already sort of known is now confirmed—thank you.

The "persistence" you mention above isn't really comparable to what you want to see persisted.
What the console keeps available for you are its own logs for troubleshooting what's wrong with the webhook, but you want device data persisted which is not in the scope of the console/webhook logging mechanism.

If you don't want to lose your data, you may need to wait for a webhook reply back to your device to indicate success before you discard the locally buffered data.

2 Likes

Thanks, @ScruffR . That’s what I was afraid of but it’s nonetheless good to have confirmed so that I can deal with this properly on the device itself. Appreciate it!

1 Like