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

Re: Help consume Web Service



Alvaro,

It seems as if we are getting closer to the problem. So far I figured out that "El puntero no hace referencia a ninguna ubicació" translates to "Pointer not set for location referenced".

Then I took your web service stub module (WSMP1_7NP) and replaced http_post_xml() with http_parse_xml_stmf() and fed the content of the attached XML file to it. Guess what, it ran just fine. That means that the response data of wsmp1_7npt.txt basically is fine.

The question is why you receive a "Pointer not set ..." error while I do not get it.

What version of WSDL2RPG are you using? Please do a DSPPGM PGM(WSDL2RPG) DETAIL(*COPYRIGHT) and let me know the version (hopefully 1.7) and the date (hopefully 16.06.2009). If you are not using v1.7, 16.06.2009, please download that version and generate the stub module again. Then repeat your test.

If you are using v1.7, 16.09.2009, then modify the stub module as described below in order to figure out where the error message comes from:

a) Remove the "monitor;" statement.
b) Delete everything from "on-error;" until "endmon;" including these two statements.

Now recompile the stub module and run the test again. When the "Pointer not set ..." error occurs, prompt the message with F1, then press F9 and make a screen shot of that screen. Please send the screen shot to me.

Thomas.

Alvaro Orlando Salazar Martinez schrieb:
Thomas,

In the First "If" Enter to Cycle but the second "If" is not executed(if (MultiRef_isReference(attrs))).

if (depth = 1 and
         name = 'consultarAfiliadoReturn');

              if (MultiRef_isReference(attrs));
                 MultiRef_put(
                    attrs
                    : http_parser_get_userdata()
                    : depth
                    : namespace
                    : name
                    : path
                    : http_parser_get_start_cb()
                    : http_parser_get_end_cb());
                 return;
              endif;
           endif;


the SOAPMessage_Envelope()is executed in :
when (name = 'multiRef' and MultiRef_isData(attrs)); http_parser_switch_cb( *NULL : MultiRef_getStartCallback() : MultiRef_getEndCallback()); return; Saludos, Alvaro Orlando Salazar Martínez Ingeniero Sistemas de Información
Unidad de Tecnología Informática COOMEVA
Certificados ISO 9001 - Valorados CMMI Nivel 3
www.coomeva.com.co Teléfono: (57) 2- 333 0000 Ext. 1293 Dirección: Calle 13 No. 57 - 50 Cali - Valle Colombia
Unidad de Tecnología Informática Coomeva
**************************************************
Comprometidos con el mejoramiento de la productividad, con soluciones informáticas fiables, prácticas e innovadoras.

Favor piense en el medioambiente, antes de imprimir este mensaje

-----Mensaje original-----
De: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] En nombre de Thomas Raddatz
Enviado el: 2009-06-21 11:02
Para: HTTPAPI and FTPAPI Projects
Asunto: Re: Help consume Web Service

Alvaro,

I assume that you looked at the wrong place. The code snippet of your last reply seems to be part of the impl_consultarAfiliadoRpcStart() procedure.

But my questions corresponded to parts of impl_consultarAfiliadoReturnStart() and SOAPMessage_Envelope().

Thomas.


Alvaro Orlando Salazar Martinez schrieb:
Hi Thomas,
when debugging, the Program happens only when "depth = 2" and name = "ConsultarAfiliadoReturn" like this:

when (depth = 2 and name = 'consultarAfiliadoReturn' and namespace = ''); http_parser_switch_cb( %addr(impl_consultarAfiliadoRpc.consultarAfiliadoReturn) : %paddr('impl_consultarAfiliadoReturnStart') : %paddr('impl_consultarAfiliadoReturnEnd')); return; endsl; Saludos, Alvaro Orlando Salazar Martínez Ingeniero Sistemas de Información
Unidad de Tecnología Informática COOMEVA
Certificados ISO 9001 - Valorados CMMI Nivel 3
www.coomeva.com.co Teléfono: (57) 2- 333 0000 Ext. 1293 Dirección: Calle 13 No. 57 - 50 Cali - Valle Colombia
Unidad de Tecnología Informática Coomeva
**************************************************
Comprometidos con el mejoramiento de la productividad, con soluciones informáticas fiables, prácticas e innovadoras.

Favor piense en el medioambiente, antes de imprimir este mensaje



-----Mensaje original-----
De: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx] En nombre de Thomas Raddatz
Enviado el: 2009-06-21 09:47
Para: HTTPAPI and FTPAPI Projects
Asunto: Re: Help consume Web Service

Alvaro,

I cannot see why you should not get back the web service data. The questions I have are:

What happens in impl_consultarAfiliadoReturnStart()? Is MultiRef_put() executed when 'name' equals 'consultarAfiliadoReturn'?

          if (depth = 1 and
               name = 'consultarAfiliadoReturn'
               );
             if (MultiRef_isReference(attrs));
                MultiRef_put(
                   attrs
                   : http_parser_get_userdata()
                   : depth
                   : namespace
                   : name
                   : path
                   : http_parser_get_start_cb()
                   : http_parser_get_end_cb());
                return;
             endif;
          endif;

What happens in SOAPMessage_Envelope()? Is the http_parser_switch_cb(...) statement executed?

          when (name = 'multiRef' and MultiRef_isData(attrs));
             http_parser_switch_cb(
                *NULL
                : MultiRef_getStartCallback()
                : MultiRef_getEndCallback());
             return;

Is it possible to send the WSDL file to me? I would like to try to set up a mock Web Service with soapUI in order to debug the problem.

Thomas.

Alvaro Orlando Salazar Martinez schrieb:
Thanks Thomas, realize all the steps required and to make the Debug is not satisfactory the call to Web Service and returns the following error:

"-1: El puntero no hace referencia a ninguna ubicació"
returns data, but not because this error comes out.

copy the result of the Log. Thank you

Saludos, Alvaro Orlando Salazar Martínez Ingeniero Sistemas de Información
Unidad de Tecnología Informática COOMEVA
Certificados ISO 9001 - Valorados CMMI Nivel 3
www.coomeva.com.co Teléfono: (57) 2- 333 0000 Ext. 1293 Dirección: Calle 13 No. 57 - 50 Cali - Valle Colombia
Unidad de Tecnología Informática Coomeva
**************************************************
Comprometidos con el mejoramiento de la productividad, con soluciones informáticas fiables, prácticas e innovadoras.

Favor piense en el medioambiente, antes de imprimir este mensaje

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
	<soapenv:Body>
		<consultarAfiliadoResponse soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";>
			<consultarAfiliadoReturn href="#id0"/>
		</consultarAfiliadoResponse>
		<multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; xsi:type="ns1:Afiliado" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:ns1="co.com.miempresa.WsSaludMP.modelo.afiliado">
			<ciudadCorrespondencia xsi:type="xsd:long">76001</ciudadCorrespondencia>
			<ciudadResidencia xsi:type="xsd:long">76001</ciudadResidencia>
			<codRetorno xsi:type="xsd:long">1</codRetorno>
			<correoElectronico xsi:type="xsd:string">                                                            </correoElectronico>
			<descRetorno xsi:type="xsd:string">Consulta Exitosa</descRetorno>
			<dirCorrespondencia1 xsi:type="xsd:string">CRA 99 9-99                   </dirCorrespondencia1>
			<dirCorrespondencia2 xsi:type="xsd:string">                              </dirCorrespondencia2>
			<dirResidencia1 xsi:type="xsd:string">CRA mi direccion aparece                  </dirResidencia1>
			<dirResidencia2 xsi:type="xsd:string">                              </dirResidencia2>
			<nombreCompleto xsi:type="xsd:string">SALAZAR MARTINEZ ALVARO O     </nombreCompleto>
			<numDocumento xsi:type="xsd:long">11111111</numDocumento>
			<primerApellido xsi:type="xsd:string">SALAZAR             </primerApellido>
			<primerNombre xsi:type="xsd:string">ALVARO              </primerNombre>
			<segundoApellido xsi:type="xsd:string">MARTINEZ            </segundoApellido>
			<segundoNombre xsi:type="xsd:string">O                   </segundoNombre>
			<telfCorrespondencia xsi:type="xsd:string">3333333     </telfCorrespondencia>
			<telfResidencia xsi:type="xsd:string">3333333     </telfResidencia>
			<tipoDocumento xsi:type="xsd:string">CC</tipoDocumento>
		</multiRef>
	</soapenv:Body>
</soapenv:Envelope>
-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------