GH-3194: Add generics to Amqp and Jms channel impls
Fixes https://github.com/spring-projects/spring-integration/issues/3194 For now we keep the hierarchy, but try to generalize channel specs a bit, so that ones who use `publishSubscribeChannel` can count on `BroadcastCapableChannel` as interface to utilize.
This commit is contained in:
committed by
GitHub
parent
a8430c12a6
commit
d75dd095a3
@@ -83,6 +83,7 @@ import org.springframework.transaction.PlatformTransactionManager;
|
||||
* @author Artem Bilan
|
||||
* @author Gary Russell
|
||||
* @author Nasko Vasilev
|
||||
* @author Artem Vozhdayenko
|
||||
*
|
||||
* @since 5.0
|
||||
*/
|
||||
@@ -371,8 +372,7 @@ public class JmsTests extends ActiveMQMultiContextTests {
|
||||
|
||||
@Bean
|
||||
public BroadcastCapableChannel jmsPublishSubscribeChannel() {
|
||||
// TODO reconsider target generic type for channel implementation to return from this kind of specs
|
||||
return (BroadcastCapableChannel) Jms.publishSubscribeChannel(jmsConnectionFactory())
|
||||
return Jms.publishSubscribeChannel(jmsConnectionFactory())
|
||||
.destination("pubsub")
|
||||
.get();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user