org.axonframework.eventhandling.amqp
Interface AMQPMessageConverter

All Known Implementing Classes:
DefaultAMQPMessageConverter

public interface AMQPMessageConverter

Interface describing a mechanism that converts AMQP Messages from an Axon Messages and vice versa.

Since:
2.0
Author:
Allard Buijze

Method Summary
 AMQPMessage createAMQPMessage(EventMessage eventMessage)
          Creates an AMQPMessage from given eventMessage.
 EventMessage readAMQPMessage(byte[] messageBody, Map<String,Object> headers)
          Reconstruct an EventMessage from the given messageBody and headers.
 

Method Detail

createAMQPMessage

AMQPMessage createAMQPMessage(EventMessage eventMessage)
Creates an AMQPMessage from given eventMessage.

Parameters:
eventMessage - The EventMessage to create the AMQP Message from
Returns:
an AMQP Message containing the data and characteristics of the Message to send to the AMQP Message Broker.

readAMQPMessage

EventMessage readAMQPMessage(byte[] messageBody,
                             Map<String,Object> headers)
Reconstruct an EventMessage from the given messageBody and headers.

Parameters:
messageBody - The body of the AMQP Message
headers - The headers attached to the AMQP Message
Returns:
The Event Message to publish on the local clusters


Copyright © 2010-2016. All Rights Reserved.