ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Help on httprequest

Post new topic  Reply to topic
 Help on httprequest « View previous topic :: View next topic » 
Author Message
paulobugmann
PostPosted: Thu Mar 21, 2019 10:03 am    Post subject: Help on httprequest Reply with quote

Newbie

Joined: 27 Jul 2018
Posts: 5

If I send the message via SoapUI, the webservice will receive a message correctly.
If I send via IIB the message arrives blank in webservice and displays error.


Message Flow: (This is just a sample message flow that I built to isolate the problem)
====================

MQInputNode --> ComputeNode --> HTTPRequestNode --> TraceNode (this will be replaced with Compute Node and MQOutput Node upon making it work)


Message:
====================
Code:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dir="http://tempuri.org/">
   <soapenv:Header/>
   <soapenv:Body>
      <dir:ProcessMessage>
         <dir:xmlMessage><![CDATA[<TEST>test</TEST>]]></dir:xmlMessage>
         <dir:applicationName>TEST</dir:applicationName>
      </dir:ProcessMessage>
   </soapenv:Body>
</soapenv:Envelope>




Compute Node:
====================
Code:

      SET OutputRoot.HTTPRequestHeader.POST = '/WS/ImportadorService.asmx';
      SET OutputRoot.HTTPRequestHeader.Host = 'localhost';
      SET OutputRoot.HTTPRequestHeader."Content-Type" = 'text/xml; charset=utf-8';
      SET OutputRoot.HTTPRequestHeader.SOAPAction = 'http://localhost/ProcessMessage';
      SET OutputLocalEnvironment.Destination.HTTP.RequestURL = 'http://localhost/WS/ImportadorService.asmx';
      SET OutputLocalEnvironment.Destination.HTTP.RequestLine.HTTPVersion = 'HTTP/1.1';
      SET OutputLocalEnvironment.Destination.HTTP.RequestLine.RequestURI = '/WS/ImportadorService.asmx';
      SET OutputRoot.XMLNSC.soap:Envelope.(XMLNSC.NamespaceDecl)xmlns:soap = 'http://www.w3.org/2003/05/soap-envelope';
      SET OutputRoot.XMLNSC.soap:Envelope.soap:Body.soap:ProcessMessage.(XMLNSC.NamespaceDecl)xmlns:dir = 'http://tempuri.org/;
      DECLARE InputMessageBlob BLOB ASBITSTREAM(InputBody);
      DECLARE InputMessageChar CHAR CAST(InputMessageBlob AS CHAR CCSID InputRoot.MQMD.CodedCharSetId);
      SET OutputRoot.XMLNSC.soap:Envelope.soap:Body.soap:ProcessMessage.(XMLNSC.CDataField)*:xmlMessage = InputMessageChar;
       SET OutputRoot.XMLNSC.soap:Envelope.soap:Body.soap:ProcessMessage.*:ApplicationName = 'TEST';
      RETURN TRUE;


WS Return:
====================

Server was unable to process request. ---&gt; Object reference not set to an instance of an object.
Back to top
View user's profile Send private message
Vitor
PostPosted: Thu Mar 21, 2019 10:52 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

What does the user trace (as opposed to the Trace node) say is happening? You've been advised in earlier posts to use it as a first stop diagnostic tool.

Why are you using this rather odd construction to build the CDATA section? Have you confirmed it's doing what you think it is?

Why are you building the SOAP request using ESQL and XMLNSC rather than using the SOAP domain?

Why does your ESQL attempt to build a different XML message to the example you post? (Look closely)
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Help on httprequest
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.