Hello,

I still have the same configuration :
- Web service server (WAS 6.1)
- Servicemix-cxf-bc consumer / provier (used as a bridge)
- Web service client (CXF)

I got some nillable array in my WSDL definition. Everything is ok as long as
those arrays are not null.
But when they are, "xsi:nil="true"" is added to the soap message. Everything
is still ok as long as i don't use the bridge (direct WS call from my CXF
client)

When i used the bridge, here is a part of the jbi out message :

<commitmentCode>1130</commitmentCode>
<companyCode>071</companyCode>
<consolidatedAutorisation
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
        xsi:nil="true" />
<consolidatedUtilisation
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
        xsi:nil="true" />

But here is a part of the soap out message :

<repaymentDate>2007-12-31T23:00:00.000Z</repaymentDate>
<subjectToApproval
        soapenc:arrayType="p724:SubjectToApprovalDTO[0]"
        xmlns:p724="http://dto.fcb.mycompany.com"; />
<syndication xsi: nil="true" />
<syndicationReference xsi:nil="true" />
<tolerancePercentage>1.0</tolerancePercentage>

As you can see, there is no
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";

And here is the error log of cxf client :

INFO: Interceptor has thrown exception, unwinding now
org.apache.cxf.interceptor.Fault: Unmarshalling Error: Undeclared namespace
prefix "xsi" (for attribute "nil")
 at [row,col {unknown-source}]: [1,613] 
        at
org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:559)
        at
org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:465)
        at org.apache.cxf.jaxb.io.DataReaderImpl.read(DataReaderImpl.java:40)
        at
org.apache.cxf.interceptor.DocLiteralInInterceptor.handleMessage(DocLiteralInInterceptor.java:102)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207)
        at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:402)
        at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1948)
        at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1791)
        at 
org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66)
        at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:575)
        at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207)
        at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254)
        at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205)
        at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
        at 
org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)
        at $Proxy27.searchAutorisationByInternalAutorisationNumberDTO(Unknown
Source)
        at
com.mycompany.fcb.ejb.ejb.ReadAutorisationBean_ReadAutorisationBean_Client.main(ReadAutorisationBean_ReadAutorisationBean_Client.java:59)
Caused by: javax.xml.bind.UnmarshalException
 - with linked exception:
[com.ctc.wstx.exc.WstxParsingException: Undeclared namespace prefix "xsi"
(for attribute "nil")
 at [row,col {unknown-source}]: [1,613]]
        at
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.handleStreamException(UnmarshallerImpl.java:396)
        at
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:334)
        at
com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:311)
        at
org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:545)
        ... 17 more


Does servicemix-cxf supports
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; namespace refix?

Thanks in advance,
Best regards,
Florent.
-- 
View this message in context: 
http://www.nabble.com/servicemix-cxf-bc-missing-namespace-prefix-tp14292666s12049p14292666.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to