phoenix_pubsub_eventstore v1.1.1 Phoenix.PubSub.EventStore.Serializer.Base64 View Source
Default serializer of PubSub message data
To keep published data intact and consistent (we could not differentiate between strings and atoms when converted to a JSON) we need to serialize messages before publishing them into the EventStore. Messages are deserialized before distributed to local subscribers.
Any module that implements serialize/1
and deserialize/1
can be used
as a serializer as long as EventStore works with it.
Link to this section Summary
Link to this section Types
Link to this type
t()
View Sourcet() :: %Phoenix.PubSub.EventStore.Serializer.Base64{payload: String.t()}
Link to this section Functions
Deserialize EventStore messages
Extracts and deserializes the base64 encoded binary
Serialize EventStore messages
Serializes the message as a base64 encoded binary and wraps
it in a %Phoenix.PubSub.EventStore.Serializer.Base64{}
struct.