Да, просто добавьте новые привязки:
bindings:
input:
destination: topic1
content-type: application/*+avro
inputStream1:
destination: topic_input_1
inputStream2:
destination: topic_input_2
output:
destination: topic2
content-type: application/*+avro
output2:
destination: output_topic_2
И предоставьте EnableBinding и другие дополнительные аннотации, такие как StreamListener:
@EnableBinding(MultipleDesBinding.class)
public class YourApplication {
@StreamListener
@SendTo("output")
public KStream<String, String> topology1(@Input("inputStream") KStream<String, String> inputKStream,
@Input("inputStream1") KStream<String, String> inputStream1KStream) {
}
@StreamListener
@SendTo("output2")
public KStream<String, Long> topology2(@Input("inputStream2") KStream<String, String> inputStream2KStream) {
}
}
interface MultipleDesBinding {
@Input("input")
KStream<?, ?> input();
@Input("inputStream1")
KStream<?, ?> inputStream1();
@Input("inputStream2")
KStream<?, ?> inputStream2();
@Output("output")
KStream<?, ?> output();
@Output("output2")
KStream<?, ?> output2();
}
Подробно вы можете посмотреть в документе: Модель императивного программирования .