Problem with ComplexTypes (XML RPC Server )

Hi Friends,

Can anyone help me solve a problem with ComplexType elements using EntireX XML RPC Server?

When testing the service under XML Tester, the sample code declare the array type variable as bellow:

stringAN stringII stringIV stringKA stringIN

The JBoss server are replying this fault string:

org.jboss.ws.core.binding.BindingException: org.jboss.ws.core.jaxrpc.binding.jbossxb.UnmarshalException: Failed to parse source: {XML Schema}string type of element dtFimRestricoes should be complex and contain string as a child element.

If i manually set the array to a complex type form, it work fine. See the declaration bellow:

stringAN
stringII
stringIV
stringKA
stringIN

When i publish the XMM file at the server, the communication did not work returning the message:

NAT6977 EntireX RPC error on Server, reason 10010007

How can i solve this problem? Can i force the XMM mapping file to work with a complex types?

Thanks a lot.

My XML RPX Server is running EntireX version 8.2 and the server where the services are located is running JBOSS 5.1.0

Hi Andre, suggest to look at this as SOAP InterOperability
The question is if SOAP client (aka XML RPC Server) emits a SOAP request according to WSDL.

Perhaps XMLSPY or other tool can check if SOAP request is compliant with WSDL.

You can also load the WSDL is SOAPUI - and see what kind of Request is SOAPUI generating.

If you think SOAP reequest is not conformant to WSDL - suggest to contact Global Support.

BTW - it is recommended to use the latest entirex.jar (fix 28 I think)

regards, Shmuel Coller

and it is recommended to use latest Designer fix for EntireX plugin (fix 24) to consume WSDL

Hi Shmuel, thanks for the reply.

I’ve updated the version of all plugins into eclipse and got all in the latest versions.

Here are the IDL declaration imported from WSDL:

program 'WEBS0106':'atualizarVeiculoSemOnus' is
	define data parameter
	1 VeiculoDetranTO_1 		In
		2 cdCategoria 	  (A2)
		2 cdChassi 	  (A21)
		2 cdCombustivel 	  (A2)
		2 cdFormaCalculo 	  (A2)
		2 cdModelo 	  (A6)
		2 cdMunicipio 	  (A5)
		2 cdPlaca 	  (A7)
		2 cdRenavam 	  (A11)
		2 cnpjFinanceira 	  (A14)
		2 cpfCnpjProprietario 	  (A14)
		2 dtFimRestricoes (A8/5)
		2 dtInicioRestricoes 	  (A8/5)
		2 dtLeilao 	  (A8)
		2 dtPagamento 	  (A8)
		2 dtPassagemPosto 	  (A8)
		2 dtTransacao 	  (A8)
		2 flConsulta 	  (A1)
		2 flOutroRenavam 	  (A1)
		2 nmProprietario 	  (A50)
		2 nrAnoExercicio 	  (A4)
		2 nrAnoFabricacao 	  (A4)
		2 nrDua 	  (A30)
		2 nrNotaFiscal 	  (A7)
		2 tpVeiculo 	  (A2)
		2 ufEmissaoNF 	  (A2)
		2 ufJurisdicao 	  (A2)
		2 vlCilindradas 	  (A4)
		2 vlNFCarroceria 	  (A11)
		2 vlNotaFiscal 	  (A11)
	1 result 		Out
		2 cdRenavam 	  (A11)
		2 cdRetorno 	  (A3)
	end-define

Take a look to the array declarations:

		2 dtFimRestricoes (A8/5)
		2 dtInicioRestricoes 	  (A8/5)

Then, look for the SOAP request generated by the XML Tester:

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

<SOAP-ENV:Envelope xmlns:SOAP-ENV=“http://schemas.xmlsoap.org/soap/envelope/” xmlns:xmm=“http://namespace.softwareag.com/entirex/xml/mapping” xmlns:xsd=“XML Schema” xmlns:SOAP-ENC=“http://schemas.xmlsoap.org/soap/encoding/” xmlns:xsi=“http://www.w3.org/2001/XMLSchema-instance”>
SOAP-ENV:Header

</SOAP-ENV:Header>
SOAP-ENV:Body
<m:atualizarVeiculoSemOnus xmlns:m=“http://it.ipva.sae.sefaz.se.gov.br/”>
<VeiculoDetranTO_1>
QT
cdChassicdChassiYYEMT
BX
LO
SUBJTC
KMUIG
cdPlaca
cdRenavamHZ
cnpjFinanceira
WCTJYKEZMUPXSP

stringAQ
stringOQ
stringFP
stringMP
stringVP


stringFO
stringJV
stringVU
stringMV
stringIQ

dtLeilao
WECOBZZZ
OJNNRWVJ
XKSCZYFW
G
D
nmProprietarionmProprietarionmProprietarioHDHGNMMU
LMQO
BYER
nrDuanrDuanrDuanrDuanrDuanrDua
GCYQJSH
YE
RW
ET
XMQC
TLBDBKYMYTB
DCJVHOZDHHE
</VeiculoDetranTO_1>
</m:atualizarVeiculoSemOnus>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Then, when i try to run the tester with self generated SOAP, this return a fault string bellow:

org.jboss.ws.core.binding.BindingException: org.jboss.ws.core.jaxrpc.binding.jbossxb.UnmarshalException: Failed to parse source: {XML Schema}string type of element dtFimRestricoes should be complex and contain string as a child element.

----- Next Step, using the XML Spy ------------------------------------------

Using the XML Spy, the tool generated different SOAP Request envelope (see bellow):

<SOAP-ENV:Envelope xmlns:SOAP-ENV=“http://schemas.xmlsoap.org/soap/envelope/” xmlns:SOAP-ENC=“http://schemas.xmlsoap.org/soap/encoding/” xmlns:xsi=“http://www.w3.org/2001/XMLSchema-instance” xmlns:xsd=“XML Schema”>
SOAP-ENV:Body
<m:atualizarVeiculoSemOnus xmlns:m=“http://it.ipva.sae.sefaz.se.gov.br/”>
<VeiculoDetranTO_1>
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
String
</VeiculoDetranTO_1>
</m:atualizarVeiculoSemOnus>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Then, when i try to run the tester this SOAP Env from XML Spy the response envelope returns well !!!

Hi Andre,
There is BIG difference between two SOAP requests regarding:



The question is compliance of SOAP request to WSDL, there were past EntireX fixes in this respect.
Can you share the WSDL?

I leave tonight for a vacation, not sure how much I will help.

regards, Shmuel

Hi Shmuel,

I asked the service provider to change the declaration of the elements, then now are using an array of the class “restricao” who solved the questions about the elements declaration .

Now we have:
2 restricoes (/5)
3 dataFim (A8)
3 dataInicio (A8)

And now, the problem is another…

On the XML Tester is running all well, but on my XML RPC Server the return values are taking invalid positions and showing invalid values.

See the example return values writed on the screen by Natural:

           ,0MA2,0MA 6, 0M A5,0MA 7,0MA 11,0MA1                             

4,0MA14,0MA 8,0MA8,0MA8,0M A1,0MA1,0MA50, 0MA4,0MA 4,0MA30, 0MA7,0MA 8
, 0,5MA8,0,5MA2,0MA2,0MA2,0MA4,0MA11,0MA11,0MA11,0MA 3,0.

Ive changed the version of the entirex.jar from the server with the version on my development machine but the problem persists.
wsSefaz.xmm (113 KB)
WSSefazIPVAPort.xml (17 KB)
wsSefaz.idl (6.64 KB)

Hi andre, i am now in genoa italy cannot see your wsdl in my ipad
The xml tester is to be used only when you expose rpc program as wsstack based web service
I prefer not to involve it in you original xml rpc server scenario which is opposite direction

I suggest to go back to original discussion
Entirex should consume your wsdl, and generate soap compliant to wsdl.
Even if not sure you can open a ticket with global support and discuss suspicion that soap is not compliant
Please point to the fimrestricoes and inciorestricoes to be analyzed
Regards shmuel

Hi Shmuel, thanks for your reply.

I dont know whats happening anymore. We have changed the declarations at Java Application (JBOSS) removing the array types declaring flat parameters as you can see bellow:

		2 restricaoDtFim1 	  (A8)
		2 restricaoDtFim2 	  (A8)
		2 restricaoDtFim3 	  (A8)
		2 restricaoDtFim4 	  (A8)
		2 restricaoDtFim5 	  (A8)
		2 restricaoDtInicio1 	  (A8)
		2 restricaoDtInicio2 	  (A8)
		2 restricaoDtInicio3 	  (A8)
		2 restricaoDtInicio4 	  (A8)
		2 restricaoDtInicio5 	  (A8)

And for my surprise, the problem continues.

Then, now im thinking that the problem occours with a great number of parameters, because in the other short programs it work well.

I have created one test program to call the Webservice, and here are the variables content before and after the webservice call:

BEFORE WEBSERVICE CALL

INPUT PARM: 9C2JC2501SRS10782 2 0 2803 31410 HZG4607 633172103
87839849504 20110620 20100620 1 0
JOAO AMAURY JR 2010 1995
0 0NF1825
4 SE SE 124
0.00

OUTPUT PARM:


AFTER WEBSERVICE CALL

INPUT PARM: 63 3172103 999,0MA2,0MA 6, 0M A5,0MA 7,0MA 11,0MA1 4,0MA14,0MA
8,0MA8,0MA8,0M A8,0MA1,0MA1,0 MA50,0MA 4,0MA4,0 MA30,0MA 7,0MA8,0 M A
8,0MA8,0MA8,0MA8,0MA8,0MA8,0MA8,0MA8,0MA8,0MA2,0MA 2,0M A2,0
MA4,0MA11,0MA11,0MA11,0MA3,0. 9C2JC2 501SRS10 782 2 0 2803 31410HZ
G4607633 172103 87 83984950 4 20 1106 20 2
010062010JO

OUTPUT PARM: AO AMAURY J R

Problem Found: A bug inside Natural SYSRPC module

When i mount the parameters into the SYSRPC using the IG (Interface Object Generation) option, i write all “I” for input and “O” for output parameters, then i save it with no problem.

If i open the saved object the letters “I” and “O” was changed to “M” as INOUT parameters, then when i call the webservice with specific input and output parameters the XML RPC Server cannot put the return on correct position.

Solution: Fill the parameters into SYSRPC with “I” and “O” letters on each change will save the STUB file in the correct form.

Do you know there is a Natural Wrapper plugin in the Designer where you can easily create a Natural interface object out of an Software AG IDL file. Manual input as it is required for SYSRPC is not needed …