You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by "Steven E. Harris" <se...@panix.com> on 2007/05/01 03:22:25 UTC
Client dependency on Jetty
Per this message in the February 2007 thread entitled "HTTP
dependency/decoupling issue", Jetty is supposed to be an optional
dependency for the client side:
http://mail-archives.apache.org/mod_mbox/incubator-cxf-dev/200702.mbox/%3cFA1787F64A095C4090E76EBAF8B183E071FBDE@owa-emea.iona.com%3e
Specifically, it says:
Of course, there may still be a client-side runtime dependency on
Jetty if the client is configured to launch a decoupled response
endpoint.
When I try to start my client and invoke a SOAP-over-HTTP operation
without the Jetty dependency on my class path, I see the following
exception:
,----
| javax.xml.ws.WebServiceException: org.apache.cxf.interceptor.Fault: No conduit initiator was found for the namepsace http://schemas.xmlsoap.org/soap/http.
| [...]
| Caused by: org.apache.cxf.interceptor.Fault: No conduit initiator was found for the namepsace http://schemas.xmlsoap.org/soap/http.
| at org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(AbstractConduitSelector.java:89)
| at org.apache.cxf.endpoint.UpfrontConduitSelector.prepare(UpfrontConduitSelector.java:62)
| at org.apache.cxf.endpoint.ClientImpl.prepareConduitSelector(ClientImpl.java:369)
| at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:212)
| at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
| at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:125)
| ... 7 more
| Caused by: org.apache.cxf.BusException: No conduit initiator was found for the namepsace http://schemas.xmlsoap.org/soap/http.
| at org.apache.cxf.transport.ConduitInitiatorManagerImpl.getConduitInitiator(ConduitInitiatorManagerImpl.java:96)
| at org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(AbstractConduitSelector.java:71)
| ... 12 more
`----
What do I have to do to configure my client to not "launch a decoupled
response endpoint", if that is indeed what's causing this failure?
That is, my goal is to not rely on Jetty if it's possible not to.
--
Steven E. Harris
Re: Client dependency on Jetty
Posted by Polar Humenn <ph...@iona.com>.
Daniel Kulp wrote:
> The last option would be to make the "Destination" stuff in http
> plugable. The jetty stuff just provides a HttpDestinationProvider or
> something into the http module. Jetty wouldn't subclass the http
> factory or anything. It just provides functionality into the existing
> http one.
>
>
> Any thoughts?
This is sort of the problem I voiced with the split, that it didn't go
far enough, although especially for different implementations of
HTTPConduit.
I don't think you have to go as far as having a HTTPDestinationProvider.
I didn't understand the need to make a HTTPTransportFactory both a
Conduit Initiator and a Destination Factory. The ConduitInitiator and
Destination can be separate entities and "registered" as such, can't
they? or is that a namespace problem?
Cheers,
-Polar
Re: Client dependency on Jetty
Posted by "Steven E. Harris" <se...@panix.com>.
Daniel Kulp <dk...@apache.org> writes:
> The last option would be to make the "Destination" stuff in http
> plugable. The jetty stuff just provides a HttpDestinationProvider
> or something into the http module. Jetty wouldn't subclass the http
> factory or anything. It just provides functionality into the
> existing http one.
>
> Any thoughts?
Without grasping too well what all these entities are, being too new
to CXF, this last option still sounds like the best solution with the
least coupling.
I take it "destinations" are related to listening endpoints, or
servers? If I'm writing a client, and I have no server-style behavior,
then I should be able to use the HTTP module and have all I need.
If the Jetty module wants to reuse or plug in to parts of the HTTP
module, that's fine; one could combine the two of them or not, just
like any other layered and dependent modules.
--
Steven E. Harris
Re: Client dependency on Jetty
Posted by Daniel Kulp <dk...@apache.org>.
Dan and Steven,
It's probably my fault. (actually, I'm pretty sure it IS my fault)
The cxf-rt-transport-http module doesn't register any transports on any
namespaces by default. It kind of avoids the whole "which jar is
first" issue. Thus, if you don't have the http-jetty jar, nothing is
registered to handle the http cases.
Also, the factory in the http module is abstract. It couldn't be
instantiated anyway.
So, I'm not sure how to proceed. We could create a new http-conduitonly
module that does do the registration with a factory that cannot do
destinations. That would be quick and easy. There would be the issue
of what happens if both are available.
We could make the factory in http non-abstract and have it register it,
but then we have the issue of how does the jetty version override that.
What happens if http is before http-jetty and vice versa.
The last option would be to make the "Destination" stuff in http
plugable. The jetty stuff just provides a HttpDestinationProvider or
something into the http module. Jetty wouldn't subclass the http
factory or anything. It just provides functionality into the existing
http one.
Any thoughts?
Dan
On Friday 04 May 2007 12:20, Steven E. Harris wrote:
> "Steven E. Harris" <se...@panix.com> writes:
> > I just tested this again against the latest snapshots, and the Jetty
> > dependency is no longer required.
>
> Wait, I'm wrong. I had edited the wrong POM. My client still fails if
> I remove the cxf-rt-transports-http-jetty dependency. Here is my
> intended dependency set:
>
> <dependency>
> <groupId>org.apache.cxf</groupId>
> <artifactId>cxf-rt-frontend-jaxws</artifactId>
> <scope>runtime</scope>
> </dependency>
> <dependency>
> <groupId>org.apache.cxf</groupId>
> <artifactId>cxf-rt-transports-http</artifactId>
> <scope>runtime</scope>
> </dependency>
> <dependency>
> <groupId>org.apache.cxf</groupId>
> <artifactId>cxf-rt-bindings-soap</artifactId>
> <scope>runtime</scope>
> </dependency>
> <dependency>
> <groupId>org.apache.cxf</groupId>
> <artifactId>cxf-rt-ws-addr</artifactId>
> <scope>runtime</scope>
> </dependency>
> <dependency>
> <groupId>org.apache.cxf</groupId>
> <artifactId>cxf-rt-ws-policy</artifactId>
> <scope>runtime</scope>
> </dependency>
>
> When I run the client with these dependencies, I see the following
> error:
>
> ,----
>
> | javax.xml.ws.WebServiceException: org.apache.cxf.interceptor.Fault:
> | No conduit initiator was found for the namepsace
> | http://schemas.xmlsoap.org/soap/http. at
> | org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:1
> |42) at $Proxy38.myService(Unknown Source)
> | at my.service.CXFClient.main(CXFClient.java:72)
> | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> | at
> | sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl
> |.java:39) at
> | sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcce
> |ssorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597)
> | at
> | com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
> | Caused by: org.apache.cxf.interceptor.Fault: No conduit initiator
> | was found for the namepsace http://schemas.xmlsoap.org/soap/http. at
> | org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(A
> |bstractConduitSelector.java:89) at
> | org.apache.cxf.endpoint.UpfrontConduitSelector.prepare(UpfrontCondui
> |tSelector.java:62) at
> | org.apache.cxf.endpoint.ClientImpl.prepareConduitSelector(ClientImpl
> |.java:393) at
> | org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:227) at
> | org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:181) at
> | org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
> | at
> | org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:1
> |24) ... 8 more
> | Caused by: org.apache.cxf.BusException: No conduit initiator was
> | found for the namepsace http://schemas.xmlsoap.org/soap/http. at
> | org.apache.cxf.transport.ConduitInitiatorManagerImpl.getConduitIniti
> |ator(ConduitInitiatorManagerImpl.java:96) at
> | org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(A
> |bstractConduitSelector.java:70) ... 14 more
>
> `----
>
> I'm not sure if it matters, but I have an entry in my cxf.xml file
> defining a jaxws:client with id "{service namespace}port name" and the
> "createdFromAPI" attribute set to "true".
>
> Adding the Jetty dependency back in eliminates the problem.
--
J. Daniel Kulp
Principal Engineer
IONA
P: 781-902-8727 C: 508-380-7194
daniel.kulp@iona.com
http://www.dankulp.com/blog
Re: Client dependency on Jetty
Posted by "Steven E. Harris" <se...@panix.com>.
"Steven E. Harris" <se...@panix.com> writes:
> I just tested this again against the latest snapshots, and the Jetty
> dependency is no longer required.
Wait, I'm wrong. I had edited the wrong POM. My client still fails if
I remove the cxf-rt-transports-http-jetty dependency. Here is my
intended dependency set:
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-jaxws</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-transports-http</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-bindings-soap</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-addr</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-ws-policy</artifactId>
<scope>runtime</scope>
</dependency>
When I run the client with these dependencies, I see the following
error:
,----
| javax.xml.ws.WebServiceException: org.apache.cxf.interceptor.Fault: No conduit initiator was found for the namepsace http://schemas.xmlsoap.org/soap/http.
| at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:142)
| at $Proxy38.myService(Unknown Source)
| at my.service.CXFClient.main(CXFClient.java:72)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
| Caused by: org.apache.cxf.interceptor.Fault: No conduit initiator was found for the namepsace http://schemas.xmlsoap.org/soap/http.
| at org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(AbstractConduitSelector.java:89)
| at org.apache.cxf.endpoint.UpfrontConduitSelector.prepare(UpfrontConduitSelector.java:62)
| at org.apache.cxf.endpoint.ClientImpl.prepareConduitSelector(ClientImpl.java:393)
| at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:227)
| at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:181)
| at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
| at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:124)
| ... 8 more
| Caused by: org.apache.cxf.BusException: No conduit initiator was found for the namepsace http://schemas.xmlsoap.org/soap/http.
| at org.apache.cxf.transport.ConduitInitiatorManagerImpl.getConduitInitiator(ConduitInitiatorManagerImpl.java:96)
| at org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(AbstractConduitSelector.java:70)
| ... 14 more
`----
I'm not sure if it matters, but I have an entry in my cxf.xml file
defining a jaxws:client with id "{service namespace}port name" and the
"createdFromAPI" attribute set to "true".
Adding the Jetty dependency back in eliminates the problem.
--
Steven E. Harris
Re: Client dependency on Jetty
Posted by "Steven E. Harris" <se...@panix.com>.
Dan Diephouse <da...@envoisolutions.com> writes:
> Did you ever get this sorted? I am very concerned if this is
> actually the case and will have to spend some time fixing this.
I just tested this again against the latest snapshots, and the Jetty
dependency is no longer required. Thanks for reminding me to recheck
that one.
--
Steven E. Harris
Re: Client dependency on Jetty
Posted by Dan Diephouse <da...@envoisolutions.com>.
Steve,
Did you ever get this sorted? I am very concerned if this is actually the
case and will have to spend some time fixing this.
- Dan
On 5/1/07, Steven E. Harris <se...@panix.com> wrote:
>
> Per this message in the February 2007 thread entitled "HTTP
> dependency/decoupling issue", Jetty is supposed to be an optional
> dependency for the client side:
>
>
> http://mail-archives.apache.org/mod_mbox/incubator-cxf-dev/200702.mbox/%3cFA1787F64A095C4090E76EBAF8B183E071FBDE@owa-emea.iona.com%3e
>
> Specifically, it says:
>
> Of course, there may still be a client-side runtime dependency on
> Jetty if the client is configured to launch a decoupled response
> endpoint.
>
> When I try to start my client and invoke a SOAP-over-HTTP operation
> without the Jetty dependency on my class path, I see the following
> exception:
>
> ,----
> | javax.xml.ws.WebServiceException: org.apache.cxf.interceptor.Fault: No
> conduit initiator was found for the namepsace
> http://schemas.xmlsoap.org/soap/http.
> | [...]
> | Caused by: org.apache.cxf.interceptor.Fault: No conduit initiator was
> found for the namepsace http://schemas.xmlsoap.org/soap/http.
> | at
> org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(
> AbstractConduitSelector.java:89)
> | at org.apache.cxf.endpoint.UpfrontConduitSelector.prepare(
> UpfrontConduitSelector.java:62)
> | at org.apache.cxf.endpoint.ClientImpl.prepareConduitSelector(
> ClientImpl.java:369)
> | at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:212)
> | at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java
> :73)
> | at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(
> JaxWsClientProxy.java:125)
> | ... 7 more
> | Caused by: org.apache.cxf.BusException: No conduit initiator was found
> for the namepsace http://schemas.xmlsoap.org/soap/http.
> | at
> org.apache.cxf.transport.ConduitInitiatorManagerImpl.getConduitInitiator(
> ConduitInitiatorManagerImpl.java:96)
> | at
> org.apache.cxf.endpoint.AbstractConduitSelector.getSelectedConduit(
> AbstractConduitSelector.java:71)
> | ... 12 more
> `----
>
> What do I have to do to configure my client to not "launch a decoupled
> response endpoint", if that is indeed what's causing this failure?
> That is, my goal is to not rely on Jetty if it's possible not to.
>
> --
> Steven E. Harris
>
--
Dan Diephouse
Envoi Solutions
http://envoisolutions.com | http://netzooid.com/blog