Diffusion AMQP Adapter User’s Guide

Version: 1.0.0

Gateway Framework version: 2.3.0

Publish date: 21-01-2025

Logo Diffusion transparent
Prerequisite: See Gateway Application for a generic overview of a Gateway application and how to configure it

About AMQP adapter

The AMQP adapter can be used to facilitate communication between an AMQP-compliant messaging server and a Diffusion server (or server cluster). The adapter connects to an AMQP broker (e.g., RabbitMQ or ActiveMQ) using the AMQP 1.0 protocol. It uses the Apache Qpid JMS Library for AMQP communication.

The adapter enables consuming and processing messages from AMQP queues and topics and publishing them to Diffusion topics through a streamlined workflow. The adapter provides the following functionalities:

  • Message Consumption: Connects to a specified AMQP queue or topic and consumes messages.

  • Message Transformation: Supports converting AMQP messages (e.g., JmsBytesMessage, TextMessage) into desired formats, such as JSON or Binary.

  • Message Publishing: Publishes processed messages to Diffusion topics.

The adapter uses the Diffusion Gateway framework, hence supports all features provided by the framework. See Gateway Application section in the Framework’s user guide to understand the concepts of the framework and how to configure a Gateway application.

The adapter can be viewed and managed from the Diffusion management console of the connected server or in any other server in the same cluster. Once started, the adapter is visible on the Diffusion console, in the 'Network' section, as type 'AMQP Adapter' with the ID specified in the configuration.

Software Requirements

To run the AMQP adapter, the following requirements must be met:

  • Java 11+ (JDK)

  • Diffusion server (or server cluster) (min v6.9)

  • AMQP Broker: RabbitMQ, ActiveMQ, or any AMQP 1.0-compatible server

  • Docker (optional, for containerized deployment)

Features

The AMQP Adapter provides the following features:

  • AMQP 1.0 Compatibility: Supports AMQP-compliant servers such as RabbitMQ and ActiveMQ.

  • Customizable Message Transformation: Ability to convert AMQP messages (e.g., JmsBytesMessage) to JSON, Binary, or other formats.

  • Connection Resilience: Automatically reconnects to the broker in case of connection failures.

  • Customizable Message Consumption: Supports batch or real-time consumption.

  • Client Acknowledgment Mode: Ensures message processing integrity with manual acknowledgment.

  • Error Handling and Recovery: Supports session recovery and message redelivery.

  • Monitoring and Logging: Provides configurable logging for tracking message processing and exposes metrics to monitor the adapter.

Limitations

  • Only supports AMQP 1.0-compliant brokers.

  • Message order is not guaranteed in batch mode.

  • Additional overhead may occur if the Diffusion topic template generates many topics dynamically.

About this document

This document explains everything you need to set up and use the AMQP Adapter with Diffusion.

This document should be used in conjunction with the Gateway Framework user’s guide.

NOTE: If you are accessing this document bundled together with the adapter artifacts, please refer to the online version of the same document for its latest version.

Build: 60057.e70b9ec6