Interface ICoreMessage
-
- All Superinterfaces:
Message
- All Known Subinterfaces:
ClientMessage
public interface ICoreMessage extends Message
This interface is only to determine the API of methods required for Core Messages
-
-
Field Summary
-
Fields inherited from interface org.apache.activemq.artemis.api.core.Message
BYTES_TYPE, DEFAULT_TYPE, EMBEDDED_TYPE, HDR_ACTUAL_EXPIRY_TIME, HDR_BRIDGE_DUPLICATE_ID, HDR_CONTENT_TYPE, HDR_DUPLICATE_DETECTION_ID, HDR_GROUP_ID, HDR_GROUP_SEQUENCE, HDR_INGRESS_TIMESTAMP, HDR_LARGE_BODY_SIZE, HDR_LARGE_COMPRESSED, HDR_LAST_VALUE_NAME, HDR_ORIG_MESSAGE_ID, HDR_ORIG_ROUTING_TYPE, HDR_ORIGINAL_ADDRESS, HDR_ORIGINAL_QUEUE, HDR_PREFIX, HDR_ROUTE_TO_ACK_IDS, HDR_ROUTE_TO_IDS, HDR_ROUTING_TYPE, HDR_SCALEDOWN_TO_IDS, HDR_SCHEDULED_DELIVERY_TIME, HDR_VALIDATED_USER, INTERNAL_PROPERTY_NAMES_PREDICATE, LARGE_EMBEDDED_TYPE, MAP_TYPE, memoryOffset, OBJECT_TYPE, STREAM_TYPE, TEXT_TYPE
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description ActiveMQBuffer
getBodyBuffer()
The buffer to write the body.int
getBodyBufferSize()
Returns the length in bytes of the body buffer.InputStream
getBodyInputStream()
io.netty.buffer.ByteBuf
getBuffer()
ActiveMQBuffer
getDataBuffer()
Returns a readOnlyBodyBuffer or a decompressed one if the message is compressed.int
getEndOfBodyPosition()
int
getHeadersAndPropertiesEncodeSize()
org.apache.activemq.artemis.core.message.LargeBodyReader
getLargeBodyReader()
ActiveMQBuffer
getReadOnlyBodyBuffer()
Returns a new Buffer slicing the current Body.byte
getType()
Return the type of the messagedefault boolean
isConfirmed()
boolean
isServerMessage()
We are really interested if this is a LargeServerMessage.void
moveHeadersAndProperties(Message msg)
Used on large messages treatment.void
receiveBuffer_1X(io.netty.buffer.ByteBuf buffer)
it will fix the body of incoming messages from 1.x and before versionsvoid
sendBuffer_1X(io.netty.buffer.ByteBuf sendBuffer)
Message
setBuffer(io.netty.buffer.ByteBuf buffer)
The buffer will belong to this message, until release is called.default void
setConfirmed(boolean confirmed)
org.apache.activemq.artemis.core.message.impl.CoreMessage
setType(byte type)
the type of the messagedefault Map<String,Object>
toMap(int valueSizeLimit)
-
Methods inherited from interface org.apache.activemq.artemis.api.core.Message
acceptsConsumer, clearInternalProperties, containsProperty, containsProperty, copy, copy, copy, durableDown, durableUp, getAddress, getAddressSimpleString, getAnnotation, getAnnotationString, getBooleanProperty, getBooleanProperty, getBrokerProperty, getByteProperty, getByteProperty, getBytesProperty, getBytesProperty, getConnectionID, getCorrelationID, getDoubleProperty, getDoubleProperty, getDuplicateIDBytes, getDuplicateProperty, getDurableCount, getEncodeSize, getExpiration, getExtraBytesProperty, getFloatProperty, getFloatProperty, getGroupID, getGroupSequence, getIngressTimestamp, getIntProperty, getIntProperty, getLastValueProperty, getLongProperty, getLongProperty, getMemoryEstimate, getMessageID, getObjectProperty, getObjectProperty, getObjectPropertyForFilter, getOwner, getPersistentSize, getPersister, getPersistSize, getPriority, getPropertyNames, getProtocolName, getRefCount, getReplyTo, getRoutingType, getScheduledDeliveryTime, getShortProperty, getShortProperty, getSimpleStringProperty, getSimpleStringProperty, getStringBody, getStringProperty, getStringProperty, getTimestamp, getUsage, getUserContext, getUserID, getValidatedUserID, getWholeMessageSize, hasScheduledDeliveryTime, isDurable, isExpired, isLargeMessage, isPaged, messageChanged, persist, putBooleanProperty, putBooleanProperty, putByteProperty, putByteProperty, putBytesProperty, putBytesProperty, putCharProperty, putCharProperty, putDoubleProperty, putDoubleProperty, putExtraBytesProperty, putFloatProperty, putFloatProperty, putIntProperty, putIntProperty, putLongProperty, putLongProperty, putObjectProperty, putObjectProperty, putShortProperty, putShortProperty, putStringProperty, putStringProperty, putStringProperty, receiveBuffer, reencode, refDown, referenceOriginalMessage, refUp, rejectConsumer, reloadPersistence, removeAnnotation, removeExtraBytesProperty, removeProperty, removeProperty, sendBuffer, setAddress, setAddress, setAnnotation, setBrokerProperty, setConnectionID, setCorrelationID, setDurable, setExpiration, setGroupID, setGroupID, setGroupSequence, setIngressTimestamp, setLastValueProperty, setMessageID, setOwner, setPaged, setPriority, setReplyTo, setRoutingType, setScheduledDeliveryTime, setTimestamp, setUserContext, setUserID, setValidatedUserID, toCompositeData, toCore, toCore, toMap, toPropertyMap, toPropertyMap, usageDown, usageUp
-
-
-
-
Method Detail
-
setBuffer
Message setBuffer(io.netty.buffer.ByteBuf buffer)
The buffer will belong to this message, until release is called.
-
getBuffer
io.netty.buffer.ByteBuf getBuffer()
-
getLargeBodyReader
org.apache.activemq.artemis.core.message.LargeBodyReader getLargeBodyReader() throws ActiveMQException
- Throws:
ActiveMQException
-
getHeadersAndPropertiesEncodeSize
int getHeadersAndPropertiesEncodeSize()
-
getBodyInputStream
InputStream getBodyInputStream()
- Specified by:
getBodyInputStream
in interfaceMessage
-
getReadOnlyBodyBuffer
ActiveMQBuffer getReadOnlyBodyBuffer()
Returns a new Buffer slicing the current Body.
-
getBodyBufferSize
int getBodyBufferSize()
Returns the length in bytes of the body buffer.
-
getDataBuffer
ActiveMQBuffer getDataBuffer()
Returns a readOnlyBodyBuffer or a decompressed one if the message is compressed. or the large message buffer.- Returns:
-
setType
org.apache.activemq.artemis.core.message.impl.CoreMessage setType(byte type)
the type of the message
-
isServerMessage
boolean isServerMessage()
We are really interested if this is a LargeServerMessage.- Returns:
-
getBodyBuffer
ActiveMQBuffer getBodyBuffer()
The buffer to write the body. Warning: If you just want to read the content of a message, use getDataBuffer() or getReadOnlyBuffer();- Specified by:
getBodyBuffer
in interfaceMessage
- Returns:
-
getEndOfBodyPosition
int getEndOfBodyPosition()
-
moveHeadersAndProperties
void moveHeadersAndProperties(Message msg)
Used on large messages treatment. this method is used to transfer properties from a temporary CoreMessage to a definitive one. This is used when before a Message was defined as a LargeMessages, its properties are then moved from the Temporary message to its final LargeMessage object. Be careful as this will not perform a copy of the Properties. For real copy, use the copy methods or copy constructors.
-
sendBuffer_1X
void sendBuffer_1X(io.netty.buffer.ByteBuf sendBuffer)
-
receiveBuffer_1X
void receiveBuffer_1X(io.netty.buffer.ByteBuf buffer)
it will fix the body of incoming messages from 1.x and before versions
-
isConfirmed
default boolean isConfirmed()
-
setConfirmed
default void setConfirmed(boolean confirmed)
-
-