Expand description
§Serialization
Restate sends data over the network for storing state, journaling actions, awakeables, etc.
Therefore, the types of the values that are stored, need to either:
- be a primitive type
- use a wrapper type
Json
for usingserde-json
. To enable JSON schema generation, you’ll need to enable theschemars
feature. See PayloadMetadata for more details. - have the
Serialize
andDeserialize
trait implemented. If you need to use a type for the handler input/output, you’ll also need to implement PayloadMetadata to reply with correct content type and enable JSON schema generation.
Structs§
- Input
Metadata - This struct encapsulates input payload metadata used by discovery.
- Json
- Wrapper type to use
serde_json
with Restate’sSerialize
/Deserialize
traits. - Output
Metadata - This struct encapsulates output payload metadata used by discovery.
Traits§
- Deserialize
- Deserialize trait for Restate services.
- Payload
Metadata - Payload metadata and Json Schemas
- Serialize
- Serialize trait for Restate services.