Some items saved through Storage API aren't actually being stored

Hi all, bit of an odd one but i’m out of ideas and thought i’d reach out here to see if anyone might’ve experienced this, or has some suggestions on how I could do some further debugging to get to the root of the issue.

For a year and a half, we’ve had a app acting as a calendar within our confluence cloud instance that i developed and it’s been working quite well. I use the storage-api to store the calendar events. Sometimes, however, we’ve experienced a weird issue where a given event won’t be saved. It hasn’t been a major issue until this week where it’s become more common and i’ve personally experienced it for the first time. It’s quite strange, because the event I create did persist through a few refreshes and thus did ‘save’ but when I returned later the event had disappeared and wasn’t anywhere in the apps storage.

This is my first time developing an app of this kind, so while i’m almost certain i’ve done something wrong to cause this issue, as far as I can tell my events are being saved correctly through the invoke call so i’m unsure as to how to further narrow down the issue. Has anyone experienced something like this before? Or rather, does anyone have any tips on how I might further debug this? Happy to provide further information as needed as to the inner workings of the app.

Thank you very much!

Not 100% sure if it’s the same issue you’re experiencing but I’ve had something similar happen in the past where I was doing multiple read/write calls to the storage API at the same time and some values were being overwritten because according to the docs: “Forge resolves write conflicts using a last-write-wins strategy”.