[INT-1129] Refactor MessageChannelTemplate and gateway classes Created: 06/May/10 Updated: 03/Sep/10 Resolved: 02/Sep/10
|Fix Version/s:||2.0 M7|
|Reporter:||Mark Fisher||Assignee:||Mark Fisher|
|Σ Remaining Estimate:||Not Specified||Remaining Estimate:||Not Specified|
|Σ Time Spent:||Not Specified||Time Spent:||Not Specified|
|Σ Original Estimate:||Not Specified||Original Estimate:||Not Specified|
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.
|Comment by Mark Fisher [ 25/Jul/10 ]|
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).
|Comment by Mark Fisher [ 27/Jul/10 ]|
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).
|Comment by Mark Fisher [ 28/Jul/10 ]|
A major part of this has now been done (for M6), but there are a few things remaining:
1) define a MessageOperations interface (in 'core') with all the send/receive methods of MessagingTemplate
I will create sub-tasks for those.