Hi,Freeman :
I wrote a cxf-interceptor just before JbiOutWsdl1Interceptor at
Phase.MARSHAL to trace the flow.
I found that the JbiOutWsdl1Interceptor has parsed the jbi-message as
expected.
It got out the soap-headers and put it into the headlist,like :
List<Header> headerList = message.getHeaders();
headerList.add(new Header(header.getPart().getConcreteName(),
nl.item(0)));
I print out the header's name ,it was "AuthResult" and namespace was also
the expected.
But the SoapResponse to the client still has only the soap body.
How can i go ahead?
Is it the problem of SoapOutInterceptor$SoapOutEndingInterceptor,or
StaxOutInterceptor$StaxOutEndingInterceptor,or
MessageSenderInterceptor$MessageSenderEndingInterceptor?
This really confused me.
Expecting for your help!
Freeman Fang wrote:
>
>
> It should work, ensure the jbi part you added has same namespace and
> local name as it defined in the schema.
> what's the servicemix version you are using?
>
> Freeman
>> Freeman Fang wrote:
>>>
>>> Hi,
>>> Cxf bc provider parse JBI message and generate soap message based on
>>> wsdl model.
>>> So if the wsdl used for your cxf bc provider has no soap header in
>>> binding def, the soap message sent out from your cxf bc provider
>>> won't
>>> have soap header, it's expected behavior.
>>> You may need change your provider wsdl first.
>>>
>>> Freeman
>>> On 2009-9-6, at 上午11:58, inter wrote:
>>>
>>>>
>>>> I used cxf-bc-consumer,cxf-bc-provider and camel like follows:
>>>>
>>>> cxf-bc-consumer=(1)=>servicemix-camel=(2)=>cxf-bc-
>>>> provider=(3)=>external
>>>> server=(4)=>back to==>cxf-
>>>> -bc-provider=(5)=>servicemix-camel=(6)=>cxf-bc-consumer.
>>>>
>>>> The consumer and provider both have their own wsdl file.
>>>> The only difference of the two wsdl-files is that:the consumer's
>>>> wsdl has a
>>>> out-soap-header in binding def
>>>>
>>>> but the provider's does not have it.
>>>>
>>>> So in step(6),i add a camel-processor to add a soap-heaer part in
>>>> JBI msg
>>>> ,the whole msg after my processor like this:
>>>> -------------------------------------------------------------------------------------
>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>> <jbi:message xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-
>>>> wrapper"
>>>> xmlns:msg="http://server" xmlns:xsd="http://www.w3.org/2001/
>>>> XMLSchema"
>>>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>>> name="sayHelloResponse" type="msg:sayHelloResponse" version="1.0">
>>>> <jbi:part>
>>>> <ns1:sayHelloResponse xmlns:ns1="http://server">
>>>> <ns1:out>Hello!!!boy</ns1:out>
>>>> </ns1:sayHelloResponse>
>>>> </jbi:part>
>>>> <jbi:part>
>>>> <wsse:AuthResult
>>>>
>>>> xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd
>>>> "
>>>> mustUnderstand="true">
>>>> <wsse:ResultCode>0000</wsse:ResultCode>
>>>> <wsse:ResultDetail>success</wsse:ResultDetail>
>>>> </wsse:AuthResult>
>>>> </jbi:part>
>>>> </jbi:message>
>>>> ------------------------------------------------------------------------------------------------
>>>>
>>>> But when out of servicemix-cxf-bc,the soap message does not contain
>>>> soap-header at all,it just contains
>>>> the body message.
>>>> I am sure that I have added a soap-header to the binding def of the
>>>> consumer's wsdl.
>>>>
>>>> I upload my whole sa ZIP , in the cxf-bc-su.zip,there are all the
>>>> wsdl
>>>> files.
>>>> The proxy.wsdl is the consumer's,and the service.wsdl is the
>>>> provider's,the
>>>> wsse.xsd is the imported schema in which the soap header is defined.
>>>>
>>>> http://www.nabble.com/file/p25314469/test.zip test.zip
>>>>
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/Problems-with-adding-out-soap-header-for-cxf-bc..-tp25314469p25314469.html
>>>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>>>
>>>
>>>
>>> --
>>> Freeman Fang
>>> ------------------------
>>> Open Source SOA: http://fusesource.com
>>>
>>>
>>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Problems-with-adding-out-soap-header-for-cxf-bc..-tp25314469p25316117.html
>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>
>
>
> --
> Freeman Fang
> ------------------------
> Open Source SOA: http://fusesource.com
>
>
>
--
View this message in context:
http://www.nabble.com/Problems-with-adding-out-soap-header-for-cxf-bc..-tp25314469p25330829.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.