Skip to content

Latest commit

 

History

115 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 


BlazingMQ License Java Maven MessageQueue Documentation

BlazingMQ Java SDK

This repository provides the official Java client library as well as examples of how applications can interact with BlazingMQ. BlazingMQ is an open source message queue system with focus on efficiency, reliability and a rich feature set. Please see the BlazingMQ repo and documentation for more details about BlazingMQ.

This Java client is fully supported by the BlazingMQ team and we provide feature and/or API parity with the BlazingMQ C++ client library.

Menu

Using

This repository contains two modules. The built packages for these modules are available in Maven Central:

  • bmq-sdk: contains BlazingMQ Java client library code
  • bmq-examples: contains sample producer and consumer clients

Building

Build and Install the JARs

Execute from repo root:

$ mvn clean install

Above command will compile and install both modules -- bmq-sdk as well as bmq-examples. It will also run tests and carry out static analysis. If it is desired to skip running any tests and static analysis while creating the JARs (because those steps were executed already), one can execute:

$ mvn clean -Dmaven.test.skip=true -Dspotbugs.skip=true install

Build and Run bmq-examples Producer Example

Prerequisites:

  • BlazingMQ backend is built and is available.
  • bmq-sdk JAR is installed locally.

Java SDK producers/consumers can be tested with the local BlazingMQ broker. For Linux build, first start the local broker:

cd $BLAZINGMQ_DIR/build/Linux/src/applications/bmqbrkr
./run

Secondly, start sample producer, that will connect to the local broker, open a queue, post messages and exits:

$ cd bmq-examples
$ mvn clean compile
$ mvn exec:java -Dexec.mainClass="com.bloomberg.bmq.examples.SimpleProducer"

Building BlazingMQ Backend

Detailed instructions on how to build BlazingMQ backend (BlazingMQ message brokers, etc) can be found here.

Supported JDKs

The SDK requires JDK 17 or newer to build and run. The code is compiled with release=17.

By default, the JDK defined in JAVA_HOME is used. To use a specific JDK, override JAVA_HOME env variable. For instance:

# clean output and compile the code using a specific JDK install
$ JAVA_HOME=${PATH_TO_JDK} mvn clean compile
...
[INFO] BUILD SUCCESS
...

Build and Run Unit Tests

  • All unit tests

    $ mvn -q -Dspotbugs.skip=true -Dspotless.check.skip=true test  // '-q' for quiet mode
  • A specific unit test class, e.g. OpenQueueTest

    $ mvn -q -Dspotbugs.skip=true -Dspotless.check.skip=true -Dtest=OpenQueueTest test
  • A specific unit test method of a class, e.g. OpenQueueTest.testReset

    $ mvn -q -Dspotbugs.skip=true -Dspotless.check.skip=true -Dtest=OpenQueueTest#testReset test

Contributions

We welcome your contributions to help us improve and extend this project!

We welcome issue reports here; be sure to choose the proper issue template for your issue, so that we can be sure you're providing us with the necessary information.

Before sending a Pull Request, please make sure you have read our Contribution Guidelines.

License

The BlazingMQ Java SDK is Apache 2.0 licensed, as found in the LICENSE file.

Code of Conduct

This project has adopted a Code of Conduct. If you have any concerns about the Code, or behavior which you have experienced in the project, please contact us at opensource@bloomberg.net.

Security Vulnerability Reporting

If you believe you have identified a security vulnerability in this project, please email the project team at opensource@bloomberg.net, detailing the suspected issue and any methods you've found to reproduce it.

Please do NOT open an issue in the GitHub repository, as we'd prefer to keep vulnerability reports private until we've had an opportunity to review and address them.

About

Java SDK for BlazingMQ, a modern high-performance open source message queuing system.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

34 stars

Watchers

12 watching

Forks

Releases

Packages

Used by

Contributors

Languages