Class CoreMessagePersister
java.lang.Object
org.apache.activemq.artemis.core.message.impl.CoreMessagePersister
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondecode(ActiveMQBuffer buffer, Message record, CoreMessageObjectPools pool) voidencode(ActiveMQBuffer buffer, Message record) Sub classes must add the first short as the protocol-idintgetEncodeSize(Message record) bytegetID()This is to be used to store the protocol-id on Messages.static CoreMessagePersisterstatic voidregisterPersister(CoreMessagePersister newPersister) This is a hook for testingstatic void
-
Field Details
-
ID
public static final byte ID- See Also:
-
-
Constructor Details
-
CoreMessagePersister
protected CoreMessagePersister()
-
-
Method Details
-
registerPersister
This is a hook for testing -
resetPersister
public static void resetPersister() -
getInstance
-
getID
public byte getID()Description copied from interface:PersisterThis is to be used to store the protocol-id on Messages. Messages are stored on their bare format. The protocol manager will be responsible to code or decode messages. The caveat here is that the first short-sized bytes need to be this constant. -
getEncodeSize
- Specified by:
getEncodeSizein interfacePersister<Message>
-
encode
Sub classes must add the first short as the protocol-id -
decode
-