Cloud Connectors in Payara Micro

Uncategorized

Payara Micro 172 brings with it support for JCA adapters, meaning it can be used as a client for Java Messaging Service (JMS) brokers. JMS is a Java EE API which provides a common interface for standard communication protocols. This means that you can send and receive messages between systems in a platform and language independent way. With Payara Micro now supporting JMS, you can setup your Micro instance as a JMS client with Message Driven Beans (MDBs) to listen and respond to messages from other systems through a message broker.

 

{{cta(‘f53ec10a-12d5-483b-b089-2d4cdab10448’)}}

 

What is a Message Broker?

Traditional message brokers were made to solve the problem of having multiple applications that need to act on data from multiple different data sources in a standard way. Without a message broker, you could well end up with a network looking like this:

 

cloud connectors 1.png

 

Having a message broker makes it look more like this:

 

cloud connectors 2.png

 

The message broker allows you to decouple your messaging from your application code and communicate between systems in a language agnostic way.

 

Message brokers typically follow a publish-subscribe pattern. This means that all messages received are stored in sections called topics. Producers send messages to the broker by publishing to this topic. The data in the message can be stored in any format depending on your needs. Consumers will then receive messages by subscribing to a particular topic. They will receive all messages from that topic. Consumers can subscribe to any number of topics, and handle each topic depending on the application needs.

 

Using Message Brokers With Payara Micro

Payara Micro isn’t packaged with a message broker. This means that Payara Micro stays lightweight, and allows you to integrate your application with an external message broker. You could, for example, dedicate a cluster of Payara Servers to be a message broker. This would mean that the message broker is more highly available. To integrate Payara Micro with these external message brokers, you need to include and deploy a Java Connector Architecture (JCA) adapter. While any valid JMS RAR file will allow you to connect to a JMS broker, the Cloud Connectors suite includes some examples of JCA adapters for non-JMS message brokers.

 

Currently we have JCA adapters for:

  • Apache Kafka – sending messages using a Connection Factory and receiving messages via an MDB.
  • Amazon SQS – sending messages using a Connection Factory and receiving messages via an MDB to Amazon Simple Queue Service queues.
  • MQTT – sending messages using a Connection Factory and receiving messages via an MDB to an MQTT broker or to IOT hubs that support MQTT.
  • Azure Service Bus – Sending and receiving messages to/from Azure Service Bus Queues using ConnectionFactory via MDB.

In future blogs ( see the list below) we will explore these different messaging platforms as well as sample projects using these adapters.

 

 

 {{cta(‘cd5027bd-d5ca-4a13-b76f-6ea11296df99’)}}

 

Comments (0)

Post a comment

Your email address will not be published. Required fields are marked *

Payara needs the contact information you provide to us to contact you about our products and services. You may unsubscribe from these communications at any time. For information on how to unsubscribe, as well as our privacy practices and commitment to protecting your privacy, please review our Legal & Privacy Policy.

Related Posts

Blue background with coral and fish. Left text: 'MONTHLY CATCH'. Right: laptop screen with tech tabs and Payara Community logo. 3 minutes
Community

The Payara Monthly Catch -September 2025

Welcome aboard the September issue of The Monthly Catch! With summer holidays wrapping up, the Java world is back […]

4 minutes
Uncategorized

Leading the Way: Payara Platform Community 7 Beta Now Fully Jakarta EE 11 Certified

We’re excited to announce that Payara Platform Community 7 Beta application server is now fully certified as Jakarta EE 11 […]

JBoss ELS Decoded 5 minutes
Migration

JBoss ELS Decoded: What Extended Lifecycle Support Really Means for Your Java Applications​

If your Java EE 8 applications run on Red Hat JBoss Enterprise Application Platform (EAP) 7, you can’t afford […]