use of org.apache.activemq.artemis.api.core.client.ClientMessage in project activemq-artemis by apache.
the class ActiveMQDynamicProducerResource method sendMessage.
/**
* Create a new ClientMessage with the specified body and send to the specified address on the server
*
* @param targetAddress the target address
* @param body the body for the new message
* @return the message that was sent
*/
public ClientMessage sendMessage(SimpleString targetAddress, byte[] body) {
ClientMessage message = createMessage(body);
sendMessage(targetAddress, message);
return message;
}
use of org.apache.activemq.artemis.api.core.client.ClientMessage in project activemq-artemis by apache.
the class ActiveMQDynamicProducerResource method sendMessage.
/**
* Create a new ClientMessage with the specified body and and properties and send to the server
*
* @param targetAddress the target address
* @param properties the properties for the new message
* @return the message that was sent
*/
public ClientMessage sendMessage(SimpleString targetAddress, String body, Map<String, Object> properties) {
ClientMessage message = createMessage(body);
sendMessage(targetAddress, message);
return message;
}
use of org.apache.activemq.artemis.api.core.client.ClientMessage in project activemq-artemis by apache.
the class ActiveMQDynamicProducerResource method sendMessage.
/**
* Create a new ClientMessage with the specified body and and properties and send to the server
*
* @param targetAddress the target address
* @param properties the properties for the new message
* @return the message that was sent
*/
public ClientMessage sendMessage(SimpleString targetAddress, byte[] body, Map<String, Object> properties) {
ClientMessage message = createMessage(body);
sendMessage(targetAddress, message);
return message;
}
use of org.apache.activemq.artemis.api.core.client.ClientMessage in project activemq-artemis by apache.
the class EmbeddedActiveMQResource method sendMessageWithProperties.
/**
* Create a new message with the specified properties, and send the message to an queueName
*
* @param address the target queueName for the message
* @param properties message properties for the new message
* @return the message that was sent
*/
public ClientMessage sendMessageWithProperties(SimpleString address, Map<String, Object> properties) {
ClientMessage message = createMessageWithProperties(properties);
sendMessage(address, message);
return message;
}
use of org.apache.activemq.artemis.api.core.client.ClientMessage in project activemq-artemis by apache.
the class EmbeddedActiveMQResource method createMessageWithProperties.
/**
* Create a ClientMessage with the specified body and message properties
*
* If useDurableMessage is false, a non-durable message is created. Otherwise, a durable message is created
*
* @param body the body for the new message
* @param properties message properties for the new message
* @return a new ClientMessage with the specified body and message properties
*/
public ClientMessage createMessageWithProperties(byte[] body, Map<String, Object> properties) {
ClientMessage message = createMessage(body);
addMessageProperties(message, properties);
return message;
}
Aggregations