cancel
Showing results for 
Search instead for 
Did you mean: 

How to create Multipart request using HTTP_AAE Java adapter

Former Member
0 Kudos

Dear Sap Experts,

I am using SAP PO7.4 Java stack. My scenario is proxy to HTTP. I am using HTTP_AAE java receiver adapter for the first time

My task is to send a multipart request to receiver system. This request  looks as below.

Please suggest how I can convert my XML(Bold colour part is my XML request after message mapping) to this request format and what should be the configuration and what parameters should i pass.

Any link or any step by step guide would be really helpful for me .

Request :

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="C:\SDG\Temp\1.txt"; filename="1.txt"

Content-Type: text/plain; charset=ISO-8859-1

Content-Transfer-Encoding: binary

Test Sample File

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="C:\SDG\Temp\Import6.xml"; filename="Import6.xml"

Content-Type: text/xml; charset=ISO-8859-1

Content-Transfer-Encoding: binary

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE ePASSRequest SYSTEM "ePASS3.dtd">

<ePASSRequest requestID="6000285942" submitterOrganization="6200" submitterUser="bam" submitterPassword="Test@123">

<RFxRequest>

<createRFx>

<RFx RFxStyle="None" OrganizationCode="6200" RFxName="1081600007" RFxType="RFP" RFxBusinessUnit="(Unassigned)" RFxIsTemplate="FALSE" RFxTemplateCode="ZR01" RFxStatus="created" RFxDecimalPlaces="2" RFxDefaultCurrencyCode="INR" RFxCurrencyCodes="INR|USD|EUR" RFxPrimaryContact="bam">

<GeneralRFxBiddingRules RFxUseBundleBid="false" RFxVolumeDiscount="false" RFxUseItemSet="false" RFxEventNotifications="true"/>

<AttachmentRules RFxEventAttachment="true" RFxBidAttachment="true" RFxQuestionnaireResponseAttachment="true" RFxQuestionResponseAttachment="true"/>

<RFQBiddingRules RFxUseVolumeBid="false" RFxAllowOptimizationFeedback="false" RFxAllowSupplierConstraint="false" RFxAllowSingleBidPerItem="false"/>

<RFxBuyerRules RFxLockedBidIndicator="false"/>

<HostAssignment LoginName="bam" ResponderParticipationStatus="accepted" SubscriptionType="rfx" HostAssignmentRole="Lead"/>

<Subscription LoginName="xyz@abc.com" SupplierProfileName="Org Name" ResponderParticipationStatus="unacknowledged" SubscriptionType="rfx"/>

<Requisition RequisitionCode="Default" RequisitionName="Default">

<LineItem LineItemCategoryCode="root category" LineItemCode="10" LineItemLotName="Default" LineItemMinimumBidQuantity="0" LineItemMinimumDesiredQuantity="2.0" LineItemName="10" LineItemType="single">

<ExtendedAttribute ExtendedAttributeCode="Material Code" ExtendedAttributeValue="OPC43"/>

<ExtendedAttribute ExtendedAttributeCode="Material Group" ExtendedAttributeValue="Z200"/>

<ExtendedAttribute ExtendedAttributeCode="Plant" ExtendedAttributeValue="6972"/>

<ExtendedAttribute ExtendedAttributeCode="Plant Region" ExtendedAttributeValue="WEST BENGAL"/>

<ExtendedAttribute ExtendedAttributeCode="Country" ExtendedAttributeValue="India"/>

<ExtendedAttribute ExtendedAttributeCode="Required Delivery Date" ExtendedAttributeValue="31.07.2017"/>

<ExtendedAttribute ExtendedAttributeCode="UOM" ExtendedAttributeValue="Metric Ton"/>

<Attachment AttachmentEntityType="item" AttachmentName="1.txt" AttachmentLocation="1.txt" AttachmentCreatorLoginName="bam"/>

</LineItem>

</Requisition>

</RFx>

</createRFx>

</RFxRequest>

</ePASSRequest>

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="ioCtx"

Content-Type: text/plain; charset=US-ASCII

Content-Transfer-Encoding: 8bit

1

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="orgname"

Content-Type: text/plain; charset=US-ASCII

Content-Transfer-Encoding: 8bit

6200

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="requestMode"

Content-Type: text/plain; charset=US-ASCII

Content-Transfer-Encoding: 8bit

0

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="ePASSRequestDocs"

Content-Type: text/plain; charset=US-ASCII

Content-Transfer-Encoding: 8bit

C:\SDG\Temp\Import6.xml

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="username"

Content-Type: text/plain; charset=US-ASCII

Content-Transfer-Encoding: 8bit

bam

--b2Lh0weilHCR3Aw6z30XSc-HGGYpw-LcKSA

Content-Disposition: form-data; name="fileType"

Content-Type: text/plain; charset=US-ASCII

Content-Transfer-Encoding: 8bit

0

Thanks

Sandeep Sharma

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Experts any reply ... plz

former_member186851
Active Contributor
0 Kudos

Sandeep,

Check the below link and see if it helps

bhavesh_kantilal
Active Contributor
0 Kudos

Hello Raghu,

The blog deals with using a Custom Java Mapping to create a MultiPart message with a plain old HTTP Adapter. This approach was required when HTTP adapters did not support Multi Part.

The requester has already mentioned he is using HTTP_AAE which means this is a out of the shelf feature ( one that I personally have not used so havent attempted to answer this question ) and hence this link is not relevant ..

Regards,

Bhavesh

former_member186851
Active Contributor
0 Kudos

Hello Bhavesh,

Yes Bhavesh,In the starting they have mentioned for HTTP_AAE,Just enabling in the channel level will do I guess.

I shared it for better understanding.

Former Member
0 Kudos

Thanks raghu .. I have already visited this link  and this is not relevent as bhavesh has mentioned.

former_member186851
Active Contributor
0 Kudos

Ok Sharma, Please ignore it.

The HTTP_AAE adapter option of Multipart is not helping you out.

Former Member
0 Kudos

Hi raghu,

I have configured parameters but unfortunately i am not able to see any conversion /Change in request

experts .... please suggest