Hi Florent,

You client side should already have correct response even with this "Out not supported" exception. Anyway I will try to fix it soon.

For cxf interceptor documents, I think [1] is a good place to start.

[1]http://cwiki.apache.org/confluence/display/CXF20DOC/Interceptors

Best Regards

Freeman

Florent wrote:
Hi Freeman,

Thanks for your post, it resolves a part of the problem. Indeed, the third
party web service is called (i put a breakpoint to check it). Is there some documentation / examples of interceptor use, other than
javadoc?

Sadly, i still get the "Out not supported error".

If i used my standalone client to call the WAS web service (without using
servicemix), i get the following soap message :

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"; xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
<soapenv:Header/>
<soapenv:Body>
<p637:getProtoDTOResponse xmlns:p637="http://ejb.proto.mycompany.com";>
<getProtoDTOReturn>
<date>2007-11-28T09:10:54.104Z</date>
<dble>0.0</dble>
<integ>1</integ>
<liste><string>s01</string><string>s02</string><string>s03</string></liste>
</getProtoDTOReturn>
</p637:getProtoDTOResponse>
</soapenv:Body>
</soapenv:Envelope>

Is there something wrong with it? or something servicemix cxf might not
understand?

Here is the debug log :

INFO: Inbound Message
--------------------------------------
Encoding: utf-8
Headers: {Content-Length=[353], User-Agent=[IBM WebServices/1.0],
Host=[localhos
t:8092], connection=[Keep-Alive], Date=[Wed, 28 Nov 2007 09:05:10 GMT],
SOAPActi
on=[], Pragma=[no-cache], content-type=[text/xml; charset=utf-8],
Cache-Control=
[no-cache], Accept=[application/soap+xml,multipart/related,text/*]}
Message:
<env:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:en
v="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/
XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns:tns="http
://ejb.proto.mycompany.com"><env:Body><tns:getProtoDTO>ddd</tns:getPr
otoDTO></env:Body></env:Envelope>
--------------------------------------
DEBUG - CxfBcComponent                 - Created correlation id:
ID:172.xx.xxx.xxx-116855db752-4:10
DEBUG - DeliveryChannelImpl            - SendSync
ID:172.xx.xxx.xxx-116855db752-4:10 in DeliveryChannel{servicemix-cxf-bc}
DEBUG - SedaFlow                       - Called Flow send
DEBUG - DeliveryChannelImpl            - Waiting for exchange
ID:172.xx.xxx.xxx-116855db752-4:10 (13cdb70) to be answered in
DeliveryChannel{servicemix-cxf-bc}
from sendSync
DEBUG - SedaQueue                      -
[EMAIL PROTECTED] dequeued
exchange: InOut[
  id: ID:172.xx.xxx.xxx-116855db752-4:10
  status: Active
  role: provider
  interface: {http://ejb.proto.mycompany.com}ProtoBean
  service: {http://ejb.proto.mycompany.com}ProtoBeanService
  endpoint: ProtoBean
  operation: {http://ejb.proto.mycompany.com}getProtoDTO
  in: <?xml version="1.0" encoding="UTF-8"?><jbi:message
xmlns:jbi="http://java.
sun.com/xml/ns/jbi/wsdl-11-wrapper"
xmlns:msg="http://ejb.proto.mycompany.com"; name=
"getProtoDTORequest" type="msg:getProtoDTORequest"
version="1.0"><jbi:part><tns:
getProtoDTO xmlns:tns="http://ejb.proto.mycompany.com";>ddd</tns:getPr
otoDTO></jbi:part></jbi:message>
]
DEBUG - CxfBcComponent                 - Received exchange: status: Active,
role: provider
DEBUG - CxfBcComponent                 - Retrieved correlation id:
ID:172.xx.xxx.xxx-116855db752-4:10
DEBUG - DeliveryChannelImpl            - Send
ID:172.xx.xxx.xxx-116855db752-4:10 in DeliveryChannel{servicemix-cxf-bc}
DEBUG - SedaFlow                       - Called Flow send
DEBUG - SedaQueue                      -
[EMAIL PROTECTED] dequeued
exchange: InOut[
  id: ID:172.xx.xxx.xxx-116855db752-4:10
  status: Active
  role: consumer
  interface: {http://ejb.proto.mycompany.com}ProtoBean
  service: {http://ejb.proto.mycompany.com}ProtoBeanService
  endpoint: ProtoBean
  operation: {http://ejb.proto.mycompany.com}getProtoDTO
  in: <?xml version="1.0" encoding="UTF-8"?><jbi:message
xmlns:jbi="http://java.
sun.com/xml/ns/jbi/wsdl-11-wrapper"
xmlns:msg="http://ejb.proto.mycompany.com"; name=
"getProtoDTORequest" type="msg:getProtoDTORequest"
version="1.0"><jbi:part><tns:
getProtoDTO xmlns:tns="http://ejb.proto.mycompany.com";>ddd</tns:getPr
otoDTO></jbi:part></jbi:message>
  out: null
]
DEBUG - DeliveryChannelImpl            - Notifying exchange
ID:172.xx.xxx.xxx-116855db752-4:10(13cdb70) in
DeliveryChannel{servicemix-cxf-bc} from processInboun
dSynchronousExchange
DEBUG - DeliveryChannelImpl            - Notified:
ID:172.xx.xxx.xxx-116855db752-4:10(13cdb70) in
DeliveryChannel{servicemix-cxf-bc} from sendSync
28 nov. 2007 10:05:10
org.apache.cxf.interceptor.LoggingOutInterceptor$LoggingCallback onClose
INFO: Outbound Message
--------------------------------------
<soap:Envelope
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";><soap:Body
 /></soap:Envelope>
--------------------------------------
DEBUG - DeliveryChannelImpl            - Send
ID:172.xx.xxx.xxx-116855db752-4:10 in DeliveryChannel{servicemix-cxf-bc}
DEBUG - SedaFlow                       - Called Flow send
DEBUG - SedaQueue                      -
[EMAIL PROTECTED] dequeued
exchange: InOut[
  id: ID:172.xx.xxx.xxx-116855db752-4:10
  status: Done
  role: provider
  interface: {http://ejb.proto.mycompany.com}ProtoBean
  service: {http://ejb.proto.mycompany.com}ProtoBeanService
  endpoint: ProtoBean
  operation: {http://ejb.proto.mycompany.com}getProtoDTO
  in: <?xml version="1.0" encoding="UTF-8"?><jbi:message
xmlns:jbi="http://java.
sun.com/xml/ns/jbi/wsdl-11-wrapper"
xmlns:msg="http://ejb.proto.mycompany.com"; name=
"getProtoDTORequest" type="msg:getProtoDTORequest"
version="1.0"><jbi:part><tns:
getProtoDTO xmlns:tns="http://ejb.proto.mycompany.com";>ddd</tns:getPr
otoDTO></jbi:part></jbi:message>
  out: null
]
DEBUG - CxfBcComponent                 - Received exchange: status: Done,
role:provider
DEBUG - CxfBcComponent                 - Retrieved correlation id:
ID:172.xx.xxx.xxx-116855db752-4:10
javax.jbi.messaging.MessagingException: Out not supported
        at
org.apache.servicemix.jbi.messaging.MessageExchangeImpl.setMessage(MessageExchangeImpl.java:357)
        at
org.apache.servicemix.cxfbc.CxfBcProviderMessageObserver.onMessage(CxfBcProviderMessageObserver.java:125)
        at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1932)
        at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1790)
        at
org.apache.servicemix.cxfbc.CxfBcProvider.process(CxfBcProvider.java:166)
        at
org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:538)
        at
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:490)
        at
org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:46)
        at
org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:610)
        at
org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:170)
        at
org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:167)
        at
org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
        at java.lang.Thread.run(Thread.java:595)





Freeman Fang wrote:
Hi Florent,

I just use your wsdl and create standalone client and server using cxf, and use servicemix cxf bc consumer and provider to simulate your scenario, it works for me.

The soap message after cxf bc provider is

Encoding: UTF-8
Headers: {Host=[localhost:9001], User-Agent=[Java/1.5.0_10], connection=[keep-alive], transfer-encoding=[chunked], Pragma=[no-cache], content-type=[text/xml; charset=UTF-8], Cache-Control=[no-cache], Accept=[*]}
Message:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";><soap:Body><ns2:getProtoDTO xmlns:ns2="http://ejb.proto.mycompany.com";>test</ns2:getProtoDTO></soap:Body></soap:Envelope>

Even there this no soapAction in http header, it works well with cxf server. But as you said, your websphere server need this soapAction, so you can add
         <cxfbc:outInterceptors>
<bean class="org.apache.cxf.binding.soap.interceptor.SoapActionOutInterceptor"/>
          </cxfbc:outInterceptors>

for your cxf bc provider configuration, this interceptor will add soapAction according to the wsdl to your message
after that, the soap message would be like
Encoding: UTF-8
Headers: {Host=[localhost:9001], User-Agent=[Java/1.5.0_10], connection=[keep-alive], SOAPAction=["getProtoDTO"], transfer-encoding=[chunked], Pragma=[no-cache], content-type=[text/xml; charset=UTF-8], Cache-Control=[no-cache], Accept=[*]}
Message:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";><soap:Body><ns2:getProtoDTO xmlns:ns2="http://ejb.proto.mycompany.com";>test</ns2:getProtoDTO></soap:Body></soap:Envelope>
I believe this way should work for you.

Best Regards

Freeman

Florent wrote:
Yes, that's exactly what i mean.

The param tag didn't appear in my first for some obscur reason. That's
why i
was saying my SOAP message is correct.

Is there any way to trace what is going on in the bus? Something better
than
the debug log?
I'd like to check the SOAP message generated by the Servicemix Cxf bc
provider.



Freeman Fang wrote:
You mean your request soap message already has < param> yourParam<
/param> element? and it still doesn't work ? (obviously I make a
mistake in my prevoious mail, I mismactch the response and request,
sorry for it)


On Nov 27, 2007 8:06 PM, Florent <[EMAIL PROTECTED]> wrote:
There is a problem when i post the "param" tag : it does not appear in
the
forum post. I edited my previous message and put some spaces :

<tns:getProtoDTO>
< param>myparam</ param>
</tns:getProtoDTO>

Sorry, i didn't notice it in my first post. I think the
misunderstanding
came from that...

Best Regards,
Florent



Florent wrote:
Ok, i think i understand why you said my soap enveloppe in incorrect.

Here is the one i'm using (in my first post, i have to admit it wasn't
correct) :

<?xml version=\"1.0\" encoding=\"UTF-8\"?>
<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\";
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\";
xmlns:tns=\"http://ejb.proto.sopra.com\";>
<env:Body>
<tns:getProtoDTO>
< param>myparam</ param>
</tns:getProtoDTO>
</env:Body>
</env:Envelope>



Florent wrote:
this :

Standalone client <--> SOAP message <--> Servicemix cxf bc
consumer<--->
JBI message  <--->Servicemix Cxf bc provider <---> soap message
<-->Websphere
Application Server

is exactly what i want to be done (and what i'm trying to do) :)

According to your reply, i should use the following soap message :

<?xml version=\"1.0\" encoding=\"UTF-8\"?>
<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\";
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\";
xmlns:tns=\"http://ejb.proto.sopra.com\";>
<env:Body>
<tns:getProtoDTO>
<date>2007-11-27T10:04:16.347Z</date>
<dble>0.0</dble>
<integ>1</integ>
<liste>
<string>s01</string><string>s02</string><string>s03</string>
</liste>
</tns:getProtoDTO>
</env:Body>
</env:Envelope>

But, according to my wsdl, this is the response soap message, not the
request one !

Operation :
<wsdl:operation name="getProtoDTO">
       <wsdlsoap:operation soapAction="getProtoDTO"/>
       <wsdl:input name="getProtoDTORequest">
         <wsdlsoap:body use="literal"/>
      </wsdl:input>
       <wsdl:output name="getProtoDTOResponse">
         <wsdlsoap:body use="literal"/>
      </wsdl:output>
</wsdl:operation>

PortType :
<wsdl:portType name="ProtoBean">
     <wsdl:operation name="getProtoDTO">
       <wsdl:input message="intf:getProtoDTORequest"
name="getProtoDTORequest"/>
       <wsdl:output message="intf:getProtoDTOResponse"
name="getProtoDTOResponse"/>
    </wsdl:operation>
</wsdl:portType>


Input / request :
<wsdl:message name="getProtoDTORequest">
     <wsdl:part element="intf:getProtoDTO" name="parameters"/>
</wsdl:message>

Element :
<element name="getProtoDTO">
    <complexType>
     <sequence>
      <element name="param" nillable="true" type="xsd:string"/>
     </sequence>
    </complexType>
</element>

Output / response :
<wsdl:message name="getProtoDTOResponse">
     <wsdl:part element="intf:getProtoDTOResponse"
name="parameters"/>
</wsdl:message>

Element :
<element name="getProtoDTOResponse">
    <complexType>
     <sequence>
      <element name="getProtoDTOReturn" nillable="true"
type="tns2:ProtoDTO"/>
     </sequence>
    </complexType>
</element>

So, the output is the ProtoDTO complex type, and the input is a
string.
Did i misunderstand something? May be i'm confusing provider/consumer
role?




Freeman Fang wrote:
Comments in line

Florent wrote:
Morning Freeman,

I tried to modify my SOAP message, but it didn't work : i still get
the
same
error.

What's your new soap message now?
I also tried to call the web service with this enveloppe and a
standalone
client : i got a "wrong parameter error".

I think my SOAP message is correct : i tried to generate it from
the
RAD 7
web service test and it was the same one. Plus, my business method
has
one
parameter (a string) and a complex type as return type.

According to the schema from your wsdl, your soap messge
<getProtoDTO>ddd</getProteDTO> is not correct, under <getProtoDTO>
element, there should be element <date> or <dble> or <integ> or
<liste>
Btw, different soap tool kit may generate soap message with little
different, which may cause interoperability problem

As i'm totally new to servicemix, so there is probably something i
don't
understand.

What i want to do :
SOAP message <--> Servicemix cxf bc <---> SOAP message
<-->Websphere
Application Server

Considering the debug log, what i think it's going on :
SOAP message <--> Servicemix cxf bc <---> JBI message <-->Websphere
Application Server

no, what's going on is

SOAP message <--> Servicemix cxf bc consumer<---> JBI message
<--->Servicemix Cxf bc provider <---> soap message <-->Websphere
Application Server

So what's reach your websphere application server is soap message,
not
jbi message.
May be you need refer to [1]  which is similiar as your scenario
[1]

http://svn.apache.org/repos/asf/servicemix/trunk/deployables/bindingcomponents/servicemix-cxf-bc/src/test/java/org/apache/servicemix/cxfbc/CxfBcProviderConsumerTest.java
So, i don't think WAS support JBI message... and that could explain
my
error
(i no longer think it's a soap verion problem).

http://localhost:9080/PROTOServiceMixWeb/services/ProtoBean = thrid
party
web service URL.
http://localhost:8092/ProtoBeanService/ = servicemix web service.

I only want to call my web service, but i want to call it using a
servicemix
URL.

Thanks again for your help,
Best Regards,
Florent.



Freeman Fang wrote:

Hi Florent,

This problem has nothing to do with soap version.

The problem is that your hard code soap request message is not
correct.

According to the schema in wsdl you append, it should be something
like

<env:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:en
v="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/
XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns:tns="http
://ejb.proto.mycompany.com"><env:Body><tns:getProtoDTO>
<date>your date</date>
<dble>your dble</dble>
<integ>your integ</integ>
<liste>your liste</liste>
</tns:getPr
otoDTO></env:Body></env:Envelope>

You shouldn't use
<tns:getProtoDTO>something</tns:getProtoDTO> directly without
element
tag
defined in the schema.
For some complex schema, write soap message yourself is not so
easy,
so we
prefer to use some soap tool kit to generate soap message for you,
may
be
you can  try to use apache cxf, basically generate code stub from
the
wsdl, and what you need do is just write client invoke code as
normal
java
operation invoke and  cxf will genearate soap message for you.

Would you please try it again?

Best Regards

Freeman




Florent wrote:

Hi Freeman,

Indeed,
http://localhost:9080/PROTOServiceMixWeb/services/ProtoBean
use
soap
1.1.
But i don't know which soap version
http://localhost:8092/ProtoBeanService/
is using...

The third party webservice is hosted by Websphere Application
Server
6.1.

I don't really know what cxf is doing to the message, is it
possible
to
log/trace it?

I enabled debug log and added interceptors in my xbean.xml, here
is
the
output :

INFO: Inbound Message
--------------------------------------
Encoding: utf-8
Headers: {Content-Length=[353], User-Agent=[IBM WebServices/1.0],
Host=[ITEM-509
73:8092], connection=[Keep-Alive], Date=[Mon, 26 Nov 2007
08:59:47
GMT],
SOAPAct
ion=[], Pragma=[no-cache], content-type=[text/xml;
charset=utf-8],
Cache-Control
=[no-cache],
Accept=[application/soap+xml,multipart/related,text/*]}
Message:
<env:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:en
v="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/
XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns:tns="http

://ejb.proto.mycompany.com"><env:Body><tns:getProtoDTO>ddd</tns:getPr
otoDTO></env:Body></env:Envelope>
--------------------------------------
DEBUG - CxfBcComponent                 - Created correlation id:
ID:172.16.180.193-1167b1f58b2-4:1
DEBUG - DeliveryChannelImpl            - SendSync
ID:172.16.180.193-1167b1f58b2-4:1 in
DeliveryChannel{servicemix-cxf-bc}
DEBUG - SedaFlow                       - Called Flow send
DEBUG - DeliveryChannelImpl            - Waiting for exchange
ID:172.16.180.193-1167b1f58b2-4:1 (1d7a7b3) to be answered in
DeliveryChannel{servicemix-cxf-bc} from sendSync
DEBUG - SedaQueue                      -
[EMAIL PROTECTED]
dequeued
exchange: InOut[
  id: ID:172.16.180.193-1167b1f58b2-4:1
  status: Active
  role: provider
  interface: {http://ejb.proto.mycompany.com}ProtoBean
  service: {http://ejb.proto.mycompany.com}ProtoBeanService
  endpoint: ProtoBean
  operation: {http://ejb.proto.mycompany.com}getProtoDTO
  in: <?xml version="1.0" encoding="UTF-8"?><jbi:message
xmlns:jbi="http://java.
sun.com/xml/ns/jbi/wsdl-11-wrapper"
xmlns:msg="http://ejb.proto.mycompany.com"; name=
"getProtoDTORequest" type="msg:getProtoDTORequest"
version="1.0"><jbi:part><tns:
getProtoDTO
xmlns:tns="http://ejb.proto.mycompany.com";>ddd</tns:getPr
otoDTO></jbi:part></jbi:message>
]
DEBUG - CxfBcComponent                 - Received exchange:
status:
Active,
role: provider
DEBUG - CxfBcComponent                 - Retrieved correlation
id:
ID:172.16.180.193-1167b1f58b2-4:1
DEBUG - DeliveryChannelImpl            - Send
ID:172.16.180.193-1167b1f58b2-4:1in
DeliveryChannel{servicemix-cxf-bc}
DEBUG - SedaFlow                       - Called Flow send
DEBUG - SedaQueue                      -
[EMAIL PROTECTED]
dequeued
exchange: InOut[
  id: ID:172.16.180.193-1167b1f58b2-4:1
  status: Active
  role: consumer
  interface: {http://ejb.proto.mycompany.com}ProtoBean
  service: {http://ejb.proto.mycompany.com}ProtoBeanService
  endpoint: ProtoBean
  operation: {http://ejb.proto.mycompany.com}getProtoDTO
  in: <?xml version="1.0" encoding="UTF-8"?><jbi:message
xmlns:jbi="http://java.
sun.com/xml/ns/jbi/wsdl-11-wrapper"
xmlns:msg="http://ejb.proto.mycompany.com"; name=
"getProtoDTORequest" type="msg:getProtoDTORequest"
version="1.0"><jbi:part><tns:
getProtoDTO
xmlns:tns="http://ejb.proto.mycompany.com";>ddd</tns:getPr
otoDTO></jbi:part></jbi:message>
  out: null
]
DEBUG - DeliveryChannelImpl            - Notifying exchange
ID:172.16.180.193-1167b1f58b2-4:1(1d7a7b3) in
DeliveryChannel{servicemix-cxf-bc} from
processInboundSynchronousExchange
DEBUG - DeliveryChannelImpl            - Notified:
ID:172.16.180.193-1167b1f58b2-4:1(1d7a7b3) in
DeliveryChannel{servicemix-cxf-bc} from sendSync
26 nov. 2007 09:59:48
org.apache.cxf.interceptor.LoggingOutInterceptor$LoggingCallback
onClose
INFO: Outbound Message
--------------------------------------
<soap:Envelope
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";><soap:Body
 /></soap:Envelope>
--------------------------------------
DEBUG - DeliveryChannelImpl            - Send
ID:172.16.180.193-1167b1f58b2-4:1
in DeliveryChannel{servicemix-cxf-bc}
DEBUG - SedaFlow                       - Called Flow send
DEBUG - SedaQueue                      -
[EMAIL PROTECTED]
dequeued
exchange: InOut[
  id: ID:172.16.180.193-1167b1f58b2-4:1
  status: Done
  role: provider
  interface: {http://ejb.proto.mycompany.com}ProtoBean
  service: {http://ejb.proto.mycompany.com}ProtoBeanService
  endpoint: ProtoBean
  operation: {http://ejb.proto.mycompany.com}getProtoDTO
  in: <?xml version="1.0" encoding="UTF-8"?><jbi:message
xmlns:jbi="http://java.
sun.com/xml/ns/jbi/wsdl-11-wrapper"
xmlns:msg="http://ejb.proto.mycompany.com"; name=
"getProtoDTORequest" type="msg:getProtoDTORequest"
version="1.0"><jbi:part><tns:
getProtoDTO
xmlns:tns="http://ejb.proto.mycompany.com";>ddd</tns:getPr
otoDTO></jbi:part></jbi:message>
  out: null
]
DEBUG - CxfBcComponent                 - Received exchange:
status:
Done,
role:provider
DEBUG - CxfBcComponent                 - Retrieved correlation
id:
ID:172.16.180.193-1167b1f58b2-4:1
javax.jbi.messaging.MessagingException: Out not supported
        at

org.apache.servicemix.jbi.messaging.MessageExchangeImpl.setMessage(MessageExchangeImpl.java:357)
        at

org.apache.servicemix.cxfbc.CxfBcProviderMessageObserver.onMessage(CxfBcProviderMessageObserver.java:125)
        at

org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1932)
        at

org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1790)
        at

org.apache.servicemix.cxfbc.CxfBcProvider.process(CxfBcProvider.java:166)
        at

org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:538)
        at

org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:490)
        at

org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:46)
        at

org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:610)
        at

org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:170)
        at

org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:167)
        at

org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
        at

java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
        at

java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
        at java.lang.Thread.run(Thread.java:595)



Here is my wsdl used by servicemix (the one used by the AS is the
same
one,
except the service location) :

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions
targetNamespace="http://ejb.proto.mycompany.com";
 xmlns:impl="http://ejb.proto.mycompany.com";
 xmlns:intf="http://ejb.proto.mycompany.com";
 xmlns:tns2="http://dto.proto.mycompany.com";
 xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
 xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/";
 xmlns:wsi="http://ws-i.org/profiles/basic/1.1/xsd";
 xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
 <wsdl:types>
         <schema targetNamespace="http://ejb.proto.mycompany.com";
                 xmlns="http://www.w3.org/2001/XMLSchema";
                 xmlns:tns2="http://dto.proto.mycompany.com";
                 xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
                 xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
                 <import
namespace="http://dto.proto.mycompany.com"; />
                 <element name="getProtoDTOResponse">
                         <complexType>
                                 <sequence>
                                         <element
name="getProtoDTOReturn"
                                                 nillable="true"
type="tns2:ProtoDTO" />
                                 </sequence>
                         </complexType>
                 </element>
                 <element name="getProtoDTO">
                         <complexType>
                                 <sequence>
                                         <element name="param"
nillable="true"
type="xsd:string"
/>
                                 </sequence>
                         </complexType>
                 </element>
                 <complexType name="ArrayOf_xsd_nillable_string">
                         <sequence>
                                 <element maxOccurs="unbounded"
minOccurs="0"
                                         name="string"
nillable="true" type="xsd:string" />
                         </sequence>
                 </complexType>
         </schema>
         <schema targetNamespace="http://dto.proto.mycompany.com";
                 xmlns="http://www.w3.org/2001/XMLSchema";
                 xmlns:intf="http://ejb.proto.mycompany.com";
                 xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
                 xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
                 <import
namespace="http://ejb.proto.mycompany.com"; />
                 <complexType name="ProtoDTO">
                         <sequence>
                                 <element name="date"
nillable="true"
                                         type="xsd:dateTime" />
                                 <element name="dble"
nillable="true"
                                         type="xsd:double" />
                                 <element name="integ"
type="xsd:int" />
                                 <element name="liste"
nillable="true"
type="impl:ArrayOf_xsd_nillable_string" />
                         </sequence>
                 </complexType>
         </schema>
 </wsdl:types>

 <wsdl:message name="getProtoDTORequest">
         <wsdl:part element="intf:getProtoDTO" name="parameters"
/>
 </wsdl:message>

 <wsdl:message name="getProtoDTOResponse">
         <wsdl:part element="intf:getProtoDTOResponse"
name="parameters" />
 </wsdl:message>

 <wsdl:portType name="ProtoBean">
         <wsdl:operation name="getProtoDTO">
                 <wsdl:input message="intf:getProtoDTORequest"
                         name="getProtoDTORequest" />

                 <wsdl:output message="intf:getProtoDTOResponse"
                         name="getProtoDTOResponse" />

         </wsdl:operation>

 </wsdl:portType>

 <wsdl:binding name="ProtoBeanSoapBinding" type="intf:ProtoBean">

         <wsdlsoap:binding style="document"
                 transport="http://schemas.xmlsoap.org/soap/http";
/>
         <wsdl:operation name="getProtoDTO">
                 <wsdlsoap:operation soapAction="getProtoDTO" />

                 <wsdl:input name="getProtoDTORequest">
                         <wsdlsoap:body use="literal" />

                 </wsdl:input>

                 <wsdl:output name="getProtoDTOResponse">
                         <wsdlsoap:body use="literal" />

                 </wsdl:output>

         </wsdl:operation>

 </wsdl:binding>

 <wsdl:service name="ProtoBeanService">
         <wsdl:port binding="intf:ProtoBeanSoapBinding"
                 name="ProtoBean">
                 <wsdlsoap:address
location="http://localhost:8092/ProtoBeanService/"; />
         </wsdl:port>

 </wsdl:service>

</wsdl:definitions>

Thanks in advance,
Florent.


Freeman Fang-2 wrote:


Hi Florent,
Do you mean
http://localhost:9080/PROTOServiceMixWeb/services/ProtoBean use
soap1.1 and http://localhost:8092/ProtoBeanService/  use soap
1.2?
Which soap toolkit are the third party webservice using?
Would you please append the wsdl used for two webservices?

Best Regards

Freeman


Florent wrote:


If i use the following code to access to my web service, it
works
fine
:

String endpoint =
"http://localhost:9080/PROTOServiceMixWeb/services/ProtoBean";;

String xml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" +
                                               "<env:Envelope
xmlns:env=\"http://schemas.xmlsoap.org/soap/envelope/\";
" +
"xmlns:tns=\"http://ejb.proto.mycompany.com\";>" +
                               "<env:Body>" +
                               "<tns:getProtoDTO>" +

"<tns:getProtoDTORequest>0</tns:getProtoDTORequest>" +
                               "</tns:getProtoDTO>" +
                                               "</env:Body>" +
"</env:Envelope>";
               MessageFactory mf =
MessageFactory.newInstance();
               SOAPMessage smsg = mf.createMessage(new
MimeHeaders(), new
ByteArrayInputStream(xml.getBytes()));

               SOAPConnection conn =
SOAPConnectionFactory.newInstance().createConnection();
        SOAPMessage response = conn.call(smsg, url);

        SOAPEnvelope env =
response.getSOAPPart().getEnvelope();


If i try to call the fellowing url :
http://localhost:8092/ProtoBeanService/
i get an error : No SOAPAction header (Application server
log)...
That's
why
i was wondering about the soap version.

I get the following error in servicemix log :

javax.jbi.messaging.MessagingException: Out not supported
        at

org.apache.servicemix.jbi.messaging.MessageExchangeImpl.setMessage(MessageExchangeImpl.java:357)
        at

org.apache.servicemix.cxfbc.CxfBcProviderMessageObserver.onMessage(CxfBcProviderMessageObserver.java:125)
        at

org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1932)
        at

org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1790)
        at

org.apache.servicemix.cxfbc.CxfBcProvider.process(CxfBcProvider.java:166)
        at

org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:538)
        at

org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:490)
        at

org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:46)
        at

org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:610)
        at

org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:170)
        at

org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:167)
        at

org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
        at

java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
        at

java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
        at java.lang.Thread.run(Thread.java:595)


Any idea?

Thank you in advance,
Florent.



Freeman Fang wrote:



Hi,

You needn't specify it in cxf bc endpint configuration. Cxf bc
should
support both of it by default.
Cxf bc will parse the wsdl you provided and create service
model
accordingly, extract soap version from your wsdl binding part.

Best Regards

Freeman


Florent wrote:



Hello,

I'm trying to expose a third party webservice to the bus,
using
cxf.

I'd like to know if i can set the soap version. For example,
when
i
was
using service-http, there was a SoapVersion attribute, but i
didn't
find
one
for the servicemix-cxf-bc-3.2-schema.

Is soap 1.1 or 1.2 used?

Here is my xbean.xml :

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns:cxfbc="http://servicemix.apache.org/cxfbc/1.0";
       xmlns:ns1="http://ejb.proto.mycompany.com";>

      <cxfbc:consumer
                        wsdl="classpath:ProtoBean.wsdl"
                        endpoint="ProtoBeanPort"
                        targetEndpoint="ProtoBean"
                        targetService="ns1:ProtoBeanService"
                        targetInterface="ns1:ProtoBean"
                        >
      </cxfbc:consumer>

      <cxfbc:provider
                        wsdl="classpath:ProtoBean.wsdl"


locationURI="http://localhost:9080/PROTOServiceMixWeb/services/ProtoBean";
                        service="ns1:ProtoBeanService"
                        endpoint="ProtoBean"
                        interfaceName="ns1:ProtoBean"
                        >
      </cxfbc:provider>

</beans>






--
View this message in context:
http://www.nabble.com/servicemix-cxf-bc---soapVersion-attribute-tf4860627s12049.html#a13969473

Sent from the ServiceMix - User mailing list archive at Nabble.com.



Reply via email to