Deployment guide

Qpid Broker-J

Overview

Apache Qpid Broker-J is a pure Java message broker from the Apache Software Foundation. It speaks every major version of the AMQP wire protocol (0-8, 0-9, 0-91, 0-10 and 1.0), so clients written for almost any AMQP library can connect to one broker. It provides durable queues, topics and exchanges for reliable asynchronous messaging, plus an HTTP web management console for creating queues, browsing messages, managing users and watching broker activity.

This SecureAnyCloud image installs Qpid Broker-J 10.0.1 on OpenJDK 17 at /opt/qpid and runs it as a dedicated qpid system user. Every VM generates its own admin password and TLS certificate on first boot.

What you get:

  • Apache Qpid Broker-J 10.0.1 on OpenJDK 17 at /opt/qpid, run by the dedicated qpid system user
  • A single "Plain" authentication provider bound to every port, with no guest user and no anonymous access
  • AMQP on 5672 and TLS AMQPS on 5671 (AMQP 0-8, 0-9, 0-91, 0-10 and 1.0)
  • The HTTP web management console bound to loopback 127.0.0.1:8080 and fronted by an nginx TLS reverse proxy on :443 with a per-VM self-signed certificate, with :80 redirecting to HTTPS
  • A per-VM admin password (QPID_ADMIN_PASSWORD) generated on first boot and stored in a root-only file
  • qpid.service and nginx.service as enabled, active systemd units
  • 24/7 SecureAnyCloud support

Prerequisites

You need an active Azure subscription, an SSH key pair, and a VNet with a subnet in the target region.

Standard_B2s (2 vCPU / 4 GiB RAM) is a good starting size for the JVM broker. Scale up for higher message throughput.

Configure the network security group (NSG) to allow inbound 22/tcp from your management network and 443/tcp for the web console. Also allow the message ports your clients use, 5672 for AMQP and 5671 for AMQPS, from your application networks.

Step 1 - Deploy from the Azure Marketplace

Sign in to the Azure Portal, choose Create a resource, search the Marketplace for Apache Qpid Broker-J by SecureAnyCloud, and select Create.

On the Basics tab, pick your subscription, resource group, region and size. Under Administrator account, choose SSH public key and paste your key. Under Inbound port rules, allow SSH (22) and HTTPS (443).

Select Review + create, then Create.

Step 2 - Deploy from the Azure CLI

# Accept the Marketplace terms once per subscription (required before the first CLI deploy)
az vm image terms accept --urn sac1647283583153:qpid-broker-j-ubuntu-24-04:default:latest
az vm create \
  --resource-group <your-rg> \
  --name qpid \
  --image sac1647283583153:qpid-broker-j-ubuntu-24-04:default:latest \
  --size Standard_B2s \
  --admin-username azureuser \
  --ssh-key-values ~/.ssh/id_ed25519.pub \
  --vnet-name <your-vnet> --subnet <your-subnet> \
  --public-ip-sku Standard
az vm open-port --resource-group <your-rg> --name qpid --port 443 --priority 1010

Step 3 - Connect to your VM

ssh azureuser@<vm-public-ip>

Step 4 - Confirm the services are running

Check that both services are active.

systemctl is-active qpid.service nginx.service

Both services report active. On first boot the broker can take a minute or two to start while the JVM warms up.

The AMQP acceptors listen on 5672 (AMQP) and 5671 (AMQPS). The management console listens on loopback 127.0.0.1:8080 and is reached through nginx on :443.

Step 5 - Retrieve your admin password

Your VM generates a unique admin password on first boot and writes it to a root-only file. Read it with sudo:

sudo cat /root/qpid-broker-j-credentials.txt

The QPID_ADMIN_PASSWORD value is the password. Use it to sign in to the web console and to authenticate AMQP clients as admin.

No default or guest credential ships in the image, and no two VMs share a password.

Step 6 - Open the web management console

Browse to https://<vm-public-ip>/ and accept the per-VM self-signed certificate warning. Sign in as admin with the password from Step 5.

The Qpid Broker-J console lets you inspect the broker, virtual host, ports and authentication providers. You can also create and browse queues and exchanges and watch live message statistics.

Step 7 - Verify the broker health

The management REST API is served behind the nginx TLS proxy. An unauthenticated request is rejected with 401, and the per-VM admin returns 200 with the broker attributes. Run these commands on the VM:

PW=$(sudo grep '^QPID_ADMIN_PASSWORD=' /root/qpid-broker-j-credentials.txt | cut -d= -f2-)
curl -sk -o /dev/null -w 'unauthenticated: HTTP %{http_code}\n' https://127.0.0.1/api/latest/broker
curl -sk -u "admin:$PW" https://127.0.0.1/api/latest/broker | head -c 200; echo

The first call prints HTTP 401. The second returns a JSON document that includes the broker modelVersion and productVersion, which confirms that the console authenticates the per-VM admin over TLS.

Step 8 - Send and receive a test message

The image includes a small AMQP round-trip helper. It connects as the per-VM admin, declares a durable queue, publishes a message and consumes it back. Run it on the VM:

PW=$(sudo grep '^QPID_ADMIN_PASSWORD=' /root/qpid-broker-j-credentials.txt | cut -d= -f2-)
python3 /opt/qpid/bin/qpid-amqp-roundtrip.py admin "$PW"

It prints AMQP_RT_OK followed by the message body it published and consumed. This confirms an authenticated, end-to-end AMQP round trip against the broker.

Step 9 - Connect from your applications

Point AMQP clients at amqp://<vm-public-ip>:5672 and TLS clients at amqps://<vm-public-ip>:5671. Authenticate as admin with the password from Step 5.

Qpid Broker-J speaks AMQP 0-8, 0-9, 0-91, 0-10 and 1.0 on both ports, so libraries such as Qpid Proton, Apache Qpid JMS and pika all work with the same broker.

Open the matching NSG ports from your application networks only. Prefer the TLS AMQPS listener for traffic that leaves your VNet.

# Python (AMQP 1.0) example using Qpid Proton:
# from proton import Message
# from proton.utils import BlockingConnection
# conn = BlockingConnection("amqps://admin:<password>@<vm-public-ip>:5671", ssl_domain=...)

Step 10 - Confirm authentication is enforced

Only clients that present the per-VM credential are authorized. The broker rejects a wrong or anonymous AMQP credential, and the console requires the admin password. Run this on the VM to confirm that a bad credential is refused:

PW=$(sudo grep '^QPID_ADMIN_PASSWORD=' /root/qpid-broker-j-credentials.txt | cut -d= -f2-)
python3 /opt/qpid/bin/qpid-amqp-roundtrip.py --negative admin "$PW"

It prints AMQP_AUTH_REJECTED, which confirms that the broker refuses a wrong credential. The Plain authentication provider has no guest user and no anonymous mechanism.

Using a real TLS certificate

The image ships a per-VM self-signed certificate, so the console and AMQPS are encrypted out of the box. For production, terminate TLS at nginx with a real domain pointed at the VM's public IP.

Install certbot and request a certificate, replacing the domain with your own:

sudo apt-get update && sudo apt-get install -y certbot python3-certbot-nginx
sudo certbot --nginx -d your-domain.example.com

To present a CA-signed certificate on the AMQPS listener as well, import your certificate and key into the broker keystore at /var/lib/qpid/etc/keystore.p12 and restart qpid.service.

Adding and rotating users

Manage broker users in the web console under authenticationproviders > passwordProvider. You can add users, set passwords and remove the initial admin once you have created your own.

You can also create and browse queues, exchanges and bindings from the console, or through the broker REST API under /api/latest/.

Backup and maintenance

The broker configuration and any durable message state live under /var/lib/qpid on the OS disk. Snapshot the VM disk in Azure to back it up.

Keep the OS patched with sudo apt update && sudo apt upgrade. Restart the broker cleanly with sudo systemctl restart qpid.

Support

24/7 SecureAnyCloud support backs this image. Contact us by email or chat for help with broker configuration, AMQP protocol versions, queues and exchanges, TLS, users and backups.

All product and company names are trademarks or registered trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by them.

Deploy on Azure

Launch Apache Qpid Broker-J on Ubuntu 24.04 LTS on Azure with 24/7 support from SecureAnyCloud.

View this image

Need Help?

Our support team is available 24/7.

sales@secureanycloud.com

Deploy on Azure