Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for binder customizers #186

Merged
merged 2 commits into from
Jan 5, 2021
Merged

Add support for binder customizers #186

merged 2 commits into from
Jan 5, 2021

Conversation

meltsufin
Copy link
Member

ConsumerEndpointCustomizer<PubSubInboundChannelAdapter> and ProducerMessageHandlerCustomizer<PubSubMessageHandler> user beans can now be provided to customize the Pub/Sub binder.

Fixes: #182.

`ConsumerEndpointCustomizer<PubSubInboundChannelAdapter>` and `ProducerMessageHandlerCustomizer<PubSubMessageHandler>` user beans can now be provided to customize the Pub/Sub binder.

Fixes: #182.
@sonarcloud
Copy link

sonarcloud bot commented Dec 29, 2020

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

Copy link
Contributor

@elefeint elefeint left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Optional test question.

@Test
public void testProducerAndConsumerCustomizers() {
baseContext.withUserConfiguration(PubSubBinderTestConfig.class)
.withPropertyValues("spring.cloud.stream.bindings.input.group=testGroup")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test relies on a lot of internal Spring Cloud Stream implementation details. Would it be easier to retrieve the adapter/message source by name? Or customize ACK method and verify that instead of verifying the name?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be possible, but I simply followed the test design for Kafka binder.

@meltsufin meltsufin merged commit b9af4f7 into master Jan 5, 2021
@meltsufin meltsufin deleted the binder-customizers branch January 5, 2021 16:11
kateryna216 added a commit to kateryna216/spring-cloud-gcp that referenced this pull request Oct 20, 2022
`ConsumerEndpointCustomizer<PubSubInboundChannelAdapter>` and `ProducerMessageHandlerCustomizer<PubSubMessageHandler>` user beans can now be provided to customize the Pub/Sub binder.

Fixes: GoogleCloudPlatform#182.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ability to provide ConsumerEndpointCustomizer for PubSubMessageChannelBinder
3 participants