RabbitMQ Java client

Overview

RabbitMQ Java Client

This repository contains source code of the RabbitMQ Java client. The client is maintained by the RabbitMQ team at Pivotal.

Dependency (Maven Artifact)

This package is published to several Maven package repositories:

Maven

Maven Central

5.x Series

This client releases are independent from RabbitMQ server releases and can be used with RabbitMQ server 3.x. They require Java 8 or higher.

<dependency>
    <groupId>com.rabbitmq</groupId>
    <artifactId>amqp-client</artifactId>
    <version>5.11.0</version>
</dependency>

Gradle

compile 'com.rabbitmq:amqp-client:5.11.0'

4.x Series

As of 1 January 2021 the 4.x branch is no longer supported.

This client releases are independent from RabbitMQ server releases and can be used with RabbitMQ server 3.x. They require Java 6 or higher.

<dependency>
    <groupId>com.rabbitmq</groupId>
    <artifactId>amqp-client</artifactId>
    <version>4.12.0</version>
</dependency>

Gradle

compile 'com.rabbitmq:amqp-client:4.12.0'

Experimenting with JShell

You can experiment with the client from JShell. This requires Java 9 or more.

git clone https://github.com/rabbitmq/rabbitmq-java-client.git
cd rabbitmq-java-client
./mvnw test-compile jshell:run
...
import com.rabbitmq.client.*
ConnectionFactory cf = new ConnectionFactory()
Connection c = cf.newConnection()
...
c.close()
/exit

Building from Source

Getting the Project and its Dependencies

git clone [email protected]:rabbitmq/rabbitmq-java-client.git
cd rabbitmq-java-client
make deps

Building the JAR File

./mvnw clean package -Dmaven.test.skip -P '!setup-test-cluster'

Launching Tests with the Broker Running In a Docker Container

Run the broker:

docker run -it --rm --name rabbitmq -p 5672:5672 rabbitmq:3.8

Launch "essential" tests (takes about 10 minutes):

./mvnw verify -P '!setup-test-cluster' \
    -Drabbitmqctl.bin=DOCKER:rabbitmq \
    -Dit.test=ClientTests,FunctionalTests,ServerTests

Launch a single test:

./mvnw verify -P '!setup-test-cluster' \
    -Drabbitmqctl.bin=DOCKER:rabbitmq \
    -Dit.test=DeadLetterExchange

Launching Tests with a Local Broker

The tests can run against a local broker as well. The rabbitmqctl.bin system property must point to the rabbitmqctl program:

./mvnw verify -P '!setup-test-cluster' \
       -Dtest-broker.A.nodename=rabbit@$(hostname) \
       -Drabbitmqctl.bin=/path/to/rabbitmqctl \
       -Dit.test=ClientTests,FunctionalTests,ServerTests

To launch a single test:

./mvnw verify -P '!setup-test-cluster' \
       -Dtest-broker.A.nodename=rabbit@$(hostname) \
       -Drabbitmqctl.bin=/path/to/rabbitmqctl \
       -Dit.test=DeadLetterExchange

Contributing

See Contributing and How to Run Tests.

Versioning

This library uses semantic versioning.

Support

See the RabbitMQ Java libraries support page for the support timeline of this library.

License

This package, the RabbitMQ Java client library, is triple-licensed under the Mozilla Public License 2.0 ("MPL"), the GNU General Public License version 2 ("GPL") and the Apache License version 2 ("ASL").

This means that the user can consider the library to be licensed under any of the licenses from the list above. For example, you may choose the Apache Public License 2.0 and include this client into a commercial product. Projects that are licensed under the GPLv2 may choose GPLv2, and so on.

Comments
  • When server closes TCP connection because TCP window is full, connection recovery does not kick in

    When server closes TCP connection because TCP window is full, connection recovery does not kick in

    Summary

    We started seeing the following in production:

    java.net.SocketException: Broken pipe
    	at java.net.SocketOutputStream.socketWrite0(Native Method)
    	at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:109)
    	at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
    	at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
    	at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
    	at java.io.DataOutputStream.flush(DataOutputStream.java:123)
    	at com.rabbitmq.client.impl.SocketFrameHandler.flush(SocketFrameHandler.java:177)
    	at com.rabbitmq.client.impl.AMQConnection.flush(AMQConnection.java:559)
    	at com.rabbitmq.client.impl.AMQCommand.transmit(AMQCommand.java:127)
    	at com.rabbitmq.client.impl.AMQChannel.quiescingTransmit(AMQChannel.java:396)
    	at com.rabbitmq.client.impl.AMQChannel.transmit(AMQChannel.java:372)
    	at com.rabbitmq.client.impl.AMQChannel.transmit(AMQChannel.java:365)
    	at com.rabbitmq.client.impl.ChannelN.basicAck(ChannelN.java:1169)
    	at com.rabbitmq.client.impl.recovery.RecoveryAwareChannelN.basicAck(RecoveryAwareChannelN.java:89)
    	at com.rabbitmq.client.impl.recovery.AutorecoveringChannel.basicAck(AutorecoveringChannel.java:436)
    	at RMQProblemTest$1.handleDelivery(RMQProblemTest.java:87)
    	at com.rabbitmq.client.impl.ConsumerDispatcher$5.run(ConsumerDispatcher.java:149)
    	at com.rabbitmq.client.impl.ConsumerWorkService$WorkPoolRunnable.run(ConsumerWorkService.java:100)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    	at java.lang.Thread.run(Thread.java:745)
    

    After looking at a packet capture, we were seeing [TCP Window Full] messages when RabbitMQ was sending to our consumer followed by a ton of [TCP ZeroWindow] frames coming from the consumer. After enough of these, RabbitMQ abruptly closes the connection by sending a RST frame and reporting only this in the logs:

    =ERROR REPORT==== 10-Jan-2018::20:38:08 ===
    closing AMQP connection <0.5373.1> ([::1]:53814 -> [::1]:5672):
    {writer,send_failed,{error,timeout}}
    

    Further investigation revealed that I was setting the QoS for the consumer only AFTER I had already started consuming (i.e. I was calling basicConsume directly before basicQos). I realize that this was wrong of me, however, it seems odd that this would cause the exception above especially with such a relatively small number of small messages. The more concerning thing is that none of the recovery/shutdown methods on either the connection or channel seemed to be called despite the fact that the connection was indeed closed.

    Reproduction

    I made a little test project that shows the issue.

    https://github.com/vincentjames501/rmq-fail/blob/master/src/test/java/RMQProblemTest.java

    Running the test will show the issue after 30 seconds or so. It appears reproducible on most RabbitMQ versions but I documented by setup below.

    Environment

    RabbitMQ server - 3.6.12 Erlang - Erlang 20.1 Operating system version (and distribution, if applicable) - OSX 10.13.2 All client libraries used - RabbitMQ Java Client 4.4.1 RabbitMQ plugins (if applicable) - Just Management Console

    Thanks!

    bug effort-medium 
    opened by vincentjames501 28
  • NIO main thread can terminate due to an unhandled javax.net.ssl.SSLException

    NIO main thread can terminate due to an unhandled javax.net.ssl.SSLException

    I described my problem here - https://github.com/rabbitmq/rabbitmq-java-client/issues/236 As per suggestion, I tried using v4.0.1 version of the library with NIO to work around the issue. The good thing is that that version does indeed detect connection problem much faster that 15 minutes that it used to take for previous version. The bad thing is that NIO main thread catches unhandled exception and terminates rendering the whole application unusable.

    SEVERE: Unhandled exception. Aborting.
    Throwable occurred: java.lang.AssertionError: BlockingCell can only be set once
    	at com.rabbitmq.utility.BlockingCell.set (BlockingCell.java:141)
    	at com.rabbitmq.client.impl.AMQConnection.doFinalShutdown (AMQConnection.java:681)
    	at com.rabbitmq.client.impl.AMQConnection.handleHeartbeatFailure (AMQConnection.java:654)
    	at com.rabbitmq.client.impl.nio.NioLoop.run (NioLoop.java:78)
    	at java.lang.Thread.run (Unknown Source, bco=11)
    

    I cannot easily reproduce it as I do not know what that bloody piece of network equipment does but it feels like it just stops outgoing packets from he client machine at some point while still allowing incoming ones.

    previous exceptions that lead to the one above

    Jan 16, 2017 11:45:56 AM com.rabbitmq.client.impl.nio.NioLoop run
    WARNING: Error during reading frames
    Throwable occurred: javax.net.ssl.SSLException: closed in read
    	at com.rabbitmq.client.impl.nio.SslEngineByteBufferInputStream.read (SslEngineByteBufferInputStream.java:89)
    	at java.io.DataInputStream.readUnsignedByte (Unknown Source, bco=4)
    	at com.rabbitmq.client.impl.Frame.readFrom (Frame.java:91)
    	at com.rabbitmq.client.impl.nio.NioLoop.run (NioLoop.java:149)
    	at java.lang.Thread.run (Unknown Source, bco=11)
    Jan 16, 2017 11:45:56 AM com.rabbitmq.client.impl.ForgivingExceptionHandler log
    SEVERE: An unexpected connection driver error occured
    Throwable occurred: com.rabbitmq.client.MissedHeartbeatException: Heartbeat missing with heartbeat = 30 seconds
    	at com.rabbitmq.client.impl.AMQConnection.handleHeartbeatFailure (AMQConnection.java:648)
    	at com.rabbitmq.client.impl.nio.NioLoop.run (NioLoop.java:78)
    	at java.lang.Thread.run (Unknown Source, bco=11)
    Jan 16, 2017 11:45:56 AM com.rabbitmq.client.impl.ForgivingExceptionHandler log
    SEVERE: An unexpected connection driver error occured
    Throwable occurred: javax.net.ssl.SSLException: closed in read
    	at com.rabbitmq.client.impl.nio.SslEngineByteBufferInputStream.read (SslEngineByteBufferInputStream.java:89)
    	at java.io.DataInputStream.readUnsignedByte (Unknown Source, bco=4)
    	at com.rabbitmq.client.impl.Frame.readFrom (Frame.java:91)
    	at com.rabbitmq.client.impl.nio.NioLoop.run (NioLoop.java:149)
    	at java.lang.Thread.run (Unknown Source, bco=11)
    
    bug effort-tiny 
    opened by dimas 26
  • update rpc server

    update rpc server

    sometime we need add more information to replyProperties (i.e set headers), so with handleCall function, we need replyPropertiesBuilder not replyProperties argument.

    opened by tvd12 24
  • Inform recovery listeners when recovery has started

    Inform recovery listeners when recovery has started

    ...in case an app wants to log something / set a flag / fire an event when a recovery has begun but before it has completed.

    This particular implementation is just an idea / work in progress and hasn't been tested extensively, but I thought it easier to communicate the idea via code than a thousand words trying to describe it.

    The major downfall to this approach is that it's a breaking API change to RecoveryListener, though I suspect application use of RecoveryListener is somewhat less-than-common. Another approach might be to make a subinterface of RecoveryListener that holds the extra method (though that's ugly and requires a bunch of instanceof checking when notifying), or changing RecoveryListener to be an abstract class with an empty handleRecoveryStarted method, though this approach isn't exactly pretty either.

    Yet another approach would be to create a completely independent interface called RecoveryStartedListener and have them added separately, so they'd be managed independently. This would avoid the breaking API change, but it would add more bookkeeping to the code.

    Our use case is that we'd both like to log when a recovery has started and set a flag that a recovery is in progress, then flip the bit back when recovery has completed (and continue to log it as we do now) so that our background task that tries very hard to ensure that consumers keep consuming over dodgy Internet connections can make more intelligent decisions about when to abort & replace a connection (sometimes necessary if an IP address changes, etc., but we'd rather give automatic recovery a chance to work first if it's in progress and likely to succeed).

    effort-low enhancement 
    opened by spatula75 19
  • #37 Migrate build system away from Ant (WIP)

    #37 Migrate build system away from Ant (WIP)

    Fixed #37 (at least to a large extent).

    The tests can be run with mvn clean test or with ant, I kept it compatible.

    And also with the right settings.xml in your ~/.m2 directory like

    <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
                          http://maven.apache.org/xsd/settings-1.0.0.xsd">
    <servers>
        <server>
          <id>sonatype-nexus-staging</id>
          <username>my_login</username>
          <password>my_password</password>
        </server>
      </servers>
    </settings>
    

    you can run mvn clean deploy that would compile, run the tests, and deploy to the repository if the tests pass.

    I also added maven version plugin, so to set a version you can do it that way mvn versions:set -DnewVersion=<new.version> && mvn versions:commit

    That's a better alternative than the release plugin. So basically to release a new version the maven command would be: mvn versions:set -DnewVersion=<new.version> && mvn versions:commit && mvn clean deploy

    opened by PatrickSauts 19
  • AutorecoveringConnection fires client shutdown hooks after connection has recovered

    AutorecoveringConnection fires client shutdown hooks after connection has recovered

    Version - amqp-client-3.6.1

    When init is called on AutorecoveringConnection it adds the automatic recovery listener to the shutdownHooks list - Because this is the first entry, any user added shutdown hooks will be called after the automatic recovery.

    as a possible solution; The listener created in addAutomaticRecoverListener would likely need to call each shutdownListener, and omit adding the created listener to the shutdownHooks. addShutdownListener, removeShutdownListener would only apply to the shutdownHooks list and not add to the delegate. recoverShutdownListeners would just call addAutomaticRecoverListener.

    effort-low usability enhancement 
    opened by doswell 18
  • Metrics for successful and unsuccessful outgoing publishes

    Metrics for successful and unsuccessful outgoing publishes

    Hey there! This is a feature request I'd be willing to create PR for.

    As it stands now, when you're publishing a message and it is successful, the published counter in MetricsCollector will be incremented. I'd like to add publishFailed counter, which will be incremented if and when publishing attempt fails.

    This will allow users to easily create reports of publishing success rates and help them determine if the number messages they're not publishing are a significant enough to increase resiliency of their programs.

    I'd like to find out if this is a feature that would be a welcome addition and if the way I'd like to add it would meet your expectations.

    effort-low enhancement breaking-change 
    opened by slayful 17
  • Check qos, heartbeat, max channel are unsigned shorts

    Check qos, heartbeat, max channel are unsigned shorts

    In all versions of this client, including the current version in master, the basic QoS "prefetch count" property is specified of type int. However, the AMQP 0.9.1 Reference specifies prefetch count to be of type short, which it further clarifies to be 16-bit integer.

    This most naturally maps to java type short rather than int.

    As a result, it's relatively simple to specify values that are out of bounds, such as 100000 (100k). These values have their most significant bits truncated and result in a transmitted value to the server of something else. In the case of 100000 the server will see the 16 least significant bits, which come out to value 16960. (See this SO post for context)

    Possible fixes for this would include one or all of: a) explicitly failing of the value supplied is > Short.MAX_VALUE b) changing the allowed type in the client from int to short

    bug usability breaking-change 
    opened by drobert 16
  • channel.queueDelete sometimes throws NullPointerException, possibly due to race on recordedBindings

    channel.queueDelete sometimes throws NullPointerException, possibly due to race on recordedBindings

    When multiple channels share an AutorecoveringConnection and queues are coming and going from multiple theads, about 1 time out of 10000 , we are seeing a NullPointerException or ConcurrentModificationException to be thrown:

    java.lang.NullPointerException
            at com.rabbitmq.client.impl.recovery.AutorecoveringConnection.removeBindingsWithDestination(AutorecoveringConnection.java:768)
            at com.rabbitmq.client.impl.recovery.AutorecoveringConnection.deleteRecordedQueue(AutorecoveringConnection.java:690)
            at com.rabbitmq.client.impl.recovery.AutorecoveringChannel.deleteRecordedQueue(AutorecoveringChannel.java:562)
            at com.rabbitmq.client.impl.recovery.AutorecoveringChannel.queueDelete(AutorecoveringChannel.java:303)
            at com.rabbitmq.client.impl.recovery.AutorecoveringChannel.queueDelete(AutorecoveringChannel.java:299)
    

    The code at this location looks innocuous enough:

        Set<RecordedBinding> removeBindingsWithDestination(String s) {
            Set<RecordedBinding> result = new HashSet<RecordedBinding>();
            for (Iterator<RecordedBinding> it = this.recordedBindings.iterator(); it.hasNext(); ) {
                RecordedBinding b = it.next();
                if(b.getDestination().equals(s)) { // [[ NPE here ]] //
                    it.remove();
                    result.add(b);
                }
            }
            return result;
        }
    

    However, removeBindingsWithDestination is not synchronized, so it's possible for multiple threads to be in this method changing the recordedBindings ArrayList at the same time as bindings come and go from multiple threads, even with channels not being shared across threads (but the Connection is shared).

    It looks the other accesses to recordedBindings are synchronized (though caution: maybeDeleteRecordedAutoDeleteExchange is synchronizing differently than the others) so removeBindingsWithDestination may have just fallen through the cracks.

    It may be a sufficient fix just to make removeBindingsWithDestination synchronized.

    (Another tangential thing I noticed is that most of the recorded maintenance is done from synchronized methods, but maybeDeleteRecordedAutoDeleteQueue during a basicCancel instead synchronizes on recordedQueues and consumers, and that this method just removes the recordedQueues entry, not the recordedBindings associated with the queue as well.)

    bug effort-low 
    opened by spatula75 16
  • When recovery is enabled more deliveries can be acked after recovery than the user expects

    When recovery is enabled more deliveries can be acked after recovery than the user expects

    I found the following code in the class RecoveryAwareChannelN:

    @Override
    public void basicAck(long deliveryTag, boolean multiple) throws IOException {
        long realTag = deliveryTag - activeDeliveryTagOffset;
        // 0 tag means ack all when multiple is set
        if (realTag > 0 || (multiple && realTag == 0)) {
            transmit(new Basic.Ack(realTag, multiple));
            metricsCollector.basicAck(this, deliveryTag, multiple);
        }
    }
    

    When activeDeliveryTagOffset and deliveryTag are the same (this can happen directly after a channel is reconnected/recovered) this method will ack all outstanding messages instead of acking nothing.

    The output of the attached sample application contains PRECONDITION_FAILED - unknown delivery tag 1 because it is trying to ack all messages. But it was already acked by acking the first message after connection recovery.

    example-output.txt TestRabbitRecover.txt

    • RabbitMQ version 3.6.15

    • Erlang version Erlang 19.3.6.7

    • Client library version (for all libraries used) com.rabbitmq/amqp-client/4.5.0

    bug effort-low 
    opened by caspermout 15
  • Heap out of memory error if consumer is slow and auto ack is used

    Heap out of memory error if consumer is slow and auto ack is used

    Because WorkPool uses an unbounded LinkedList, when a consumer is not fast enough the list will be filled by the connection thread until OOM error. This is aggravated by GC pressure making consumers even slower.

    I suggest using a bounded blocking queue instead.

    opened by nukemberg 15
  • Changed ClientProperty after recovery in connection.created message

    Changed ClientProperty after recovery in connection.created message

    Hello,

    We are using this version com.rabbitmq amqp-client 5.15.0

    But 3.16.0 hasn't changed in the following regards.

    We are facing the issue that we need a unique identifier that should change after each connection incl. automatic recovery. That's why we added this UUID into the clientProperties of the connection via ConnectionFactory. Everything works but the initial connection.created message the rabbit server is sending after a recovery. Here we see the old UUID still. We tried to change the property in the recoveryStarted call.

    But when I look into the source code, we don't have any chance to do this.

    AutorecoveringConnection stores params, which are not accessible from outside but in parts through a delegate that is created as RecoveryAwareAMQConnection using this params. Unfortunately they are stored as a new HashMap in AMQConnection: this._clientProperties = new HashMap(params.getClientProperties()); As well as whole as params in RecoveryAwareAMQConnectionFactory.

    The AutorecoveringConnection.recoverConnection is calling the internal ConnectionFactory (not ours) to create a newConnection which is using the stored params, which is not accessible for us.

    As I previously said, the first call of recoveryStart is too late for us to make any modification, because we need this changed clientProperty in the first communication (connection.created message) that is made before any channel activity.

    Or is there a way to do this anyhow? In my small opinion the clientProperties of the delegate of the current connection should be used for the new connection instead of the initially stored params of the factory.

    Kind regards, Markus Heidt

    I know, I hate those cases as well :)

    opened by mheidt 6
  • Thread.interrupt() cause message loss and hang for ChannelRpcTimeout(default 10mins) or forever

    Thread.interrupt() cause message loss and hang for ChannelRpcTimeout(default 10mins) or forever

    To avoid thread execution for too long, we interrupt the thread after the time limit is reached. Recently, We find that occasionally messages get lost. We use TX mode , and txCommit() got an ChannelContinuationTimeoutException. I found the following problem according to the warning log.

    if thread interrupted before rpc(m,k) then rpc will not be sent to the server. And k.getReply(..) will hang for _rpcTimeout or forever.

    client version is 5.8.0

    com.rabbitmq.client.impl.AMQChannel
    
    private AMQCommand privateRpc(Method m)
            throws IOException, ShutdownSignalException
        {
            SimpleBlockingRpcContinuation k = new SimpleBlockingRpcContinuation(m);
            rpc(m, k);
            // At this point, the request method has been sent, and we
            // should wait for the reply to arrive.
            //
            // Calling getReply() on the continuation puts us to sleep
            // until the connection's reader-thread throws the reply over
            // the fence or the RPC times out (if enabled)
            if(_rpcTimeout == NO_RPC_TIMEOUT) {
                return k.getReply();
            } else {
                try {
                    return k.getReply(_rpcTimeout);
                } catch (TimeoutException e) {
                    throw wrapTimeoutException(m, e);
                }
            }
        }
    
    opened by MrLiuzy 5
  • ForgivingExceptionHandler swallows Errors

    ForgivingExceptionHandler swallows Errors

    Several methods defined in ExceptionHandler interface accept Throwable as one of arguments. ForgivingExceptionHandler and DefaultExceptionHandler (which is used as a default ExceptionHandler implementation) as one of it's descendants effectively ignore any encountered Errors leaving application in abnormal state, which is strongly discouraged according to Error's description. Maybe it would be more correct to re-throw catched Errors after ExceptionHandler tried to log them or catch clauses should not even rely on ExceptionHandler to re-throw Errors.

    opened by vkochnev 11
  • newConnection does not shuffle addresses

    newConnection does not shuffle addresses

    We noticed that when using java client version 5.11.0 there is a significant skew in client connections towards the first Rabbit node in the list.

    It appears that AutoRecovering connection actually shuffles the list of rabbit nodes when creating new connections, but regular connection does not.

    public RecoveryAwareAMQConnection newConnection() throws IOException, TimeoutException {
        Exception lastException = null;
        List<Address> shuffled = shuffle(addressResolver.getAddresses());
    

    There is no shuffle call in the regular ConnectionFactory.newConnection method.

    opened by a701440 7
  • Make ConnectionFactory easier to use

    Make ConnectionFactory easier to use

    Related to #330.

    Many settings have been added to ConnectionFactory over the years, making it somewhat harder to configure. It's for instance easy to omit an important option when setting TLS, because the different TLS-related options are scattered: ConnectionFactory#useSslProtocol, ConnectionFactory#setSslContextFactory, ConnectionFactory#enableHostnameVerification. Same thing for NIO (mitigated by NioParams).

    A more "use-case oriented", less JavaBeans-like way could improve the situation, e.g.:

    cf.nio().executor(myNioExecutor).socketChannelConfigurator(configurator) // NIO configuration
      .connectionFactory() // going back to the connection factory (call may be avoided with syntax trick)
      .tls().context(sslContext).hostnameVerification(true); // TLS configuration
    

    Not longer useful configuration methods would be deprecated and scheduled for removal in 7.0.0.

    effort-low usability 
    opened by acogoluegnes 2
Releases(v5.16.0)
  • v5.16.0(Sep 9, 2022)

    Changes between 5.15.0 and 5.16.0

    This is a minor release with a new feature, usability improvements, and dependency upgrades. It is compatible with 5.15.x. All users of the 5.x.x series are encouraged to upgrade.

    Thanks to Rogelio J. Baucells (@rjbaucells) and Oleg Golberg (@ogolberg) for their contribution.

    Re-enable DNS round robin

    GitHub PR: #827

    OpenTelemetry metrics collector implementation

    GitHub PR: #817

    Increase max ConsumerWorkService block size to 256

    GitHub PR: #814

    Bump dependencies

    GitHub issue: #797

    Source code(tar.gz)
    Source code(zip)
  • v5.16.0.RC1(Sep 7, 2022)

    Changes between 5.15.0 and 5.16.0.RC1

    This is a minor release with a new feature, usability improvements, and dependency upgrades. It is compatible with 5.15.x. All users of the 5.x.x series are encouraged to test it.

    Thanks to Rogelio J. Baucells (@rjbaucells) and Oleg Golberg (@ogolberg) for their contribution.

    Re-enable DNS round robin

    GitHub PR: #827

    OpenTelemetry metrics collector implementation

    GitHub PR: #817

    Increase max ConsumerWorkService block size to 256

    GitHub PR: #814

    Bump dependencies

    GitHub issue: #797

    Source code(tar.gz)
    Source code(zip)
  • v5.15.0(Jun 14, 2022)

    Changes between 5.14.2 and 5.15.0

    This is a minor release with a bug fix, usability improvements, and dependency upgrades. It is compatible with 5.14.x. All users of the 5.x.x series are encouraged to upgrade.

    Thanks to @vikinghawk and @laststem for their contribution.

    Fix potential deadlock in AutorecoveringConnection

    GitHub PR: #786

    Use available processor number for default thread count in consumer work service

    GitHub issue: #730

    Add host description when throwing MissedHeartbeatException

    GitHub PR: #726

    Bump dependencies

    GitHub issue: #717

    Source code(tar.gz)
    Source code(zip)
  • v5.15.0.RC1(Jun 8, 2022)

    Changes between 5.14.2 and 5.15.0.RC1

    This is a pre-release for 5.15.0, a maintenance release with a bug fix, usability improvements, and dependency upgrades. It is compatible with 5.14.x. All users of the 5.x.x series are encouraged to test this version.

    Thanks to @vikinghawk and @laststem for their contribution.

    Fix potential deadlock in AutorecoveringConnection

    GitHub PR: #786

    Use available processor number for default thread count in consumer work service

    GitHub issue: #730

    Add host description when throwing MissedHeartbeatException

    GitHub PR: #726

    Bump dependencies

    GitHub issue: #717

    Source code(tar.gz)
    Source code(zip)
  • v5.14.2(Feb 10, 2022)

    Changes between 5.14.1 and 5.14.2

    This is a patch release with a bug fix in the ConnectionFactory file-based configuration. It is compatible with 5.14.2. All users are encouraged to upgrade.

    Thanks to @laurentperez for his contribution.

    Fix topology recovery flag evaluation in file-based configuration

    GitHub PR: #724

    Source code(tar.gz)
    Source code(zip)
  • v5.14.1(Jan 13, 2022)

    Changes between 5.14.0 and 5.14.1

    This is a patch release with 2 bug fixes in the NIO mode. It is compatible with 5.14.0. All users are encouraged to upgrade.

    Thanks to @mgrafl for his contribution.

    Enforce connection timeout in NIO TLS handshake

    GitHub issue: #719

    Set timeout on NIO connection

    GitHub PR: #720

    Source code(tar.gz)
    Source code(zip)
  • v5.14.0(Nov 15, 2021)

    Changes between 5.13.1 and 5.14.0

    This is a minor release with bug fixes, usability improvements, and dependency upgrades. It is compatible with 5.13.x. All users are encouraged to upgrade.

    Thanks to @wangqiandeniangniang, @ByteAlex, and @Yaytay for their contribution.

    TLS handshake hangs with NIO and TLS 1.3

    GitHub issue: #715

    Unsigned 8 bit number field type seems not to be supported

    GitHub issue: #714

    Change/remove usage of some deprecated JDK API

    GitHub issue: #709

    Be more defensive about provided channelMax values

    GitHub PR: #695

    Bump dependencies

    GitHub issue: #699

    Source code(tar.gz)
    Source code(zip)
  • v5.14.0.RC1(Nov 8, 2021)

    Changes between 5.13.1 and 5.14.0.RC1

    This is a pre-release for 5.14.0, a maintenance release with bug fixes, usability improvements, and dependency upgrades. It is compatible with 5.13.x. All users of the 5.x.x series are encouraged to test this version.

    Thanks to @wangqiandeniangniang, @ByteAlex, and @Yaytay for their contribution.

    TLS handshake hangs with NIO and TLS 1.3

    GitHub issue: #715

    Unsigned 8 bit number field type seems not to be supported

    GitHub issue: #714

    Change/remove usage of some deprecated JDK API

    GitHub issue: #709

    Be more defensive about provided channelMax values

    GitHub PR: #695

    Bump dependencies

    GitHub issue: #699

    Source code(tar.gz)
    Source code(zip)
  • v5.13.1(Aug 30, 2021)

    Changes between 5.13.0 and 5.13.1

    This is a patch release with a bug fix. It is compatible with 5.13.0. All users are encouraged to upgrade.

    Thanks to @YuryAndr for his contribution.

    Large message deliveries with TLS and NIO enabled results in a "buffer closed" exception in SslEngineHelper

    GitHub PR: #700

    Source code(tar.gz)
    Source code(zip)
  • v5.13.0(Jul 12, 2021)

    Changes between 5.12.0 and 5.13.0

    This is a minor release with usability improvements, a bug fix, and dependency upgrades. It is compatible with 5.12.0. All users are encouraged to upgrade.

    Thanks to @ValSmith and @vikinghawk for their contribution.

    Move resolved address shuffling to AddressResolver

    GitHub PR: #691

    Allow changing queue names during recovery

    GitHub PR: #693

    Topology recovery retry fixes for auto-delete queues

    GitHub PR: #692

    Bump dependencies

    GitHub PR: #683

    Source code(tar.gz)
    Source code(zip)
  • v5.13.0.RC2(Jul 5, 2021)

    Changes between 5.12.0 and 5.13.0.RC2

    This is a pre-release for 5.13.0, a maintenance release with usability improvements, a bug fix, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Thanks to @ValSmith and @vikinghawk for their contribution.

    Move resolved address shuffling to AddressResolver

    GitHub PR: #691

    Allow changing queue names during recovery

    GitHub PR: #693

    Topology recovery retry fixes for auto-delete queues

    GitHub PR: #692

    Bump dependencies

    GitHub PR: #683

    Source code(tar.gz)
    Source code(zip)
  • v5.13.0.RC1(Jun 30, 2021)

    Changes between 5.12.0 and 5.13.0.RC1

    This is a pre-release for 5.13.0, a maintenance release with a usability improvement and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Thanks to @ValSmith for their contribution.

    Move resolved address shuffling to AddressResolver

    GitHub PR: #691

    Bump dependencies

    GitHub PR: #683

    Source code(tar.gz)
    Source code(zip)
  • v5.12.0(Apr 9, 2021)

    Changes between 5.11.0 and 5.12.0

    This is a minor release with usability improvements and dependency upgrades. All users are encouraged to upgrade.

    Thanks to @vikinghawk, @gustf, and @captainju for their contribution.

    Consumer recovery retry needs to return the new consumer tag

    GitHub PR: #680

    Improvements to topology recovery retry logic

    GitHub PR: #678

    Add support for reading unsigned int "i"

    GitHub PR: #675

    Add support for reading unsigned short "u"

    GitHub PR: #674

    Handle basic query parameters in connection URI

    GitHub PR: #672

    Bump dependencies

    GitHub issue: #681

    Source code(tar.gz)
    Source code(zip)
  • v5.12.0.RC1(Apr 6, 2021)

    Changes between 5.11.0 and 5.12.0.RC1

    This is a pre-release for 5.12.0, a maintenance release with usability improvements and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Thanks to @vikinghawk, @gustf, and @captainju for their contribution.

    Consumer recovery retry needs to return the new consumer tag

    GitHub PR: #680

    Improvements to topology recovery retry logic

    GitHub PR: #678

    Add support for reading unsigned int "i"

    GitHub PR: #675

    Add support for reading unsigned short "u"

    GitHub PR: #674

    Handle basic query parameters in connection URI

    GitHub PR: #672

    Bump dependencies

    GitHub issue: #681

    Source code(tar.gz)
    Source code(zip)
  • v5.11.0(Feb 19, 2021)

    Changes between 5.10.0 and 5.11.0

    This is a minor release with usability improvements, a bug fix, and dependency upgrades. All users are encouraged to upgrade.

    Thanks to @vikinghawk and @rjbaucells for their contribution.

    Binding recovery retry should recover all bindings on the recovered queue

    GitHub PR: #667

    Add topology recovery started method to RecoveryListener

    GitHub PR: #668

    Adds required command line args to GraalVM native-image command

    GitHub PR: #666

    Recover channels with user-provided number

    GitHub issue: #670

    Bump dependencies

    GitHub issue: #662

    Source code(tar.gz)
    Source code(zip)
  • v5.11.0.RC1(Feb 17, 2021)

    Changes between 5.10.0 and 5.11.0.RC1

    This is a pre-release for 5.11.0, a maintenance release with usability improvements, a bug fix, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Thanks to @vikinghawk and @rjbaucells for their contribution.

    Binding recovery retry should recover all bindings on the recovered queue

    GitHub PR: #667

    Add topology recovery started method to RecoveryListener

    GitHub PR: #668

    Adds required command line args to GraalVM native-image command

    GitHub PR: #666

    Recover channels with user-provided number

    GitHub issue: #670

    Bump dependencies

    GitHub issue: #662

    Source code(tar.gz)
    Source code(zip)
  • v5.10.0(Oct 23, 2020)

    Changes between 5.9.0 and 5.10.0

    This is a maintenance release with a usability improvement, bug fixes, and dependency upgrades. All users are encouraged to upgrade.

    Add TLS settings for property-based configuration

    GitHub issue: #646

    Remove unnecessary lock acquisition

    GitHub issue: #650

    Channel state not cleaned when using abort

    GitHub issue: #661

    Bump optional dependencies

    GitHub issue: #660

    Source code(tar.gz)
    Source code(zip)
  • v5.10.0.RC2(Oct 21, 2020)

    Changes between 5.9.0 and 5.10.0.RC2

    This is a pre-release for 5.10.0, a maintenance release with a usability improvement, bug fixes, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Add TLS settings for property-based configuration

    GitHub issue: #646

    Remove unnecessary lock acquisition

    GitHub issue: #650

    Channel state not cleaned when using abort

    GitHub issue: #661

    Bump optional dependencies

    GitHub issue: #660

    Source code(tar.gz)
    Source code(zip)
  • v5.10.0.RC1(Oct 14, 2020)

    Changes between 5.9.0 and 5.10.0.RC1

    This is a pre-release for 5.10.0, a maintenance release with a usability improvement, a bug fix, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Add TLS settings for property-based configuration

    GitHub issue: #646

    Remove unnecessary lock acquisition

    GitHub issue: #650

    Bump optional dependencies

    GitHub issue: #660

    Source code(tar.gz)
    Source code(zip)
  • v5.9.0(Apr 14, 2020)

    Changes between 5.8.0 and 5.9.0

    This is a maintenance release with a new feature, a bug fix, and dependency upgrades. All users are encouraged to upgrade to this version.

    Thanks to @janssk1 for their contribution on this release.

    Allow configurable correlation ID generation in RpcClient

    GitHub issue: #637

    Make sure qos, heartbeat, max channel are unsigned shorts

    GitHub issue: #642

    Bump optional dependencies

    GitHub issue: #644

    Source code(tar.gz)
    Source code(zip)
  • v4.12.0(Apr 14, 2020)

    Changes between 4.11.3 and 4.12.0

    This is a minor release with a new feature, a bug fix, and dependency upgrades. It is compatible with 4.11.x. All users of the 4.x.x and 3.6.x series are encouraged to upgrade to this version.

    Thanks to @janssk1 for their contribution on this release.

    Allow configurable correlation ID generation in RpcClient

    GitHub issue: #637

    Make sure qos, heartbeat, max channel are unsigned shorts

    GitHub issue: #642

    Bump optional dependencies

    GitHub issue: #644

    Source code(tar.gz)
    Source code(zip)
  • v5.9.0.RC1(Apr 3, 2020)

    Changes between 5.8.0 and 5.9.0.RC1

    This is a pre-release for 5.9.0, a maintenance release with a new feature, a bug fix, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Allow configurable correlation ID generation in RpcClient

    GitHub issue: #637

    Make sure qos, heartbeat, max channel are unsigned shorts

    GitHub issue: #642

    Bump optional dependencies

    GitHub issue: #644

    Source code(tar.gz)
    Source code(zip)
  • v4.12.0.RC1(Apr 3, 2020)

    Changes between 4.11.3 and 4.12.0.RC1

    This is a pre-release for 4.12.0, a maintenance release with a new feature, a bug fix, and dependency upgrades. All users of the 4.x.x and 3.6.x series are encouraged to test this version.

    Allow configurable correlation ID generation in RpcClient

    GitHub issue: #637

    Make sure qos, heartbeat, max channel are unsigned shorts

    GitHub issue: #642

    Bump optional dependencies

    GitHub issue: #644

    Source code(tar.gz)
    Source code(zip)
  • v5.8.0(Dec 12, 2019)

    Changes between 5.7.3 and 5.8.0

    This is a maintenance release with a new feature, a usability improvement, and dependency upgrades. All users are encouraged to upgrade to this version.

    Add support for OAuth 2 authentication

    Documentation

    GitHub issue: #626

    Sanitise peer certificate values we log

    GitHub PR: #623

    Bump dependencies

    GitHub issue: #625

    Do not depend on generated classes for update-secret extension

    GitHub PR: #627

    Source code(tar.gz)
    Source code(zip)
  • v5.8.0.RC2(Sep 17, 2019)

    Changes between 5.7.3 and 5.8.0.RC2

    This is a pre-release for 5.8.0, a maintenance release with a new feature, a usability improvement, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Add support for OAuth 2 authentication

    Documentation

    GitHub issue: #626

    Sanitise peer certificate values we log

    GitHub PR: #623

    Bump dependencies

    GitHub issue: #625

    Do not depend on generated classes for update-secret extension

    GitHub PR: #627

    Source code(tar.gz)
    Source code(zip)
  • v5.8.0.RC1(Sep 12, 2019)

    Changes between 5.7.3 and 5.8.0.RC1

    This is a pre-release for 5.8.0, a maintenance release with new feature, a usability improvement, and dependency upgrades. All users of the 5.x.x series are encouraged to test this version.

    Add support for OAuth 2 authentication

    Documentation

    GitHub issue: #626

    Sanitise peer certificate values we log

    GitHub PR: #623

    Bump dependencies

    GitHub issue: #625

    Source code(tar.gz)
    Source code(zip)
  • v5.7.3(Jul 25, 2019)

    Changes between 5.7.2 and 5.7.3

    This is a patch release with an optional dependency bump to address a vulnerability. All users of the 5.x.x series are encouraged to upgrade to this version.

    The optional dependency affected by the vulnerability is Jackson. The Java client uses this library as a pluggable mapping solution in the JSON RPC support. In the context of the Java client, you are affected by this vulnerability only if you added explicitly Jackson to your dependencies. You must then upgrade Jackson to 2.9.9.1.

    Bump Jackson to 2.9.9.1

    GitHub issue: #621

    Source code(tar.gz)
    Source code(zip)
  • v4.11.3(Jul 25, 2019)

    Changes between 4.11.2 and 4.11.3

    This is a patch release with an optional dependency bump to address a vulnerability. All users of the 4.x.x series are encouraged to upgrade to this version.

    The optional dependency affected by the vulnerability is Jackson. The Java client uses this library as a pluggable mapping solution in the JSON RPC support. In the context of the Java client, you are affected by this vulnerability only if you added explicitly Jackson to your dependencies. You must then upgrade Jackson to 2.9.9.1.

    Bump Jackson to 2.9.9.1

    GitHub issue: #621

    Source code(tar.gz)
    Source code(zip)
  • v5.7.2(Jul 3, 2019)

    Changes between 5.7.1 and 5.7.2

    This is a patch release with a bug fix and upgrades of optional dependencies. All users of the 5.x.x series are encouraged to upgrade to this version.

    ValueWriter.writeFieldValue allows BigDecimals that are too big to be written

    GitHub issue: #617

    Bump optional dependencies (Micrometer, Dropwizard Metrics)

    GitHub issue: #619

    Source code(tar.gz)
    Source code(zip)
  • v4.11.2(Jul 3, 2019)

    Changes between 4.11.1 and 4.11.2

    This is a patch release with a bug fix and upgrades of optional dependencies. All users of the 4.x.x series are encouraged to upgrade to this version.

    ValueWriter.writeFieldValue allows BigDecimals that are too big to be written

    GitHub issue: #617

    Bump optional dependencies (Micrometer, Dropwizard Metrics)

    GitHub issue: #619

    Source code(tar.gz)
    Source code(zip)
A modular and portable open source XMPP client library written in Java for Android and Java (SE) VMs

Smack About Smack is an open source, highly modular, easy to use, XMPP client library written in Java for Java SE compatible JVMs and Android. A pure

Ignite Realtime 2.3k Dec 28, 2022
Java client for NATS

NATS - Java Client A Java client for the NATS messaging system. A Note on Versions This is version 2.x of the java-nats library. This version is a gro

NATS - The Cloud Native Messaging System 454 Jan 4, 2023
A command line client for Kafka Connect

kcctl -- A CLI for Apache Kafka Connect This project is a command-line client for Kafka Connect. Relying on the idioms and semantics of kubectl, it al

Gunnar Morling 274 Dec 19, 2022
CookieClient is a utility client for anarchy servers

CookieClient CookieClient is a utility client for anarchy servers. Its a forge mod so you need forge to run it. Currently supported versions: 1.12.2 D

null 82 Dec 4, 2022
A command line client for Kafka Connect

?? kcctl – Your Cuddly CLI for Apache Kafka Connect This project is a command-line client for Kafka Connect. Relying on the idioms and semantics of ku

kcctl 274 Dec 19, 2022
Event bus for Android and Java that simplifies communication between Activities, Fragments, Threads, Services, etc. Less code, better quality.

EventBus EventBus is a publish/subscribe event bus for Android and Java. EventBus... simplifies the communication between components decouples event s

Markus Junginger 24.2k Jan 3, 2023
Pure Java ZeroMQ

JeroMQ Pure Java implementation of libzmq (http://zeromq.org). Features Based on libzmq 4.1.7. ZMTP/3.0 (http://rfc.zeromq.org/spec:23). tcp:// protoc

The ZeroMQ project 2.2k Jan 9, 2023
Java binding for ZeroMQ

What is JZMQ? This is the Java language binding for libzmq (aka ZeroMQ, 0MQ). The latest javadocs. Building and Installing JZMQ To build you need to h

The ZeroMQ project 577 Dec 11, 2022
A mod for Fabric that ports Bedrock Edition mechanics to Java Edition. 1.16.x

bedrock-mechanics A mod for Fabric that ports Bedrock Edition mechanics to Java Edition. The controller support should be working on any controller by

Pedro Henrique 6 Oct 24, 2021
KC4Streams - a simple Java library that provides utility classes and standard implementations for most of the Kafka Streams pluggable interfaces

KC4Streams (which stands for Kafka Commons for Streams) is a simple Java library that provides utility classes and standard implementations for most of the Kafka Streams pluggable interfaces.

StreamThoughts 2 Mar 2, 2022
Kafka example - a simple producer and consumer for kafka using spring boot + java

Kafka example - a simple producer and consumer for kafka using spring boot + java

arturcampos 1 Feb 18, 2022
Mock for RabbitMQ Java amqp-client

RabbitMQ-mock Mock for RabbitMQ Java amqp-client. Compatible with versions 4.0.0 to 5.9.0 of com.rabbitmq:amqp-client Compatible with versions 3.6.3 t

Fridujo 160 Dec 28, 2022
A JVM library to use RabbitMQ as an embedded service

Embedded RabbitMQ Compatibility: Builds: Linux OS X Windows Reports: Dist: Social: This library allows for the use of various RabbitMQ versions as if

Alejandro Rivera 88 Dec 25, 2021
mall学习教程,架构、业务、技术要点全方位解析。mall项目(40k+star)是一套电商系统,使用现阶段主流技术实现。涵盖了SpringBoot 2.3.0、MyBatis 3.4.6、Elasticsearch 7.6.2、RabbitMQ 3.7.15、Redis 5.0、MongoDB 4.2.5、Mysql5.7等技术,采用Docker容器化部署。

mall学习教程 简介 mall学习教程,架构、业务、技术要点全方位解析。mall项目(40k+star)是一套电商系统,使用现阶段主流技术实现。涵盖了SpringBoot 2.3.0、MyBatis 3.4.6、Elasticsearch 7.6.2、RabbitMQ 3.7.15、Redis 5

macro 11.7k Jan 8, 2023
:herb: 基于springboot的快速学习示例,整合自己遇到的开源框架,如:rabbitmq(延迟队列)、Kafka、jpa、redies、oauth2、swagger、jsp、docker、spring-batch、异常处理、日志输出、多模块开发、多环境打包、缓存cache、爬虫、jwt、GraphQL、dubbo、zookeeper和Async等等:pushpin:

欢迎大家留言和PR~ Tip: 技术更新换代太快,本仓库仅做参考,自己的项目具体使用哪个版本还需谨慎思考~(不推荐使用最新的版本,推荐使用(最新-1|2)的版本,会比较稳定) spring-boot-quick 前言   自己很早就想搞一个总的仓库就是将自己平时遇到的和学习到的东西整合在一起,方便后

wangxc 2.1k Jan 2, 2023
:racehorse:基于SpringBoot + MySQL + Redis + RabbitMQ + Guava开发的高并发商品限时秒杀系统

系统介绍 本系统是使用SpringBoot开发的高并发限时抢购秒杀系统,除了实现基本的登录、查看商品列表、秒杀、下单等功能,项目中还针对高并发情况实现了系统缓存、降级和限流。 开发工具 IntelliJ IDEA + Navicat + Sublime Text3 + Git + Chrome 压测

FINN 2.3k Dec 27, 2022
A lightweight messaging library that simplifies the development and usage of RabbitMQ with the AMQP protocol.

kryo-messaging This library contains a simple MessagingService which simplifies the setup and work with RabbitMQ and the AMQP protocol. Usage Gradle r

Kryonite Labs 3 Jan 10, 2022
EssentialClient is a client side mod originally forked from Carpet Client for 1.15.2 that implements new client side features

EssentialClient EssentialClient is a client side only mod originally forked from Carpet Client for 1.15.2 that implements new client side features. Th

null 62 Jan 3, 2023
This is the src of Badlion client 3.0.0, The reason of this repo is badlion client's owner being p e d o

About Badlion Using Gradle instead of the shit mcp uwu Commands Run with random username gradle startGame Run with another username gradle startGame -

Pace 32 Dec 2, 2022