[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Antwort: Re: Missing tags in the web service XML creation



Kalyan,

> - I am trying to understand your sample programs in LIBHTTP and find
> which is going to be the version I should use as there seems to be
> different methods of XML parsing in there.

Usually you will use http_post_xml() to send your SOAP request to the
server and automatically invoke the eXpat parser on the response received
from the server. I assume that this approach is common sense for calling a
web service. http_post_xml() is the very same procedure as
http_url_post_xml(). It is mapped to http_url_post_xml() in member
HTTPAPI_H. I do not know why both procedure names exist.

Some times, but I cannot explain why, you will use http_url_get() or
http_url_post() to send a request to the server but put the response into
an IFS stream file. Then you can decide whether to start a parser for the
data in the stream file or not. Procedure http_parse_xml_stmf() is used for
that purpose. It takes the name of an existing stream file and the address
of the callback procedure to use. Then it starts the eXpat parser and the
parser will call the callback procedure for each element it reads from the
stream file.

> - Lastly, your example in HTTPXMLR4 seems to contain both HTTP POST as
> well as EXPAT parsing. Is that correct?

As Scott already mentioned, HTTPXMLR4 is part of the HTTP API service
program. It is not an example program. The following sample programs
demonstrate how to use http_url_post_xml()/http_post_xml():

   EXAMPLE16 - UPS package tracking
   EXAMPLE18 - Currency converter
   EXAMPLE19 - Language translation
   EXAMPLE20 - Currency converter (long SOAP action)

Thomas.


ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx schrieb am 28.08.2009 00:18:13:

> Von:
>
> KTirumamidi@xxxxxxxxxxxxxxx
>
> An:
>
> ftpapi@xxxxxxxxxxxxxxxxxxxxxx
>
> Datum:
>
> 28.08.2009 00:22
>
> Betreff:
>
> Re: Missing tags in the web service XML creation
>
> Gesendet von:
>
> ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
>
> Scott - Upon reading the articles I am leaning towards your idea.
>
> - If it is worth a question can you please tell me how different is
> EXPAT compared to IBM supplied XML-SAX parser? I just started reading
> documentation on IBM for XML parsing.
>
> - I am trying to understand your sample programs in LIBHTTP and find
> which is going to be the version I should use as there seems to be
> different methods of XML parsing in there.
>
> - Also I do not know if I can use SOAPUI since our company has already
> developed a generic RPG application to generate a XML file to POST to
> the web service. Would that cause any issues in using your EXPAT utility
> to parse the response file?
>
> - Lastly, your example in HTTPXMLR4 seems to contain both HTTP POST as
> well as EXPAT parsing. Is that correct?
>
> Thanks advance,
>
> Regards
> Kalyan
>
>
>
> Message: 1
> Date: Thu, 27 Aug 2009 12:46:34 -0500
> From: Scott Klement <sk@xxxxxxxxxxxxxxxx>
> Subject: Re: Missing tags in the web service XML creation
> To: HTTPAPI and FTPAPI Projects <ftpapi@xxxxxxxxxxxxxxxxxxxxxx>
> Message-ID: <4A96C67A.4010103@xxxxxxxxxxxxxxxx>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hello,
>
> > Here is what is happening. The tags between <q0:paymentRequest> and
> > </q0:paymentRequest> are not being generated.
>
> I just want to point out that you can use HTTPAPI with SoapUI. To get
> this service working.  It's a little more effort than using WSDL2RPG,
> but if you have a looming deadline, this might get you going quicker
> than waiting for Thomas to update WSDL2RPG.
>
> Surely doing that is 100 times simpler than switching to another
> technology like MQ!
>
>
> -----------------------------------------
> This e-mail, including attachments, may include confidential and/or
> proprietary information, and may be used only by the person or
> entity to which it is addressed. If the reader of this e-mail is
> not the intended recipient or his or her authorized agent, the
> reader is hereby notified that any dissemination, distribution or
> copying of this e-mail is prohibited. If you have received this
> e-mail in error, please notify the sender by replying to this
> message and delete this e-mail immediately.
> -----------------------------------------------------------------------
> This is the FTPAPI mailing list.  To unsubscribe, please go to:
> http://www.scottklement.com/mailman/listinfo/ftpapi
> -----------------------------------------------------------------------


--
IMPORTANT NOTICE:
This email is confidential, may be legally privileged, and is for the
intended recipient only. Access, disclosure, copying, distribution, or
reliance on any of it by anyone else is prohibited and may be a criminal
offence. Please delete if obtained in error and email confirmation to the sender.
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------