Hi everyone. First of all, I'd like to make clear that I understand how powerful both ServiceMix and Camel are, and that my case is probably a particular scenario where using Camel in ServiceMix may not be a good idea. I'd just like to know if I'm missing something out to integrate both together.
I've been using ServiceMix for quite some time, and a few days ago I thought on using Camel for routing and designing some EIPs in my project. The problems have come when I've started implementing these routes, that have made me think if, in my case, it's a good idea to be using Camel. I explain: I'm using various JBI components inside the ESB, that communicate using the standard JBI MessageExchange. If I try to use Camel to process any of these exchanges I lose the advantages of processing a JBI exchange. For example, as I'm using XMLBeans, I've been using the DOMSource along the whole project to process the messages, but now Camel won't let me. The next problem comes when I send the message back from Camel to the ESB: as I haven't sent a DOMSource, I will have problems processing the message when it comes back to ServiceMix. Is it worth the hassle of changing from one exchange to another just to process a message? Also, as my processing operations in Camel are quite complex, I need to be using DSL. So I don't really notice the difference between using Camel to process the message or send the message to a Bean endpoint, process it in Java in the bean, and send it to the destination endpoint. What are the disadvantages of my alternative? Probably, the best solution would be to implement a Camel2JBIExchangeConverter or similar, but it doesn't look that easy. I miss quite a few properties of the JBI MessageExchange in the Camel Exchange. Obviously, for routing without message processing (eg. wiretapping), Camel is working great inside SM, so I'm sure I'll use it anyway, but I don't know if I should start processing in the Bean component. What do you guys think about this? Best regards. Sebastian Gomez. P.D: Hope no one gets annoyed about sending this mail to both Camel and ServiceMix mailing-lists.
