AMQP Publisher
This adapter publishes messages to an AMQP topic.
Properties
| Defines the operation executed by the adapter Possible values:
|
Parameters
| Main adapter class (do not change!) Possible values: de.softproject.integration.adapter.amqp.AmqpPublisherAdapter: Main class (default) |
| Identifier of the configuration provided in Possible values: Any string containing the configuration identifier, e.g. This parameter is mandatory if you use the |
| AMQP server host Possible values: Server host, e.g. This parameter is mandatory if you do not use the |
| Dedicated AMQP port in the server Possible values: AMQP port number, e.g. This parameter is mandatory if you do not use the |
| Name of the user publishing the messages Possible values: Any string containing the user name, e.g. |
| Password associated to the user Possible values: Any string containing the corresponding password, e.g. |
| Queue where the message will be published Possible values: Any string containing the queue name, e.g. This parameter is mandatory if you do not use the |
| Container where the queue is placed Possible values: Any string containing the container name, e.g. |
| Quality of Service of the message Possible values:
The default value is |
| Enable SSL encryption Possible values:
|
| Activate SASL Authentication Possible values:
|
| SASL mechanism of the remote endpoint. Mögliche Werte:
|
| Set the message as durable Possible values:
|
| Priority level of the message Possible values: Any number between |
| Period of time in milliseconds when the message is considered alive Possible values: Any integer indicating the period of time in milliseconds, e.g. |
Status values
1 | The operation was executed successfully. |
| The operation was executed successfully (no output is generated). |
| An error occurred during the operation's execution (no output is generated). |
Configuration
To provide the needed information, a configuration file with a specified structure can be used, which is loaded at server startup. The configuration file amqpconfig.xml
must be stored under the server path X4DB/0
.
The file has the following structure:
<?xml version='1.0' encoding='UTF-8'?>
<RootElement>
<AMQPConfig name="queueEmployeesConfig">
<Server host="localhost" port="5672" useSsl="false"/>
<Client user="user" password="p4ssw0rd"/>
<Queue container="employeesContainer" name="employees" qos="AT_LEAST_ONCE"/>
</AMQPConfig>
</RootElement>
Input
The AMQP Publisher expects the following input structure, whereby only one element for each message is allowed:
Simple types:
<Messages>
<Message>
<Element type="String" value="Good morning!!"/>
</Message>
<Message>
<Element type="Int" value="18"/>
</Message>
</Messages>
The following simple types are allowed: Binary
, Boolean
, Byte
, Char
, Decimal32
, Decimal64
, Decimal128
, Double
, Float
, Long
, Short
, String
, Symbol
, Timestamp
(following the pattern yyyy-[m]m-[d]d hh:mm:ss
), UByte
, UInt
, ULong
, UShort
, Uuid
.
Complex types:
List:
XML<Messages> <Message> <Element type="List"> <Element type="Int" value="1"/> <Element type="Short" value="3"/> <Element type="Boolean" value="false"/> </Element> </Message> </Messages>
Map:
XML<Messages> <Message> <Element type="Map"> <Entries> <Entry> <Key type="Int" value="2"/> <Value type="String" value="Hello!!"/> </Entry> <Entry> <Key type="Int" value="5"/> <Value type="String" value="Goodbye!!"/> </Entry> </Entries> </Element> </Message> </Messages>