shuttle icon indicating copy to clipboard operation
shuttle copied to clipboard

Object persistence from annotations

Open brokad opened this issue 2 years ago • 1 comments

Currently the only form of persistence across runs of a service is an (optional) database accessible via Factory.

Maybe we could allow users to "persist" a serializable/deserializable object across runs with a simple derive annotation

#[derive(Serialize, Deserialize, Persist)]
struct MyPersistingState {
  view_counter: usize
}

brokad avatar Mar 19 '22 09:03 brokad

I'll give this a go!

Butch78 avatar Jun 28 '22 11:06 Butch78

This was added with the new persist resource in v0.6.0

chesedo avatar Oct 31 '22 10:10 chesedo