Hi Vivian, maybe you can define your own marshaler to extract content and format as you want, can't you ?
Regards JB -- Jean-Baptiste Onofré [email protected] BuildProcess/AutoDeploy Project Leader http://buildprocess.sourceforge.net On Tue 07/07/09 14:46, "Madesclair Vivian" [email protected] wrote: > Anyone has any insights about this? The fact that it removes my tag is > quite annoying a behavior. > Best regards, > Vivian > > > -----Message d'origine----- > De : Madesclair Vivian [vm > [email protected]] Envoyé : vendredi 3 juillet 2009 11:04 > À : u > [email protected] Objet : Servicemix adding and removing <DEFANGED_META> tags in > messages > Hello, > > I am working on a SA that receive HTTP post requests and send emails with > the content of the request. The content is HTML, and I have to encode it in > UTF-8 (otherwise special characters raise exception in smx). The issue I > got, is that the mail I receive are not decoded and still in plain > UTF-8. > It seems that smx is adding <DEFANGED_META> tag to the message (I > know that because I looked at the debug output). So when I put myself a > <DEFANGED_META> in my html stating that this is UTF-8, the message in > smx contains 2 <DEFANGED_META> (stating the same thing). Finally, > when the message is given to the mail component, these two tags are removed > and not send in the email. > I don't really get it. Why is servicemix modifying the initial > message? I thought it should only work on the JBI wrappers... Which by the way seem > absent here. See ressources provided at the end of the mail. > And also, if the message I send is not xml-like but plain text, servicemix > throw an exception (I don't remember what it says though). > Regards, > Vivian > > > My HTTP consumer bean : > <http:consumer service="httpMailService" > endpoint="httpMail" > targetService="MailService" > targetEndpoint="senderEndpoint" > locationURI="http://0.0.0.0:8192/jbi/Mail/" /> > Mail received : > <html> > > <head> > > > </head> > <DEFANGED_body>Bonjour%2C+%0A%0AVoici+le+r%C3%A9capitulatif+de+votre+ > r%C3%A9serva tion+%3A%0ANombre+de+voyageurs+%3A2%0AVol+Aller+%3A+Le+01%2F07%2F2009+de +Toulouse+%C3%A0+Paris+%3A+%0A%09Air+France+-+No+%3A+25457+-+09%3A50%0A% 0AVol+Retour+%3A+Le+10%2F07%2F2009+de+Paris+%C3%A0+Toulouse+%3A+%0A%09+A ir+France+-+No+%3A+7892+-+07%3A35%0A%0AA+bientot+sur+VoyageSopra.com+%21 </body> > > </html> > > Extract of the log : > 10:37:49,252 | DEBUG | pool-flow.seda.servicemix-mail-thread-11 | > SedaQueue | .jbi.nmr.flow.seda.SedaQueue$1 132 | > org.apache.servicemix.jbi.nmr.flow.seda.sedaqueu...@a96eba > dequeued exchange: InOut[ > id: ID:172.31.196.135-1223f9b50e0-2:3 > status: Done > role: provider > service: MailService > endpoint: senderEndpoint > in: <html> > > <head> > <DEFANGED_META http-equiv="Content-Type" content="text/html; > charset=UTF-8"> <DEFANGED_META content="text/html; charset=UTF-8" > http-equiv="Content-Type"> </head> > <DEFANGED_body>Bonjour%2C+%0A%0AVoici+le+r%C3%A9capitulatif+de+votre+ > r%C3%A9serva tion+%3A%0ANombre+de+voyageurs+%3A2%0AVol+Aller+%3A+Le+01%2F07%2F2009+de +Toulouse+%C3%A0+Paris+%3A+%0A%09Air+France+-+No+%3A+25457+-+09%3A50%0A% 0AVol+Retour+%3A+Le+10%2F07%2F2009+de+Paris+%C3%A0+Toulouse+%3A+%0A%09+A ir+France+-+No+%3A+7892+-+07%3A35%0A%0AA+bientot+sur+VoyageSopra.com+%21 </body> > > </html> > > out: <?xml version="1.0" encoding="UTF-8"?><ack/> ] > 10:37:49,268 | DEBUG | pool-flow.seda.servicemix-mail-thread-11 | > MailComponent | emix.common.AsyncBaseLifeCycle 561 | > Received exchange: status: Done, role: provider > > >
