cancel
Showing results for 
Search instead for 
Did you mean: 

Call from MII using HTTPPost to standard ME WebService - no data returned.

former_member202208
Active Participant
0 Kudos

Hi experts,

I am making a HttpPost Call to Standard SAP ME webservice from MII transaction to create a PO, in the PostData we are setting the SOAPxml request.

If there is error in creating a PO, MII transaction doest show me the response data, In the response, i see the following trace.

  • [WARN] [HTTP_Post_0] Skipping execution of output links due to action failure.
  • [ERROR] Uncaught exception from HTTP_Post_0, 

data set to HttpPost request.

Trying to retrieve the ME response from HTTP_Post_0.ReturnAsString & HTTP_Post_0.ReturnAsXML methods.

am i missing something?

Message was edited by: Shridhar N I see the following message in logs; Message:   [Transaction: 248465] Uncaught exception from HTTP_Post_0,   Severity:   Error Date:   2012-04-19 Time:   11:41:37:482 Category:   /Applications/XMII/Xacute/Event Location:   com.sap.xmii.bls.engine.TransactionInstance Application:   sap.com/xapps~xmii~ear Message:   *** MISSING RESOURCE: Unable to localize Unknown variable: HTTP_Post_0.LastErrorMessage  Severity:   Warning Date:   2012-04-19 Time:   11:41:37:482 Category:   /Applications/LHCommon Location:   com.sap.lhcommon.localization.MessageCatalog Application:   sap.com/xapps~xmii~ear Thread:   Thread[HTTP Worker [@898724571],5,Dedicated_Application_Thread] Data Source:   j2ee/cluster/server0/log/applications_00.log

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member196557
Active Contributor
0 Kudos

If you are using MII 12.2 you can add a Catch block and then examine the error message from the Catch branch with a Trace action.

- Steve

former_member202208
Active Participant
0 Kudos

Thanks Steve,

I see "13:51:43.351 [DEBUG] HTTP Post:false statusText:Internal Server Error statusCode:500

" message.

When i pass the correct data, i see "13:49:10.633 [DEBUG] HTTP Post:true statusText:OK statusCode:200" message and there is no error.

Why could this be happening.? If the input data is incorrect, i should get an error message from the server/app and it should not stop the flow.

am i missing something?

Thanks,

former_member202208
Active Participant
0 Kudos
Sorry for the double post [extra post removed by moderator ;-)];
According to help document;
 
You can link the following parameters to this action:
Parameter
Description
Type
DisableHandling
User-defined message
Boolean
Source
The action that is throwing the exception
String
ActionType
Type of the action that is throwing the exception
String
Message
Message the exception contains
String
ExceptionType
Type of exception thrown
String
ExceptionCaught
If an exception occurred, the value is true
Boolean
Succeeded
Value is always true
Boolean
I dont see any of these in link editor for catch block.
I am using MII 12.2.2.235.

Message was edited by: Michael Appleby

former_member196557
Active Contributor
0 Kudos

Add a Sequence step after the Catch block, you will get two branched sequences.  Add a Tracer action to the "caught" branch (red connector) and map the Message property there.

Just curious, why are you using HTTPPost instead of Webservice action to call the web service?

- Steve

former_member202208
Active Participant
0 Kudos

Thanks Steve.

With catch block i could see the response coming back from ME.

I observed that, when i use the Webservice call, it expects me to fill/map in all the data elements value. but if i use http call, i can send the minimal xml elments in the SOAP call and it works.

Thanks..

former_member196557
Active Contributor
0 Kudos

You can actually use Webservice action block but you have to create 3 sequence steps to modify the request to remove the non-required nodes, WS1 without execution, Assignment action (to remove the un-needed nodes from WS1 request and assign the rest of the request required values), WS2 and assign its request from the modified WS1 request, and execute WS2

- Steve

former_member202208
Active Participant
0 Kudos

Thanks Steve,

I will try that option aswell.

I have one more question:

I am trying to set the HTTPPost ReturnXML (which is a SOAP response xml) to a Transaction parameter of type xml, from which i plan to use to retrive the data or faultcode or faultstring etc..

I have a Transaction output param of type xml (ReturnData). In the POGrid (iGrid), the ReturnData wont show up under the 'Column names' for POXacQuery (Querytemplate). If i change the datatype of ReturnData to String, it shows up and i can see the data in Applet.

I need to the response so that we can display proper message.

Is it that we cant use a Transaction parameter of type xml to assign SOAP return xml or does it expect the return xml data in a specific format.??

Pls advise.

Thanks,

PS: I am new to MII.

former_member196557
Active Contributor
0 Kudos

Not sure about the issue with the HTTPPost response.  I have only used Webservice Action Block for ME Webservice requests, and not had any issues with the response xml assignments.

- Steve

former_member202208
Active Participant
0 Kudos

Steve,

Thanks. With Webservice action, I am passing/setting minimal xml elments in the SOAP call and it works.

but, the repose has only one root node and no details on the PO created.

<ns2:ProductionOrderCreateConfirmation_sync xmlns:ns2="http://sap.com/xi/ME" xmlns="http://sap.com/xi/SAPGlobal/GDT"/>

any suggestion?

Thanks,

former_member196557
Active Contributor
0 Kudos

Which version/build of SAPME are you using?

- Steve

former_member202208
Active Participant
0 Kudos

Its;

Base 6.0.2.2 Counter 12

Build ID 138945

former_member196557
Active Contributor
0 Kudos

I thint at this point you will need to log a ticket to get this resolved.  The WSDL for 6.0.3 Counter 24 for ProductionOrderService appears to contain the elements for a valid response; I don't have access to a 6.0.2 system to compare with.

- Steve

former_member202208
Active Participant
0 Kudos

Hi,

I have the same issue on;

ME Base 6.0.2.6 Counter 10
Build ID 141098

Reposne:

<SOAP-ENV:Envelope xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

   <SOAP-ENV:Body>

      <ns2:ProductionOrderCreateConfirmation_sync xmlns="http://sap.com/xi/SAPGlobal/GDT" xmlns:ns2="http://sap.com/xi/ME"/>

   </SOAP-ENV:Body>

</SOAP-ENV:Envelope>

Can some one help me..

Thanks,