Hi,
we are in the process of migrating to spring-integration 2. In that process we are trying to make things easier than they are at the moment. One of the possible candidates to improve in the routing part. At the moment we have code like this:
The router is a very basic implementation:Code:<si:router input-channel="docTypeChannel" ref="docTypeRouter" method="resolveObjectTypeChannel"/> <si:channel id="News"/> <si:channel id="PressRelease"/> <si:channel id="Faq"/> <si:channel id="Address"/> <si:channel id="PB51Publication"/> <si:channel id="LeadingPage"/> <si:channel id="Bill"/> <si:channel id="CountryInformation"/> <si:channel id="TravelAdvice"/> <si:channel id="Webpage"/> <si:channel id="Delete"/>
Now I would like to replace this with the existing payload type message router. If I understand well, I do need to provide a mapping between type and channel myself, would be nice if there could be a default resolving strategy like:Code:public String resolveObjectTypeChannel(Message message) { return message.getPayload().getClass().getSimpleName(); }
- fully qualified class name
- simple class name
- custom mappings
Am I wrong and is this possible?
thanks,
Jettro


Reply With Quote