cancel
Showing results for 
Search instead for 
Did you mean: 

XI message with Attachment using Http Adapter

laxman_molugu
Participant
0 Kudos

Hi ,

We are using XI/PI 7.0 with Sp09 and Sender Application is SRM and Receiver is Ariba MarketPlace.

We are trying to Send PO with Attachments like Word, PDF etc from SRM to Ariba using Https adapter and from SRM we are using ABAP Proxy. When I did the testing with out any special config, I was able to send the attachments (I can see word doc as part of the payload-attachment) to XI from SRM but this attachment is not going through https adapter from XI to Ariba?

I have read some posts on this but I could not find the answer for my situation. One of the solution is that we can use SOAP adapter but we don't want to use Soap for some reasons.

Please give your thoughts.

Thanks in Advance.

-Laxman

Accepted Solutions (0)

Answers (3)

Answers (3)

stefan_grube
Active Contributor
0 Kudos

You can use the SOAP adapter and check the parameters 'Do not use SOAP envelope' and 'Keep attachments'.

Regards

Stefan

bhavesh_kantilal
Active Contributor
0 Kudos

Stefan,

I have never worked with Market place adapters, but from what I have read from laxman's question and you answer to use SOAP adapter with "Do not use SOAP Enevlope" and "Keepo Attachements" , is it a reasonable assumption that when integrating with marketplaces also you need a WSDL from the Marketplace / your vendor just as we need for SOAP?

Regards

Bhavesh

Former Member
0 Kudos

Stefan,

Laxam does want to use SOAP Adapter he wants to use HTTPonly

Regards

sreeram.g.reddy

stefan_grube
Active Contributor
0 Kudos

And what do you think is a SOAP message without SOAP envelope?

stefan_grube
Active Contributor
0 Kudos

When you check "Do not use SOAP Enevlope", then the SOAP adapter does not create a SOAP message, therefore you do not need a WSDL for it.

Besides: You can also send mails with the SOAP adapter

Regards

Stefan

laxman_molugu
Participant
0 Kudos

Hi Stefan and All,

Thanks for your replies, I am little confused, based on your references http can't support attachments. Also sap help link says Http adapter doesn't support attachments and XI adapter also doesn't support. It means Proxy also shouldn't support because proxy is nothing but XI adapter.

But When I send PO with attachments from SRM using Proxy connection I was able to pass through XI. So how proxy was able to send the attachments and this is contradicts to the help documentation.

We don't want to use SOAP because we are already using https adapter and this scenario is in production also if we go with SOAP then we have to re-import the digital certificate in Java Engine for SSL. Attachments are the new enhancement only.

Thanks,

Laxman

stefan_grube
Active Contributor
0 Kudos

> Thanks for your replies, I am little confused, based

> on your references http can't support attachments.

That is true.

> Also sap help link says Http adapter doesn't support

> attachments and XI adapter also doesn't support.

That is not true. XI adapter (in fact we do not talk of an adapter) supports attachments.

> It means Proxy also shouldn't support because proxy is

> nothing but XI adapter.

This is true, ABAP or Java Proxy are like XI adapter. Therefore it supports attachments.

> But When I send PO with attachments from SRM using

> Proxy connection I was able to pass through XI. So

> how proxy was able to send the attachments and this

> is contradicts to the help documentation.

The online help is wrong.

> We don't want to use SOAP because we are already

> using https adapter and this scenario is in

> production also if we go with SOAP then we have to

> re-import the digital certificate in Java Engine for

> SSL. Attachments are the new enhancement only.

I do not see another solution besides using SOAP adapter in so-called non-SOAP mode. Yes you have to reimport the certificates to J2EE stack.

Regards

Stefan

laxman_molugu
Participant
0 Kudos

Hi Stefan,

I am trying to setup the soap with attachment (Based on your kind advice).

Now I have another question that, when we are sending the PO with attachment to Ariba they need Attachment reference in the main payload in one of the tag. They expect tag like this <url>cid:payload-45D6A85428C41D07E1000000CC69380C@sap.com</url>. I can see the url of each attachment with its own ID but question is how to retrive that ID into a message mapping program.

Greatly appreciated your help.

Thanks,

Laxman

stefan_grube
Active Contributor
0 Kudos

> They expect tag like this

> <url>cid:payload-45D6A85428C41D07E1000000CC69380C@sap.

> com</url>. I can see the url of each attachment with

> its own ID but question is how to retrive that ID

> into a message mapping program.

What exacly should be in this tag? The HTTP message looks different as the XI message. I think the URL should be the same as the parameter content-description of the HTTP message.

If you have a sample HTTP message with attachment as the receiver requests, could you send this to stefan.sdn@googlemail.com

I will look into this.

Regards

Stefan

laxman_molugu
Participant
0 Kudos

Hi Stefan,

I sent (emailed) you a word document with detailed explanation. Please let me know if you need any further info.

Thanks,

Laxman

stefan_grube
Active Contributor
0 Kudos

I have checked the documents and the cXML specification.

You need to use the HTTP header property "Content-Id" of the attachment for the url tag in the main document. There is no standard for this scenario. I do not know, if you can access this property with an adapter module, but anyway this would have an effort in implementing this.

Another approach is using the plain HTTP adapter and create the whole MIME message with an Java Mapping. But in this case the attachment must not be sent as attachment, it must be part of the main payload, for example as base64 encoded element.

The creation of the Java mapping is not easy.

Regards

Stefan

laxman_molugu
Participant
0 Kudos

Hi Stefan,

Thanks a lot for your time.

>>Another approach is using the plain HTTP adapter and create the whole MIME message with an Java Mapping. But in this case the attachment must not be sent as attachment, it must be part of the main payload, for example as base64 encoded element.

Yes, this may not be suitable solution.

>>You need to use the HTTP header property "Content-Id" of the attachment for the url tag in the main document

Is there any way to get this ID from ABAP stack?(And this ID is also available in Manifest section of a message), if so we can write a RFC program and then we can make lookups in the mapping program. Since message is persisted in ABAP stack I am hoping that some how we can get this ID with MessageID as the input.

Please let me know if you have any insight on this.

thanks,

Laxman

laxman_molugu
Participant
0 Kudos

Hi Stefan,

Finally I was able to get the Content Ids of Mime attachments. Created a RFC to fetch the Ids then used RFC lookup API get this IDs into message mapping.

Used these main ABAP classes to get this piece of data.

......

CALL METHOD MESSAGE->GET_MSGHDR30_MANIFEST

EXPORTING

IM_CREATION = '1'

RECEIVING

RE_HEADER = msg_header

.

CALL METHOD MSG_HEADER->GET_PAYLOAD_REFS

RECEIVING

RETURN = itab_manifest

.

......

Thanks to all for your help.

-Laxman Molugu

Former Member
0 Kudos

HI Laxman,

we are having scenario of sending attachment along with purchase order from SRM to Ariba,

As we are using standard abap proxy at SRM end, We can find the attachment in PI 7.1 as separterpayload.

SRM is also sending one URL locating the location of attachment in doc server. Using that URL we can download the attachment in SRM network.

But Problems comes when Ariba try to access that url , it got an error as ISA server denied the URL.

Proxy error : 502 - Might this error is at Ariba Adapter proxy.

Please suggest

Former Member
0 Kudos

HI,

HTTP adapter wont support attachments. SOAP supports attachments.

Check this link to check out what are all the adapters that supports attachments.

http://help.sap.com/saphelp_nw2004s/helpdata/en/0d/5ab43b274a960de10000000a114084/content.htm

Regards,

Sudheer

Former Member
0 Kudos

Laxman,

you need to use payload swap bean in module processor to send the attachment from XI to Ariba.

Regards

Sreeram.G.Reddy