on 03-22-2007 4:26 PM
I am currently facing the following problem:
I have to integrate a scenario using email as communication protocol (both in and outbound).
On the outbound way I know what I am getting, so this is no problem.
On the inbound way though I am facing one huge problem:
I am using a module that needs the source attachment name to do its job.
But as I am receiving emails, this source attachment name can be "MailMessage" if someone sends the content inlined or "MailAttachment-1" if someone sends the content attached.
As I am using one channel to poll a mailbox where basically both these situations can occur, I am looking for a means to use either MailMessage OR MailAttachment-1, depending on what is present.
So far I only know of ways to hard code the source attachment which will cause the cc to fail forever if a wrong message hits the inbox.
I have thought of a workaround, polling the messages from the mailbox without using any module chain, sending them to a file receiver and picking them up again with a file sender that has "archive errorneous messages" set. But this does not look like a nice solution to me at all.
Any ideas how to solve that are highly welcomed!
Thanks and cheers!
Stefan
Hi Stefan,
Try to have a look to my blog:
/people/francesco.bersani/blog/2007/03/27/rename-attachment-adapter-module
Hope this help
Francesco
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Francesco,
two follow-up questions:
Can your module cope with an attachment that is not there (as mentioned I might receive messages with "MailMessage" OR "MailAttachment-1" set - never both...)?
Just out of curiousity: is there a possibility to process more than one attachment in the Integration Engine (routing, mapping, ...) from one XI message?
Cheers!
Stefan
Hi Stefan,
You have to write a module, that checks whether an attachmant is there or not. If an attachment is available, replace the content of the main payload with the attachment.
It is not possible to work with attachments inside the IS. Only adapters and proxies can handle attachments.
Regards
Stefan
Hi
you have the possibility to look for all the attachments in the xi message using the method
getAttachmentIterator() of Message interface.
Here how to find the sap api:
http://help.sap.com/saphelp_nw04/helpdata/en/87/3ef4403ae3db12e10000000a155106/content.htm
Hope this help
Francesco
Solved the issue by utilizing a module that creates a separate XI message for every MailAttachment or MailMessage it finds in an inbound email.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
See the below link
Mail Attachement name with note - Look at this note: 960502
/people/prasad.ulagappan2/blog/2005/06/07/mail-adapter-scenarios-150-sap-exchange-infrastructure
/people/michal.krawczyk2/blog/2005/11/23/xi-html-e-mails-from-the-receiver-mail-adapter - XI: HTML e-mails from the receiver mail adapter
/people/rahul.nawale2/blog/2006/11/01/dynamically-sending-a-mail-to-the-po-creator-using-xslt-abap-mapping
Sender mail adapter - PayloadSwapBean - Step by step -/people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step
Regards
Chilla
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.