Commits on Jan 16, 2018
  1. Improve Test Run Times

    garyrussell committed with artembilan Jan 16, 2018
    - Reduce container `receiveTimeout` so containers stop faster
    - Remove unnecessary `Thread.sleep()`s
    Reduced runtime from 5'26'' to 3'11'' on my machine.
Commits on Jan 2, 2018
  1. Doc Copyright 2018

    garyrussell committed Jan 2, 2018
Commits on Dec 26, 2017
  1. Fix Race in DMLC Events test

    garyrussell committed Dec 26, 2017
    ConsumeOkEvent introduced a race condition into the test.
Commits on Dec 21, 2017
  1. Fix JUnit dependencies

    garyrussell committed with artembilan Dec 21, 2017
    - eliminate the `platform-commons` dependency
    - make the `jupiter-api` dependency optional
Commits on Dec 20, 2017
  1. AMQP-791: Support JUnit5

    garyrussell committed with artembilan Dec 20, 2017
    - refactor `BrokerRunning` JUnit4 `@Rule` so it can be invoked from an `ExecutionCondition`.
    - Add `@RabbitAvailable` annotation with queue list and auto-delete queues at the end of the class; purge them between tests.
    * Implement `ParameterResolver` to access the rule's connection factory.
    * Support CTOR Injection and `BrokerRunning` Injection
    - user might want to invoke methods such as `deleteQueues()`.
    * Patches omitted from previous commit
    * WIP - Spring
    * Polishing - PR Comments
    * Convert `RabbitTemplateMPPIntegrationTests` - JUnit5
    * Remove bogus test
    * Docs + `@LongRunning`
    * Polishing - PR Comments
  2. Bump HOP Version to 1.3.1.RELEASE

    garyrussell committed Dec 20, 2017
    Fixes a content-type problem when running with a 3.7 broker.
Commits on Dec 19, 2017
  1. AMQP-793: Exception on ack for closed Channel

    garyrussell committed with artembilan Dec 19, 2017
    Throw an exception to the caller when attempting to ack/nack a
    message on a closed channel.
Commits on Dec 18, 2017
  1. AMQP-794: CRErrorHandler: Traverse cause tree

    garyrussell committed with artembilan Dec 18, 2017
    In the `ConditionalRejectingErrorHandleri.DefaultExceptionStrategy`,
    if the `cause` of the `ListenerExecutionFailedException` is a `MessagingException`,
    traverse the `cause` tree to find the root cause of all such exceptions unless
    it's a fatal cause itself (`MethodArgumentResolutionException` or `MessageConversionException`).
    The final fatal check is performed on the root cause.
  2. AMQP-788 Add delegate publisher connection factory

    garyrussell committed with artembilan Dec 13, 2017
    To avoid deadlocks, it is best to use a different connection for producers and
    consumers (unless the producer is partiticipating in a consumer transaction).
    - Add a delegate `publisherConnectionFactory` to the `CachingConnecetionFactory`.
    - Use the same underlying `com.rabbitmq.client.ConnectionFactory` in each.
    - Propagate all properties to the delegate.
     - Except, enhance the connection name and bean name with `.publisher`.
    - Add a boolean `usePublisherConnection` to the `RabbitTemplate`.
     - If true, use `createPublisherConnection()` when appropriate.
    Polishing - PR Comments
    Polishing - More PR Comments and Fix doSendAndReceiveWithDirect() to use the publishing CF.
    More polishing; tests + reinstate overloaded execute().
    Fix (old) race condition in testReceiveAndReplyNonBlocking.
Commits on Dec 12, 2017
  1. AMQP-790: Fix after receive MPPs with send/receive

    garyrussell committed with artembilan Dec 5, 2017
    Previously, `afterReceivePostProcessors` were not called on `sendAndReceive()`
Commits on Dec 1, 2017
  1. More Sonar Polishing

    garyrussell committed Dec 1, 2017
    False positive is not only false; it's reported on the wrong line.
  2. Fix Sonar false positives

    garyrussell committed Dec 1, 2017
Commits on Nov 28, 2017
Commits on Nov 27, 2017
  1. AMQP-785: SMLC Lifecycle fixes

    garyrussell committed with artembilan Nov 21, 2017
    Fixes: spring-projects/spring-amqp#689
    - Only stop the container on one thread
    - Ignore concurrent stops
    - Interrupt consumer threads that are attempting to declare queues
    - In `restart()` don't start a new consumer if the container is stopping
    - Defer publishing consumer failure events until container is stopped
    - Add a RecoveryListener if needed to ensure channels are never recovered
    - Fix event publishing for `Error` - it is fatal
    __backport to 1.7.x will require work__
    Clear the declaring flag when exiting `start()` with exception.
    Release the `activeObjectCounter` when interrupted while declaring.
    Polishing stopped container lifecycle
    Since restarted consumer is not be aware about stopped container,
    it can restart properly when RabbitMQ comes back on-line independently
    of the container state
    * Add `active` flag to the `ActiveObjectCounter` and `deactivate()`
    and `isActive()` hooks
    * Use `ActiveObjectCounter.deactivate()` in the container shutdown
    * Use `ActiveObjectCounter.isActive()` in the
    * Use `BlockingQueueConsumer.cancelled()` in its `start()` toi check
    container activity before performing network job
    * Check `isActive()` state in the `AbstractMessageListenerContainer.shutdown()`
    * Remove `SimpleMessageListenerContainer.containerStopping` in favor of
    `isActive()` hook
    * Upgrade to SF-5.0.2, Retry-1.2.1, Mockito-2.11.0
Commits on Nov 18, 2017
  1. Fix Event Test

    garyrussell committed Nov 18, 2017
    Previous commit added more events but the test latch wasn't adjusted to suit.
Commits on Nov 17, 2017
  1. AMQP-776: More Consumer Events

    garyrussell committed with artembilan Nov 17, 2017
    Publish an event when a consumer successfully consumes from a queue.
    Publish an event when an SMLC listener throws an `Error`.
    Doc polishing.
    Update minimum client version in docs; remove reference to broker version
    since that's no longer linked to the client.
    __cherry-pick to 1.7.x (minus DMLC change)__
  2. AMQP-784: Fix multi method @RabbitListener

    garyrussell committed with artembilan Nov 17, 2017
    When looking for matching methods, we matched on no annotation or @Payload.
    Match should have been no annotation(s) or not @Header.
    __cherry-pick to 1.7.x__
Commits on Nov 9, 2017
  1. AMQP-780: Configurable consumer start timeout

    garyrussell committed with artembilan Nov 9, 2017
    Log an error if a consumer doesn't start within the timeout; make the timeout configurable.
    This can happen if the task executor doesn't have enough threads to support the concurrency.
    __cherry-pick to 1.7.x__
Commits on Nov 6, 2017
  1. AMQP-779: User correlationId with reply container

    garyrussell committed with artembilan Nov 6, 2017
    Allow the use of a user-supplied `correlationId` instead of one
    generated by the `RabbitTemplate`.
    It is the user's responsibility to ensure uniqueness.
    * Docs
Commits on Oct 31, 2017
  1. Log Connection Attempts

    garyrussell committed with artembilan Oct 31, 2017
    In many complex environments e.g. boot properties, cloud connectors, 
    environment overrides etc. it can be difficult to debug connection problems.
    Add INFO logs with configured broker address(es) before connecting.
    __cherry-pick to 1.7.x__
    * Fix tests - additional interactions with mocks for log messages.
Commits on Sep 28, 2017
Commits on Sep 27, 2017
  1. Fix Test Case

    garyrussell committed Sep 27, 2017
    - early exit from while loop was incorrect; need to wait until the consumer has changed.
  2. Revert Previous Commit

    garyrussell committed Sep 27, 2017
    This reverts commit c54cd43.
Commits on Sep 26, 2017
  1. AMQP-772: Container MPP - Discard Message

    garyrussell committed with artembilan Sep 26, 2017
    If an `afterReceivePostProcessor` in the listener container configuration
    returns `null`, discard the message.
Commits on Sep 11, 2017
  1. Fix NOTE Block; Clarify @RabbitListener Config

    garyrussell committed with artembilan Sep 11, 2017
    See just above here:
    Block terminator uses - instead of =.
    Also add a note about PP and SpEL.
    __cherry-pick to 1.7.x__
Commits on Sep 6, 2017
  1. AMQP-766: Deserialization in Message.toString()

    garyrussell committed with artembilan Sep 6, 2017
    Add white list for classes/packages that can be deserialized in Message.toString().
    __cherry-pick to 1.7.x, 1.6.x, 1.5.x__
    * Polishing - checkstyle and PR Comments
Commits on Sep 1, 2017
  1. AMQP-762: Reliably Release Channel Checkout Permit

    garyrussell committed with artembilan Aug 22, 2017
    When using `channelCheckoutTimeout` to limit channels, if a permit was acquired
    but a channel not actually created (e.g. because the broker is down), the permit
    was not released.
    Add a try catch around `getCachedChannelProxy()` and release the permit.
    * Fix conflicts and typos
    # Conflicts:
    #	spring-rabbit/src/test/java/org/springframework/amqp/rabbit/listener/
  2. AMQP-765: Suppress Exception on Deferred Close

    garyrussell committed with artembilan Aug 25, 2017
    When confirms/returns are enabled we defer the close; suppress
    the logged exception if a normal `ShutdownSignalException` is thrown.
  3. AMQP-764: Move Setting stopped to destroy()

    garyrussell committed with artembilan Aug 24, 2017
    Fixes #651
    Previously, `stopped` was set in `stop()` after the context was closed.
    This was done to prevent inadvertent re-opening of the connection which
    would prevent the application from terminating.
    This was too early since other beans destroyed before the factory might
    need to send messages.
    Remove `Smartlifecycle` and move setting `stopped` to `destroy()`, but
    still only after the context is closed; since `destroy()` can be called
    by users to reset the connection (although `resetConnection()` is now the
    preferred way to do that.
Commits on Aug 21, 2017
  1. checkstyle fix

    garyrussell committed Aug 21, 2017
Commits on Aug 17, 2017
  1. Remove Bogus DEBUG log.

    garyrussell committed with artembilan Aug 17, 2017
    "Queue with name that starts with 'amq.' cannot be declared." logged unconditionally.
    Cherry-pick to 1.6.x, 1.7.x
Commits on Jul 15, 2017
  1. Fix Race in ContainerShutDownTests

    garyrussell committed with artembilan Jul 15, 2017
    It is possible the template's channel is returned to the cache before the container starts.
    In that case, the container gets that channel and there's only one insted of two.
    Also add a consumer started event to the DMLC, which was missing.
Commits on Jul 3, 2017
  1. Remove AMListenerContainer.getRequiredQueues()

    garyrussell committed Jul 3, 2017
    No longer needed since we now allow the container to start without a queue.
Commits on Jun 27, 2017