Class MessageSerializer
java.lang.Object
org.apache.pekko.persistence.serialization.MessageSerializer
- All Implemented Interfaces:
BaseSerializer,Serializer
Protobuf serializer for
pekko.persistence.PersistentRepr, pekko.persistence.AtLeastOnceDelivery and pekko.persistence.fsm.PersistentFSM.StateChangeEvent messages.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionatLeastOnceDeliverySnapshot(MessageFormats.AtLeastOnceDeliverySnapshot atLeastOnceDeliverySnapshot) fromBinary(byte[] bytes, scala.Option<Class<?>> manifest) Deserializes persistent messages.intGlobally unique serialization identifier configured in thereference.conf.booleanReturns whether this serializer needs a manifest in the fromBinary methodprotected voidGlobally unique serialization identifier configured in thereference.conf.persistentFSMSnapshot(MessageFormats.PersistentFSMSnapshot persistentFSMSnapshot) Class<org.apache.pekko.persistence.PersistentImpl>stateChange(MessageFormats.PersistentStateChangeEvent persistentStateChange) system()Actor system which is required by most serializer implementations.byte[]Serializes persistent messages.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.pekko.serialization.BaseSerializer
identifierFromConfig, SerializationIdentifiersMethods inherited from interface org.apache.pekko.serialization.Serializer
fromBinary, fromBinary
-
Constructor Details
-
MessageSerializer
-
-
Method Details
-
AtLeastOnceDeliverySnapshotClass
-
AtomicWriteClass
-
PersistentFSMSnapshotClass
-
PersistentImplClass
-
PersistentReprClass
-
PersistentStateChangeEventClass
-
atLeastOnceDeliverySnapshot
public AtLeastOnceDelivery.AtLeastOnceDeliverySnapshot atLeastOnceDeliverySnapshot(MessageFormats.AtLeastOnceDeliverySnapshot atLeastOnceDeliverySnapshot) -
atLeastOnceDeliverySnapshotBuilder
public MessageFormats.AtLeastOnceDeliverySnapshot.Builder atLeastOnceDeliverySnapshotBuilder(AtLeastOnceDelivery.AtLeastOnceDeliverySnapshot snap) -
fromBinary
Deserializes persistent messages. Delegates deserialization of a persistent message's payload to a matchingorg.apache.pekko.serialization.Serializer.- Specified by:
fromBinaryin interfaceSerializer
-
identifier
public int identifier()Description copied from interface:BaseSerializerGlobally unique serialization identifier configured in thereference.conf.See
pekko.serialization.Serializer.identifier.- Specified by:
identifierin interfaceBaseSerializer- Specified by:
identifierin interfaceSerializer
-
includeManifest
public boolean includeManifest()Description copied from interface:SerializerReturns whether this serializer needs a manifest in the fromBinary method- Specified by:
includeManifestin interfaceSerializer
-
org$apache$pekko$serialization$BaseSerializer$_setter_$identifier_$eq
protected void org$apache$pekko$serialization$BaseSerializer$_setter_$identifier_$eq(int x$1) Description copied from interface:BaseSerializerGlobally unique serialization identifier configured in thereference.conf.See
pekko.serialization.Serializer.identifier.- Specified by:
org$apache$pekko$serialization$BaseSerializer$_setter_$identifier_$eqin interfaceBaseSerializer
-
persistentFSMSnapshot
public PersistentFSM.PersistentFSMSnapshot<Object> persistentFSMSnapshot(MessageFormats.PersistentFSMSnapshot persistentFSMSnapshot) -
stateChange
public PersistentFSM.StateChangeEvent stateChange(MessageFormats.PersistentStateChangeEvent persistentStateChange) -
system
Description copied from interface:BaseSerializerActor system which is required by most serializer implementations.- Specified by:
systemin interfaceBaseSerializer
-
toBinary
Serializes persistent messages. Delegates serialization of a persistent message's payload to a matchingorg.apache.pekko.serialization.Serializer.- Specified by:
toBinaryin interfaceSerializer
-