You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Refactor MessageChannelTemplate and gateway classes [INT-1129] #5137
We might want to simplify the AbstractMessagingGateway to rely more upon the MessageChannelTemplate (and we might want to rename it to "MessagingGatewaySupport"?).
To be consistent with other template (e.g. JMS), it would actually make sense to have the methods that accept Objects within the template (rather than requiring Messages), i.e. we could have the equivalent of "sendAndConvert" but delegating to MessageMapper implementations (inbound for send, outbound for receive) instead.
We should rename the template (big change, but this is 2.0 and therefore a good chance to get it right) to "MessagingTemplate". We should also create a "MessagingOperations" interface. The convertAndSend/receiveAndConvert methods should all be moved to the template. All of this will make it much more consistent with other Spring templates (such as JmsTemplate and AmqpTemplate).
Also (another big change), for the sake of consistency (see JMS Template) we should probably use: send(channel, message) as opposed to send(message, channel).
A major part of this has now been done (for M6), but there are a few things remaining:
define a MessageOperations interface (in 'core') with all the send/receive methods of MessagingTemplate
add ChannelResolver-awareness to MessagingTemplate and then add convertAndSend/receiveAndConvert methods
Refactor "gateway" classes to use MessagingTemplate directly as necessary (potentially removing the AbstractMessagingGateway/SimpleMessagingGateway and instead providing just convenient template access in MessagingGatewaySupport)
Activity
spring-operator commentedon Jul 25, 2010
Mark Fisher commented
We should rename the template (big change, but this is 2.0 and therefore a good chance to get it right) to "MessagingTemplate". We should also create a "MessagingOperations" interface. The convertAndSend/receiveAndConvert methods should all be moved to the template. All of this will make it much more consistent with other Spring templates (such as JmsTemplate and AmqpTemplate).
spring-operator commentedon Jul 27, 2010
Mark Fisher commented
Also (another big change), for the sake of consistency (see JMS Template) we should probably use: send(channel, message) as opposed to send(message, channel).
spring-operator commentedon Jul 28, 2010
Mark Fisher commented
A major part of this has now been done (for M6), but there are a few things remaining:
I will create sub-tasks for those.