366 Commits

Author SHA1 Message Date
Oleg Zhurakousky
aabbf2b9cf Fix dependncies in Rabbit core 2025-05-16 18:21:54 +02:00
Oleg Zhurakousky
1d6ab6dda4 Revert "Fix dependncies in Rabbit core"
This reverts commit 82132588a2.
2025-05-16 18:21:37 +02:00
Oleg Zhurakousky
82132588a2 Fix dependncies in Rabbit core 2025-05-14 18:29:57 +02:00
Deyan Yurukov
730ad0a5e5 Removes deprecated DescribeTopicsResult method
Signed-off-by: Deyan Yurukov <deyan.yurukov@gmail.com>
Resolves #3111
2025-04-28 10:17:01 +02:00
Oleg Zhurakousky
c027b43cdd Fix Kafka test 2025-04-16 19:40:53 +02:00
Oleg Zhurakousky
2860d8ca59 GH-3067 Adjust phase of StreamsBuilderFactoryManager
Adjust phase of StreamsBuilderFactoryManager to be lower than WebServerGracefulShutdownLifecycle

Resolves #3067
2025-04-14 08:35:04 +02:00
Oleg Zhurakousky
d9d8c399ac Fix formatting 2025-04-11 13:22:50 +02:00
Oleg Zhurakousky
da4d4c5b46 GH-3086 Define explicit defineInput/Output binding methods
Also changed signature to return properties for convinience
Added test
2025-04-04 15:22:42 +02:00
Oleg Zhurakousky
51f7f0c3cc GH-3104 fix formatting 2025-03-27 17:04:33 +01:00
Oleg Zhurakousky
9c65477bae GH-3104 Add JsonGetter to show SpEL expression as String
This is specifically done for actuator binding endpoint to avoid type conversion

Resolves #3104
2025-03-27 16:48:18 +01:00
spring-builds
249f68ce1f Bumping dependency versions after release 2025-03-18 22:21:30 +00:00
spring-builds
768c7b0ee4 Bumping versions to 4.2.2-SNAPSHOT after release 2025-03-18 22:20:17 +00:00
spring-builds
aefe1689d8 Going back to snapshots 2025-03-18 22:20:16 +00:00
spring-builds
9fc527da2f Update SNAPSHOT to 4.2.1 2025-03-18 22:16:59 +00:00
DidierLoiseau
463ca2269b Fixes: #3066
Issue link: https://github.com/spring-cloud/spring-cloud-stream/issues/3066

Signed-off-by: DidierLoiseau <didierloiseau+github@gmail.com>
2025-03-10 17:22:51 -04:00
akenra
9a311e1707 fix(kafka-topic-provisioner): Prevent resource leak on binding producer to KafkaMessageChannelBinder
- Producer that fetches partition info now initializes within a try-with-resources block
- If exceptions occur on calling producer.partitionsFor(topicName), it's now properly closed and resources are released

Signed-off-by: akenra <37288280+akenra@users.noreply.github.com>
2025-03-07 13:38:02 -05:00
spring-builds
dc164fe3c0 Bumping versions 2025-02-11 17:34:51 +00:00
spring-builds
dc3669bfcf Going back to snapshots 2025-01-30 03:00:53 +00:00
spring-builds
4edccc3b56 Update SNAPSHOT to 4.3.0-M1 2025-01-30 02:58:18 +00:00
spring-builds
fcd7cba51d Bumping versions 2025-01-18 15:09:52 +00:00
Soby Chacko
8954aaf336 Bumping next version to 4.3.0-SNAPSHOT 2025-01-17 11:06:07 -05:00
Oleg Zhurakousky
70b8037966 Merge pull request #3064 from artembilan/GH-3062
GH-3062: Fix `KafkaBinderMetrics` for resource leaks
2025-01-08 11:25:10 +01:00
Oleg Zhurakousky
534277ff3d GH-3065 Fix lazy initialization for Kafka streams configuration classes
Resolves #3065
2025-01-06 15:07:27 +01:00
Artem Bilan
90afffb273 GH-3062: Fix KafkaBinderMetrics for resource leaks
Fixes: https://github.com/spring-cloud/spring-cloud-stream/issues/3062

The `KafkaBinderMetrics` creates `KafkaConsumer` instances and schedule the fix rate
task for them, but never closes them even when the `scheduler` is shut downed

* Implement a `Lifecycle` contract in the `KafkaBinderMetrics` and call `close()`
from the `stop()` to satisfy CRaC resource management expectations.
* Also close all the `KafkaConsumer` instances from the `metadataConsumers`

**Cherry-pick to `4.1.x`**
2025-01-03 14:43:28 -05:00
Oleg Zhurakousky
ad2a654160 GH-3055 Polish 2024-12-12 14:27:58 +01:00
Oleg Zhurakousky
e8bed37161 GH-3055 Add BinderHeaderMapper to reactive Kafka binder
Resolves #3055
2024-12-12 13:49:36 +01:00
Oleg Zhurakousky
2f9be858d7 GH-3055 Add additional types for toString() serialization
Add additional types for toString() serialization to Kafka's  to ensure propper serialization/deserialization of message header values.

Resolves #3055
2024-12-11 13:08:41 +01:00
Oleg Zhurakousky
4fb9a16c99 Fix tests after Observation feature was added to StreamBridge 2024-12-09 15:48:59 +01:00
Agustino Lim
a88c34fc9f GH-3033: Register ObservationRegistry for Dynamic MessageChannels
Fixes: gh-3033

* ensure `ObservationRegistry` is registered on dynamically created `MessageChannel` instances in `StreamBridge`
2024-12-04 13:13:20 +01:00
spring-builds
2aa8d495cd Bumping dependency versions after release 2024-12-03 00:23:06 +00:00
spring-builds
f1e6c87814 Bumping versions to 4.2.1-SNAPSHOT after release 2024-12-03 00:21:56 +00:00
spring-builds
f03ea2582a Going back to snapshots 2024-12-03 00:21:54 +00:00
spring-builds
b26353cfcc Update SNAPSHOT to 4.2.0 2024-12-03 00:18:38 +00:00
Artem Bilan
a9fe0c2c3c GH-3040: Add virtual threads customizer for RabbitMQ binder
Fixes: #3040
Resolves #3041

This change adds out-of-the-box `ListenerContainerCustomizer<AbstractMessageListenerContainer>`
to set `VirtualThreadTaskExecutor` into an `AbstractMessageListenerContainer` created by the binder
when `Threading.VIRTUAL` condition is met
2024-11-18 12:10:49 +01:00
spring-builds
1b083c943e Going back to snapshots 2024-11-08 01:39:01 +00:00
spring-builds
34798150d8 Update SNAPSHOT to 4.2.0-RC1 2024-11-08 01:36:20 +00:00
Soby Chacko
8b6b1271ef GH-3024: Add logging for exceptions in KafkaTopicProvisioner
Related to https://github.com/spring-cloud/spring-cloud-stream/issues/3024
2024-10-24 15:02:50 -04:00
Oleg Zhurakousky
12468dcd0a Fix checkstyles 2024-10-21 17:57:07 +02:00
Artem Bilan
c96a62f163 GH-2939: Rely on custom AmqpHeaders.RETRY_COUNT for server retries
Fixes: https://github.com/spring-cloud/spring-cloud-stream/issues/2939

The RabbitMQ 4.0 does not deal with client side `x-*` headers.
Therefore, an `x-death.count` is not incremented anymore when
message is re-published from client back to the broker.

* Spring AMQP 3.2 has introduced an `AmqpHeaders.RETRY_COUNT` custom header.
Use `messageProperties.incrementRetryCount()` in the `RabbitMessageChannelBinder`
when we re-published message back to the broker for server-side retries
* Fix docs respectively

Resolves #3019
2024-10-17 12:00:11 +02:00
Soby Chacko
bf9ea9e626 Fix Rabbit binder compiliation issues 2024-10-14 14:19:45 -04:00
buildmaster
a81fb04286 Going back to snapshots 2024-10-08 01:06:11 +00:00
buildmaster
67d4d34a58 Update SNAPSHOT to 4.2.0-M2 2024-10-08 01:03:40 +00:00
Oleg Zhurakousky
559d49381f Merge pull request #3017 from omercelikceng/codecleanupp
Code Cleanup - StringBuilder, Redundant Iteration,  Record
2024-10-07 18:44:05 +02:00
Oleg Zhurakousky
eea905f692 Merge pull request #3015 from sobychacko/gh-2985
GH-2985: Add Kafka Listener Container Customizer interfaces and docum…
2024-10-07 18:43:26 +02:00
Ömer Çelik
cbfd3aa995 Change "synchronized" to reentrant lock for virtual-threads
Fix checkstyles before merge

Code cleanup

Double-Checked Locking Optimization was used to avoid unnecessary locking overhead.
2024-10-07 18:40:51 +02:00
Soby Chacko
06040728cc Cleanup spring-kafka dependency version. 2024-10-07 10:21:27 -04:00
Ömer Çelik
e445a34f8d Code Cleanup - StringBuilder, Redundant Iteration, Record 2024-10-05 01:32:15 +03:00
Soby Chacko
f8d6caa429 GH-2985: Add Kafka Listener Container Customizer interfaces and documentation
Resolves https://github.com/spring-cloud/spring-cloud-stream/issues/2985

This commit introduces new customization options for Kafka listener containers
in Spring Cloud Stream, along with comprehensive documentation:

- Add KafkaListenerContainerCustomizer interface for Kafka-specific customization
  with access to extended consumer properties
- Extend ListenerContainerWithDlqAndRetryCustomizer to include access to
  extended consumer properties
- Update KafkaMessageChannelBinder to support the new customizer interfaces
- Implement KafkaListenerContainerCustomizerTests for integration testing
- Add detailed AsciiDoc reference documentation explaining the purpose,
  usage, and hierarchy of these customizer interfaces:
  * ListenerContainerCustomizer (existing)
  * KafkaListenerContainerCustomizer (new)
  * ListenerContainerWithDlqAndRetryCustomizer (extended)
- Update navigation to include the new documentation

These changes enhance the flexibility and configurability of Kafka consumer
endpoints in Spring Cloud Stream applications, allowing users to fine-tune
their listener containers based on specific requirements and scenarios,
with improved access to Kafka-specific properties.
2024-10-04 17:53:13 -04:00
Oleg Zhurakousky
6f9809eba1 Fix depreactions 2024-09-27 16:41:56 +02:00
Andy Wilkinson
b7f2f1bb2d Support Spring Boot's KafkaConnectionDetails for Kafka connections
- Integrate KafkaConnectionDetails, a Spring Boot component, in binder
- Update KafkaBinderConfigurationProperties to use KafkaConnectionDetails
- Modify KafkaTopicProvisioner to leverage KafkaConnectionDetails
- Adjust Kafka binder configurations to pass KafkaConnectionDetails
- Update tests to accommodate KafkaConnectionDetails changes
- Add KafkaConnectionDetails to shared.beans for auto-configuration

This change improves flexibility in configuring Kafka connections,
allowing for better support of externalized configuration management
and aligning with Spring Boot's connection abstraction model.
2024-09-24 16:53:08 -04:00