Using the RabbitMQ Destination Component
The RabbitMQ Destination Component is an SSIS data flow pipeline component that can be used to send messages to a RabbitMQ Server. There are three pages of configuration:
- Error Handling
- Connection Manager
The destination component requires a RabbitMQ connection manager. The Connection Manager drop-down will show a list of all the RabbitMQ connection managers that have been created in the current SSIS package.
- Exchange Name
The name of the exchange to send messages to.
- Routing Key
The routing key of sent messages.
- Delivery Mode
The delivery mode can be set to Persistent or Non-Persistent. Persistent messages are stored on disk on the server, and will persist after a server restart. Non-persistent messages are only stored in memory.
The priority of sent messages. The possible range is 0 to 255.
The encoding that will be used to convert the message body to a byte array when sending the message.
The Columns page allows you to map the columns from upstream components to destination attributes.
In the Columns page, you will see a grid as shown below.
- Input Column - You can select an input column from an upstream component here.
- Destination Field - The attribute/field that you want to write data to.
- Data Type - This column indicates the type of value for the current attribute.
- Unmap - This button provides a convenient way to unset the mapping for the selected attribute/field.
- Add Button
- Clicking the Add button will bring up a dialog that will allow columns to be added that correspond to custom headers on outgoing messages.
Error Handling page
The Error Handling page allows you to specify how errors should be handled when they happen.
There are three options available.
- Fail on error
- Redirect rows to error output
- Ignore error
When the Redirect rows to error output option is selected, rows that failed to write to RabbitMQ will be redirected to the 'Error Output' of the Destination Component. As indicated in the screenshot below, the green output connection represent rows that were successfully written, and the red 'Error Output' connection represents rows that were erroneous. The 'RabbitMQErrorMessage' output column found in the 'Error Output' may contain the error message that was reported by RabbitMQ or the component itself.
NOTE: Use extra caution when selecting Ignore error option, since the component will remain silent for any errors that have occurred.