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 Option to Not Create an Output Binding for the RoutingFunction #2168
Comments
But I see that it is needed if at least one of the delegates is a function: @Bean
Function<Message<?>, String> foo() {
return msg -> {
System.out.println("foo: " + msg);
return "FOO";
};
} So we probably need a new property to suppress it; I don't see how we could deterministically deteverifyrmine that all delegates are |
As a work around simply point it to the same destination
Since the delegates are all |
So if I understand correctly. . .
However, and that is what I believe you're saying is that the fact that RoutingFunction is a function it automatically creates an output binding even though there will never be an output. |
Exactly, yes. I don't see how we can programmatically detect that the function never routes to another function (only
By the way, the docs talk about |
I see. . . need to think. I really don't want to introduce another property, precisely for the same reason that you just mentioned as it may crate confusion. |
Ok, it appears that it can work. Just spiked it up and all tests are passing Basically the idea is to never create output binding for Will sleep on it and merge tomorrow |
See https://stackoverflow.com/questions/67419839/spring-cloud-stream-functionrouter-output-attempts-to-bind-to-kafka-topic
Verified when destination functions are all
Consumer
s.The text was updated successfully, but these errors were encountered: