RabbitMQ Stream Queue Support

版本 6.0 引入了对 RabbitMQ 流队列的支持。 这些端点的 DSL 工厂类是 RabbitStream

RabbitMQ Stream Inbound Channel Adapter

@Bean
IntegrationFlow simpleStream(Environment env) {
	return IntegrationFlow.from(RabbitStream.inboundAdapter(env).streamName("my.stream"))
			// ...
			.get();
}

@Bean
IntegrationFlow superStream(Environment env) {
	return IntegrationFlow.from(RabbitStream.inboundAdapter(env).superStream("my.super.stream", "my.consumer"))
			// ...
			.get();
}

RabbitMQ Stream Outbound Channel Adapter

@Bean
IntegrationFlow outbound(Environment env) {
    return f -> f
            // ...
            .handle(RabbitStream.outboundStreamAdapter(env, "my.stream"));

}