Fixes https://github.com/spring-projects/spring-integration/issues/3272
* Introduce a `RenewableLockRegistry` since not all `LockRegistry` implementations
provide a way to renew the lease for the lock
* Implement `RenewableLockRegistry` in the `JdbcLockRegistry`
* Test and document the feature
Related to https://build.spring.io/browse/INT-MASTERSPRING40-1129
When there is no other candidates in the cluster, the current `yield()`
will give a leadership to the current active initiator back
Therefore a `revoke()` might not be called at all
* Fir the `RedisLockRegistryLeaderInitiatorTests` to check revoking
after `stop()` instead of `yield()`
* GH-3320: Refine lifecycle control in StdIntFlow
Fixes https://github.com/spring-projects/spring-integration/issues/3320
Turns out that lifecycle control for the whole bunch of components
in one `IntegrationFlow` is useful in fields.
* Change the logic in the `StandardIntegrationFlow` to let to call
`start()` and `stop()` independently how the flow was registered in
the application context.
This way it can be autowired as a `Lifecycle` to let end-user to
avoid the search for proper component in the flow to stop or start
manually - all the components registered with the flow are going
to be stopped or started respectively
* * Add `this.` to class property usage to satisfy Checkstyle
Co-authored-by: Artem Bilan <abilan@vmware.com>
* Fix MessagingGatewaySupport for reactive error
The `onErrorResume()` was in a wrong place for the
`doSendAndReceiveMessageReactive()`: we have to catch all the exceptions
from the top level `Mono`, not only a reply one as it was before.
Ensure in HTTP and WebFlux test that behavior is fixed
**Cherry-pick to `5.3.x` & `5.2.x`**
* * Remove unused imports
Co-authored-by: Artem Bilan <abilan@vmware.com>
Resolves https://github.com/spring-projects/spring-integration/issues/3315
`maxFetchSize` ignored with filters supporting single file filtering (default).
This breaks "fair" rotation with the `RotatingServerAdvice`.
Honor `maxFetchSize`, even with filters that support single file filtering.
**cherry-pick to 5.3.x, 5.2.x**
Fixes https://github.com/spring-projects/spring-integration/issues/3226
* Redis stream message handler support.
* This is the outbound part publishing message to the actual stream using ReactiveStreamOperations
* Addition of more test cases with one using `MessageChannel`.
* Improvements after PR review.
* Removed failed test reading List from a Stream
* Code style clean up
* Remove `rawtypes` usage
* Remove redundant inner classes for test model
* Add `What's New` note
s/Enhancement Proposal/Extension Protocol/
XMPP XEPs are extension protocols of XMPP "core" (i.e., RFC 6120 and
RFC 6121).
See also https://xmpp.org/extensions/xep-0001.html:
"The focal point of the process is a series of protocol specifications
called XMPP Extension Protocols or XEPs."
- merge master branch from old repo (`git-filter-repo`) for src branch
- update build.gradle
- copy docs from Spring for Apache Kafka Chapter
Doc polishing.
Fix http: references in tests.
* Add `What's New` note and fix `polling-consumer.adoc`
not linking to external project any more
* Rename schema
* Upgrade to Gradle 6.3-rc-3 for transitive dependency fix.
* Remove version from schema; polish `build.gradle` to remove unneeded features.
* Added support for header-mapper to outbound-channel-adapter and
outbound-gateway XML
* Follow up on review
* Corrected mistake
* Corrected indentation
Fixes https://github.com/spring-projects/spring-integration-kafka/issues/280
* Refactored to topics/topicPattern to be a property to
prevent constructor telescoping
* Add support for manual partition assignment
- Cleanup after rebasing from #283
- Add additional tests
* Fix checkstyle
* Remove redundant factory methods
* Add better test for static assignment
* Use ConsumerProperties
Fix typo where ContainerProperties was used
instead of ConsumerProperties
* Simplify construction
* Remove unused import
* Use ObjectUtils
* Use component name for clientId
* Collapse static assignment for loop
* Fix lint warning
Starting with version `3.0.x`, the `KafkaInboundGateway` and
`KafkaMessageDrivenChannelAdapter` rely on the
`RetryContext.getRetryCount()` for the
`IntegrationMessageHeaderAccessor.DELIVERY_ATTEMPT` message header, but
the `RetryContext` is obtained from the `TheadLocal` `attributesHolder`,
which is populated from the `RetryListener.open()` only if
`recoveryCallback != null`
* Fix `KafkaInboundGateway` and `KafkaMessageDrivenChannelAdapter` to
populate `TheadLocal` `attributesHolder` with the `RetryContext`
from the `RetryListener.open()` when only `retryTemplate != null`
**Cherry-pick to `master` & 3.0.x**
# Conflicts:
# src/test/java/org/springframework/integration/kafka/inbound/MessageDrivenAdapterTests.java