SK
Signal K11mo ago
Willem

Willem - Hello, quick question: is there a way ...

Hello, quick question: is there a way for a plugin to remove outdated data (that was added earlier by app.handleMessage())? In this case it concerns weather forecast data with a path like 'xxxx.forecast.2024-04-21.temperatureMin'. After April 21, this data should be purged. Thanks, Willem
4 Replies
Scott Bender
Scott Bender11mo ago
You can update the value to null, but there’s no way to delete the path completely.
Teppo Kurki
Teppo Kurki11mo ago
I think the solution here would delete by timeout If you structure your data differently: use path xxx.forecast and use a value that is an object that has all the data including the timestamp then newer updates will simply replace the previous one Having said that it seems there’s growing interest in having weather data - something we could or should address on the spec / api level
AdrianP
AdrianP11mo ago
+1 on the spec /api
Willem
WillemOP11mo ago
Thanks for the information, I'll look into restructuring the data at some point (or if memory use becomes an issue).

Did you find this page helpful?