Use this file to discover all available pages before exploring further.
Restate sends data over the network for storing state, journaling actions, awakeables, etc.
Therefore, Restate needs to serialize and deserialize the journal entries.
It is possible to implement customized serialization using the Serde interface.For example, to implement custom serializers for the handler input and output:
const myService = restate.service({ name: "MyService", handlers: { myHandler: restate.handlers.handler( { // Set the input serde here input: restate.serde.binary, // Set the output serde here output: restate.serde.binary, }, async (ctx: Context, data: Uint8Array): Promise<Uint8Array> => { // Process the request return data; } ), },});
When sending a request to a handler configured with custom serde(s) you always need to manually specify them, because the client does not automatically infer what serde(s) should be used.
To customize the serde to use on requests: