|
Replies:
41
-
Last Post:
Aug 2, 2011 10:51 PM
Last Post By: chandraprabha
|
|
|
Posts:
27
Registered:
01/06/11
|
|
|
|
SOAPFaultException: Could not find conduit initiator for transport
Posted:
Feb 19, 2011 11:05 PM
|
|
|
|
|
|
I've tried to run external ws but i've received this error message:
SOAPFaultException: Could not find conduit initiator for transport http://schemas.xmlsoap.org/soap/http
Any idea where should be the problem ?
Whole log file as attachement.
Thanks for any response.
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Feb 20, 2011 1:10 AM
in response to: nohaapav
|
|
|
|
How,
Could you provide more about your scenario.
I assume you use a customer bundle to connect a external webservice, your customer bundle play the role as a client side, is it correct?
If so, how you configure your client? Do you use spring file to configure your client?
If you use spring file, this exception could be caused by missing
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
Freeman
|
|
|
|
|
Posts:
572
Registered:
09/17/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Feb 20, 2011 10:08 AM
in response to: ffang
|
|
|
You also need to include the CXF bus definition cxf.xml like this
<import resource="classpath:META-INF/cxf/cxf.xml"/>
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
Willem
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 9, 2011 8:51 PM
in response to: njiang
|
|
|
|
Please help ...
I am also getting the same error " Could not find conduit initiator for transport http://schemas.xmlsoap.org/soap/http"
so i have added follwing import in cfxse but still I am getting the same error
<import resource="classpath:META-INF/cxf/cxf.xml"/>
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http-jetty.xml" />
I have noticed that while compiling the code I get
Caused by: java.lang.NoSuchFieldError: activationNamespaces
at org.apache.cxf.transport.http_jetty.JettyHTTPTransportFactory.finalizeConfig(JettyHTTPTransportFactory.java:62)
... 47 more
|
|
|
|
|
Posts:
572
Registered:
09/17/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 9, 2011 11:51 PM
in response to: chandraprabha
|
|
|
|
It looks like you have more than one version of CXF in your classpath.
Can you double check it?
BTW, I don't think your cxf-se need to use the these kind of configuration, as SE don't need the http transport implementation.
Willem
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 10, 2011 12:12 AM
in response to: njiang
|
|
|
|
Thanks for the response.
What I am trying to do is :
I have a cfxbc-> cfxse ->Business logic
in business logic .
I have two methods one of them call third party webservice.
To call third party webservice I have created the stub using cfx-code-gen plugin. so when I am calling this method i am getting the error.
Kindly let me know if i am doing some thing wrong.
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 10, 2011 12:37 AM
in response to: chandraprabha
|
|
|
|
Hi,
You shouldn't call external webservice directly from cxf se endpoint, this cause the error.
You need use cxfbc:provider to do so.
The correct working flow should be
cxfbc consumer-->cxf se--->cxf se proxy--->cxf bc provider.
Btw, it is cxf but not cfx.
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 11, 2011 12:00 AM
in response to: ffang
|
|
|
|
Thanks for the response.
Could you please let me know if there is any example on this.
Internal webservice and external webservice
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 11, 2011 2:13 AM
in response to: chandraprabha
|
|
|
|
Hi,
Take a look at CxfBcProviderTest, which demostrate how to use cxfse:proxy to call a cxf bc provider.
[1]https://svn.apache.org/repos/asf/servicemix/components/trunk/bindings/servicemix-cxf-bc/src/test/java/org/apache/servicemix/cxfbc/CxfBcProviderTest.java
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 19, 2011 7:47 PM
in response to: ffang
|
|
|
|
Thanks a lot for info.
i have configure cxfse endpoint to use proxy as
<cxfse:endpoint>
<cxfse:pojo>
<bean class="com.TestProxy">
<property name="address">
<cxfse:proxy service="m:Service"
endpoint="Service" type="com.IService" />
</property>
</bean>
</cxfse:pojo>
</cxfse:endpoint>
now i am getting error :
Caused by: org.springframework.context.ApplicationContextException: Failed to load configuration META-INF/cxf/transport/jbi/cxf-transport-jbi.xml
and when i add context in cfxse i get context not found .
Please help.
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 12:14 AM
in response to: chandraprabha
|
|
|
|
Hi,
You're using OSGi package or JBI package?
If JBI package, you need put cxf-rt-transports-jbi dependency into your pom.
And you needn't put "context" in cxf se, it's already inject automatically for you.
Btw, it's "cxf" but not "cfx".
Freeman
Edited by: ffang on May 20, 2011 12:20 AM
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 3:43 AM
in response to: ffang
|
|
|
|
Sorry for typo.
I am using osgi .
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 3:49 AM
in response to: ffang
|
|
|
|
Do you already have package import like
META-INF.cxf?
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 5:07 AM
in response to: ffang
|
|
|
import i have are
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http-binding.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
Still geting the errror
I have one question ... does consume will call cxfse endpoint and then provider.?
My config are as follows:
Consumer:
<cxfbc:consumer wsdl="classpath:wsdl/Service.wsdl"
targetService="m:Service" interfaceName="m:IService"
locationURI="http://localhost:8092/Service/PhysicalAddressValidationWs/" />
CXFSE:
<cxfse:endpoint>
<cxfse:pojo>
<bean class="com.ServiceImplProxy">
<property name="physicalAddress">
<cxfse:proxy service="m:Service"
endpoint="Service" type="com.IService" >
</cxfse:proxy>
</property>
</bean>
</cxfse:pojo>
</cxfse:endpoint>
Provider as :
<cxfbc:provider wsdl="classpath:wsdl/Service.wsdl"
locationURI="https://SErver1.net/v2/SOAP/Service.svc"
endpoint="Service" service="m:Service" interfaceName="m:IService" />
I am still getting
Caused by: java.lang.RuntimeException: org.springframework.context.ApplicationContextException: Failed to load configuration META-INF/cxf/transport/jbi/cxf-transport-jbi.xml
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 10, 2011 12:07 AM
in response to: chandraprabha
|
|
|
|
Hi,
It confused me a little but because cxf se endpoint doesn't need http transport, so you needn't import such files.
Could you elaborate your working flow, how you use the cxf se endpoint? Did you expose a webservice through http-jetty endpoint directly in cxf se SEI? If so, that's not the correct way to use cxf se, you should use cxf bc to handle the external protocol stuff.
Do you use JBI packaging or OSGi packaing?
About the java.lang.NoSuchFieldError: activationNamespaces, generally it means cxf version mismatch, could you check if your dependency have more cxf version, you can use "mvn dependency:tree" to check it. Also you need ensure the cxf version used in your pom is same as it in the OSGi container.
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 10, 2011 12:27 AM
in response to: ffang
|
|
|
After removing the below lines i do not get the
" Caused by: java.lang.NoSuchFieldError: activationNamespaces
at org.apache.cxf.transport.http_jetty.JettyHTTPTransportFactory.finalizeConfig(JettyHTTPTransportFactory.java:62)" error any more
<import resource="classpath:META-INF/cxf/cxf.xml"/>
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http-jetty.xml" />
but when i try to invoke the webservice i get :
Could not find conduit initiator for transport http://schemas.xmlsoap.org/soap/http
********Application flow************
we are following config in cfxse:
<cxfse:endpoint>
<cxfse:pojo>
<bean id="test-webservice" class="com.test.TestService">
</cxfse:pojo>
</cxfse:endpoint>
And then we used the cfxbc (<cxfbc:consumer) component.
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 17, 2011 9:47 PM
in response to: chandraprabha
|
|
|
|
Thanks .I got the solution
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 13, 2011 10:52 PM
in response to: ffang
|
|
|
Thanks for the respose.
Please help me how i can achive this:
1.I have my own wsdl with some operations for which i have below flow
CXFBC:Consume -> CXFSE
2. Now i want to add one more operation in my WSDL which will call third party Webservice.
For that if I am using CXFBC:provider then how i can represent my internal + external together.
So If UI team want to access they get only one wsdl..
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 14, 2011 10:17 AM
in response to: chandraprabha
|
|
|
|
Hi,
The answer is it depends...
Normally you can't do it, as cxfbc:consumer target service/endpoint name is specified, so the target service/endpoint should be a certain endpoint so it can't be a cxf se and cxfbc:provider at the same time. So generally you need define two cxfbc:consumer endpoint, one for target cxfse, one for target cxfbc:provider.
However, there's a way can do it if your external client can set ws-addressing headers for sending soap request to the cxfbc:consumer, using this way, cxfbc consumer endpoint will retrieve the wsa:To headers and dynamically set the target JBI endpoint through it, so that you can dynamically determine which target jbi endpoint you want to dispatch per each request. It just need some work on your client side. You can get more details from[1], WS-Addressing part, also, here is a testcase[2] to demonstrate how it works, the testExplicitMAPsAddressTo.
Hope this helps.
[1]http://servicemix.apache.org/servicemix-cxf-bc.html
[2]http://svn.apache.org/repos/asf/servicemix/components/trunk/bindings/servicemix-cxf-bc/src/test/java/org/apache/servicemix/cxfbc/ws/addressing/CxfBcAddressingTest.java
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 17, 2011 8:55 PM
in response to: ffang
|
|
|
|
Thanks for the response.
I am trying to implement the first option. I am getting the wsdl returned but not able to call the operation. It fails with no end point . Please help
Steps i have followed are :
1. Generated the code using wsdl2java
2.created the cxfbc:provider as:
<cxfbc:provider wsdl="classpath:wsdl/MelissaService.wsdl"
locationURI="http://localhost:8092/SurveysavvyService/PhysicalWs/"
endpoint="Service"
service="melica:Service"
useJBIWrapper="false"
interfaceName="melica:IService"/>
3.consumer as
<cxfbc:consumer wsdl="classpath:wsdl/MelissaService.wsdl"
targetService="melica:Service" interfaceName="melica:IService"
locationURI="http://localhost:8092/SurveysavvyService/PhysicalWs/"
/>
my wsdl:
<wsdl:service name="Service">
<wsdl:port name="BasicHttpBinding_IService" binding="tns:BasicHttpBinding_IService">
<soap:address location="https://addresschecks.server1.net/v2/SOAP/Service.svc"/>
</wsdl:port>
</wsdl:service>
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 19, 2011 12:03 AM
in response to: ffang
|
|
|
|
Thanks a lot .
I got cxfbc consumer - cfxse end point (internal service )
cxfbc consumer - cfxbc provider (external webservice)
Could you please tell
How i can call the external service inside the internbal service
Thanks
Edited by: chandraprabha on May 19, 2011 12:08 AM
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 19, 2011 1:08 AM
in response to: chandraprabha
|
|
|
Hi,
First of all, it's CXF but not CFX 
You can use cxfse:proxy to call cxfbc:provider from cxf se endpoint, take a look at[1], "Proxies" part.
[1]http://servicemix.apache.org/servicemix-cxf-se.html
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 3:56 AM
in response to: ffang
|
|
|
Thanks a lot for help.
I have created the cxfse proxy as follows:
<osgi:reference id="servicemix-cxf-se" interface="javax.jbi.component.Component"
cardinality="1..1" filter="(NAME=servicemix-cxf-se)" />
<cxfse:endpoint>
<cxfse:pojo>
<bean class="com.addressImplProxy">
<property name="address">
<cxfse:proxy service="melissa:Service"
endpoint="Service" type="com.IService" >
<property name="component" ref="servicemix-cxf-se"/>
</cxfse:proxy>
</property>
</bean>
</cxfse:pojo>
</cxfse:endpoint>
<cxfbc:provider wsdl="classpath:wsdl/service.wsdl"
locationURI="https://server1.net/v2/SOAP/Service.svc"
endpoint="Service" service="melissa:Service" interfaceName="melissa:IService" />
now i am getting timed out
Unable to create application context for surveysavvy-member-webservice-se, unsatisfied dependencies: Dependency on http://(&(objectClass=org.apache.servicemix.jbi.runtime.ComponentRegistry)(NAME=servicemix-cxf-se)) (from bean &componentRegistry)
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 4:15 AM
in response to: chandraprabha
|
|
|
Hi,
I'm wondering what's the Fuse ESB version you're using, you run into a known issue which get fixed quite a while ago[1], could you use the latest FUSE ESB version?
[1]https://issues.apache.org/jira/browse/SMXCOMP-803
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 25, 2011 9:56 PM
in response to: ffang
|
|
|
Thanks a lot for the help.
I am able to call the proxy now
Is there any documentation on how to invoke provider from proxy instead of test class. it will really help..
Thanks
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 26, 2011 12:00 AM
in response to: chandraprabha
|
|
|
|
Hi,
Take a look at
http://servicemix.apache.org/servicemix-cxf-se.html
Proxies part.
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 27, 2011 3:23 AM
in response to: ffang
|
|
|
my proxy class is not getting called always some times from cxfbc consumer call goes to cxfbc provider directly .
Please help
<cxfbc:consumer wsdl="classpath:wsdl/Service.wsdl"
targetService="m:Service" interfaceName="m:IService"
targetEndpoint="PSProxy" locationURI="http://localhost:8092/Service/PhysicalAddressValidationWs/" />
<cxfse:endpoint endpoint="PSProxy">
<cxfse:pojo>
<bean class="com.ServiceImplProxy">
<property name="physicalAddress">
<cxfse:proxy service="m:Service" endpoint="Service" type="com.IService" > </cxfse:proxy>
</property>
<property name="component" ref="servicemix-cxf-se"/>
</bean>
</cxfse:pojo>
</cxfse:endpoint>
<cxfbc:provider wsdl="classpath:wsdl/Service.wsdl"
locationURI="https://server1.net/v2/SOAP/Service.svc"
endpoint="Service" service="m:Service" interfaceName="m:IService" />
<bean class="org.apache.servicemix.common.osgi.EndpointExporter" />
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 27, 2011 4:02 AM
in response to: chandraprabha
|
|
|
|
Hi,
This is because your cxf se endpoint and cxf bc provider endpoint use same servicename and endpointname, so the message dispatch become uncertain in this case, please ensure they use different servicename and endpointname.
Freeman
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Aug 2, 2011 10:51 PM
in response to: ffang
|
|
|
Thanks for reply.
i have made the proxy as specified in example but i am getting below error
org.apache.cxf.interceptor.Fault: Unmarshalling Error: unexpected element (uri:"urn:mdWebServiceAddress", local:"Address"). Expected elements are <{urn:mdWebServiceAddress}Zip>,<{urn:mdWebServiceAddress}AddressType
Proxy created as specified in
http://servicemix.apache.org/servicemix-cxf-se.html
so i am getting the type object and then calling the method on it.
|
|
|
|
|
Posts:
20
Registered:
03/07/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 22, 2011 11:39 AM
in response to: ffang
|
|
|
Hello,
I have the same issue, but I am not using any spring configuration file
Actually the WS part works fine (CXF/JAXWS in ServiceMix)
to create my client I did the following
I create a bundle activator and I added the few lines in the start method
JaxWsProxyFactoryBean factory = new JaxWsProxyFactoryBean();
factory.setServiceClass(Payments.class);
factory.setAddress("http://localhost:9090/Payments");
Payments payment=null;
//try catch..
payment = (Payments)factory.create();
//works fine payments is not NULL
//the same exception when i call my service
payment.transferFunds("ffff", "ttttt", 100);
any ideas ?
in my POM I only added these dependencies
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-jaxws</artifactId>
<version>${cxf.version}</version>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-transports-http</artifactId>
<version>${cxf.version}</version>
</dependency>
and for the Felix bnd plugin the following
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<instructions>
<Bundle-Activator>demo.osgi.HelloWorldActivator</Bundle-Activator>
<Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName>
<Import-Package>
* </Import-Package>
<!-- Update Private Package tag with appropriate package name -->
<Private-Package>
</Private-Package>
<Require-Bundle>org.apache.cxf.bundle</Require-Bundle>
<DynamicImport-Package>*</DynamicImport-Package>
</instructions>
</configuration>
</plugin>
I also hope to find some clarification on the following tags
<dependency> : I need to add any dependency for my project to be able to compile
<Import-Package>: ??
<DynamicImport-Package>: ??
I know those wil be translated in the META-INF descriptor but I have no clue which one I need if I am not following a sample or a tutorial
Thanks
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 22, 2011 12:47 PM
in response to: atlantix
|
|
|
|
Hi,
Your bundle Import-Package part should be more, at lease those should be there
javax.jws,
javax.xml.bind.annotation,
javax.wsdl,
javax.xml.namespace,
META-INF.cxf,
org.apache.cxf.bus,
org.apache.cxf.bus.spring,
org.apache.cxf.bus.resource,
org.apache.cxf.configuration.spring,
org.apache.cxf.resource,
org.apache.cxf.transport.http,
org.springframework.beans.factory.config,
org.apache.commons.logging
and generally you don't need use DynamicImport-Package
You can use osgi:headers your_customer_bundle_id to see the OSGi metadate.
Freeman
|
|
|
|
|
Posts:
20
Registered:
03/07/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 22, 2011 1:17 PM
in response to: ffang
|
|
|
Thanks for the reply
that fixed the first issue
but any idea why I would get a HTTP 404 error ??
this happens when I run both my client and my service in the same ServiceMix instance
karaf@root> javax.xml.ws.WebServiceException: Could not send Message.
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)
at $Proxy111.transferFunds(Unknown Source)
at demo.osgi.HelloWorldActivator.start(HelloWorldActivator.java:45)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:783)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:774)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:755)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:370)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:284)
at org.eclipse.osgi.framework.internal.core.PackageAdminImpl.resumeBundles(PackageAdminImpl.java:297)
at org.eclipse.osgi.framework.internal.core.PackageAdminImpl.processDelta(PackageAdminImpl.java:546)
at org.eclipse.osgi.framework.internal.core.PackageAdminImpl.doResolveBundles(PackageAdminImpl.java:239)
at org.eclipse.osgi.framework.internal.core.PackageAdminImpl$1.run(PackageAdminImpl.java:174)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.apache.cxf.transport.http.HTTPException: HTTP response '404: Not Found' when communicating with http://localhos
t:9090/Payments
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:2255)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:2193)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:2037)
at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56)
at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:697)
at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInter
ceptor.java:62)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:255)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:516)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:313)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:265)
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:124)
... 13 more
when I run my client in another instance of service mix (while my first instance stil run the service ) I get a different error
at this level
factory.create()
java.lang.NullPointerException
at org.apache.cxf.jaxb.JAXBDataBinding.createContext(JAXBDataBinding.java:559)
at org.apache.cxf.jaxb.JAXBDataBinding.createJAXBContextAndSchemas(JAXBDataBinding.java:497)
at org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:324)
at org.apache.cxf.service.factory.AbstractServiceFactoryBean.initializeDataBindings(AbstractServiceFactoryBean.java:87
)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java
:445)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.buildServiceFromClass(JaxWsServiceFactoryBean.java:680)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.jav
a:508)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:245)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:202)
at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:101)
at org.apache.cxf.frontend.ClientFactoryBean.create(ClientFactoryBean.java:90)
at org.apache.cxf.frontend.ClientProxyFactoryBean.create(ClientProxyFactoryBean.java:117)
at org.apache.cxf.jaxws.JaxWsProxyFactoryBean.create(JaxWsProxyFactoryBean.java:124)
at demo.osgi.HelloWorldActivator.start(HelloWorldActivator.java:30)
I should say that the way I am doing this is not guided by any tutorial
I used wsdl2java to generate my interfaces and I just added them to my client bundle
Please advise,
Thanks
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 22, 2011 1:30 PM
in response to: atlantix
|
|
|
|
Hi,
You need first check if your webservice really start on
http://localhost:9090/Payments
You can use a browser to try to access
http://localhost:9090/Payments?wsdl
to see if you can successfully fetch the wsdl so that you can know if your webservice really start there.
Freeman
|
|
|
|
|
Posts:
20
Registered:
03/07/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 22, 2011 1:37 PM
in response to: ffang
|
|
|
|
My web service is actually running (I used soapUI to check everytime)
I even tried accessing another webservice that is a cxf endpoint developed with camel/cxf
but i fell in the same issue.
if you think of anyother reason this can happen , otherwise I might upload the bundles with the source code to get a better visibility
Thanks
|
|
|
|
|
Posts:
20
Registered:
03/07/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 22, 2011 1:40 PM
in response to: ffang
|
|
|
I also have noticed the following
i replaced localhost with 127.0.0.1
and then i had the following
Tue Mar 22 14:39:26 CET 2011]>Invoking remote web service ...
javax.xml.ws.soap.SOAPFaultException: No namespace on "HTML" element.
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:146)
at $Proxy113.transferFunds(Unknown Source)
at demo.osgi.HelloWorldActivator.start(HelloWorldActivator.java:45)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:783)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:774)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:755)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:370)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:284)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:276)
at org.apache.karaf.shell.osgi.InstallBundle.doExecute(InstallBundle.java:54)
at org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:38)
at org.apache.felix.gogo.commands.basic.AbstractCommand.execute(AbstractCommand.java:35)
at org.apache.felix.gogo.runtime.shell.CommandProxy.execute(CommandProxy.java:50)
at org.apache.felix.gogo.runtime.shell.Closure.execute(Closure.java:229)
at org.apache.felix.gogo.runtime.shell.Closure.executeStatement(Closure.java:162)
at org.apache.felix.gogo.runtime.shell.Pipe.run(Pipe.java:101)
at org.apache.felix.gogo.runtime.shell.Closure.execute(Closure.java:79)
at org.apache.felix.gogo.runtime.shell.CommandSessionImpl.execute(CommandSessionImpl.java:71)
at org.apache.karaf.shell.console.jline.Console.run(Console.java:170)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.apache.cxf.binding.soap.SoapFault: No namespace on "HTML" element.
at org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage(ReadHeadersInterceptor.java:125)
at org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage(ReadHeadersInterceptor.java:60)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:255)
at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:755)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:2335)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:2193)
at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:2037)
at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56)
at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:697)
at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInte
ceptor.java:62)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:255)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:516)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:313)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:265)
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:124)
... 20 more
edited {this happened with the client and the service running in the same servicemix instance}
for the client running in the separate servicemix instance , I still have the NullpointerException with the factory.create()
|
|
|
|
|
Posts:
1,290
Registered:
12/24/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Mar 23, 2011 9:19 AM
in response to: atlantix
|
|
|
|
Hi,
javax.xml.ws.soap.SOAPFaultException: No namespace on "HTML" element.
this means the server side not return a soap message, somehow it return a html page.
You can put some tool like tcpmon between your client and server to dump the onwire message, which generally can give you more concrete idea what happened there.
Freeman
|
|
|
|
|
Posts:
4
Registered:
02/17/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Apr 8, 2011 11:27 AM
in response to: ffang
|
|
|
Hi
I too got stuck up with this issue and included in my spring imports as -
<import resource="classpath:META-INF/cxf/cxf.xml"/>
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml"/>
<!--<import resource="classpath:META-INF/cxf/cxf-extension-http-jetty.xml"/>-->
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
<!--<import resource="classpath:META-INF/cxf/cxf-servlet.xml"/>-->
<import resource="classpath:META-INF/cxf/osgi/cxf-extension-osgi.xml" />
And my pom has as suggested by you -
<Import-Package>
org.apache.camel.osgi,
org.springframework.util,
org.apache.ws.security,
javax.jws,
javax.xml.bind.annotation,
javax.wsdl,
javax.xml.namespace,
META-INF.cxf,
org.apache.cxf.bus,
org.apache.cxf.bus.spring,
org.apache.cxf.bus.resource,
org.apache.cxf.configuration.spring,
org.apache.cxf.resource,
org.apache.cxf.transport.http,
org.springframework.beans.factory.config,
org.apache.commons.logging,
*
</Import-Package>
<DynamicImport-Package>*,
org.apache.camel.component.file.strategy
</DynamicImport-Package>
Error i am getting is -
"Could not find conduit initiator for transport http://schemas.xmlsoap.org/soap/http"
The webservice is called from the java class simply as -
CreateReponse coachService = new CreateReponse();
coachService.setHandlerResolver(handlerResolver);
CreateReponsePort coachPort = coachService.getCreateReponsePort();
//endPoint.getOutInterceptors().add(new SAAJInInterceptor());
Response resp = new Response();
resp.setConsumerCode("4382241");
ListConsumerCreateResponse listRes = new ListConsumerCreateResponse();
listRes.getResponse().add(resp);
CreateReponseInput respInput = new CreateReponseInput();
respInput.setListConsumerCreateResponse(listRes);
CreateReponseOutput respOutput = coachPort.CreateReponse(respInput);
ListConsumerCreateResponse output = respOutput.getListConsumerCreateResponse();
List returnRes = new ArrayList();
returnRes = output.getResponse();
This class is injected thru spring config. Is there any other worksround to fix this issue.
Thanks in advance.
Edited by: kanmisc on Apr 8, 2011 11:27 AM
|
|
|
|
|
Posts:
572
Registered:
09/17/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Apr 12, 2011 12:58 AM
in response to: kanmisc
|
|
|
|
It looks like a typical bus configure issue.
You need to make sure you inject a right bus into the client factory that you use.
From the below code , the bus is just take from thread local which is not safe to use from the ServiceMix, as there could be lots of CXF components which create their own bus to use and the bus may set as a thread local variable.
CreateReponsePort coachPort = coachService.getCreateReponsePort();
You may consider to use the bus which injected from the ApplicationContext, or you can use the <jaxws:client> to inject the service proxy that you are using.
Willem
|
|
|
|
|
Posts:
59
Registered:
03/10/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
May 20, 2011 5:03 AM
in response to: atlantix
|
|
|
import i have are
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http-binding.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
Still geting the errror
I have one question ... does consume will call cxfse endpoint and then provider.?
My config are as follows:
Consumer:
<cxfbc:consumer wsdl="classpath:wsdl/Service.wsdl"
targetService="m:Service" interfaceName="m:IService"
locationURI="http://localhost:8092/Service/PhysicalAddressValidationWs/" />
CXFSE:
<cxfse:endpoint>
<cxfse:pojo>
<bean class="com.ServiceImplProxy">
<property name="physicalAddress">
<cxfse:proxy service="m:Service"
endpoint="Service" type="com.IService" >
</cxfse:proxy>
</property>
</bean>
</cxfse:pojo>
</cxfse:endpoint>
Provider as :
<cxfbc:provider wsdl="classpath:wsdl/Service.wsdl"
locationURI="https://SErver1.net/v2/SOAP/Service.svc"
endpoint="Service" service="m:Service" interfaceName="m:IService" />
I am still getting
Caused by: java.lang.RuntimeException: org.springframework.context.ApplicationContextException: Failed to load configuration META-INF/cxf/transport/jbi/cxf-transport-jbi.xml
|
|
|
|
|
Posts:
27
Registered:
01/06/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Feb 20, 2011 1:26 PM
in response to: nohaapav
|
|
|
|
|
|
Thanks for quick response guys :
So my scenario seems like : i have a listener bundle which contains spring file which listen on folder temp and when i put xml file in folder --> listener put the file in some topic. Than i have some adapter which takes this xml file from topic and call the ws.
listener spring file : project-events-listener.xml
adapter spring file : planview-services.xml
Both of that files as attachement.
Implementation of method loginCaller which call ws looks like :
public Map<String, Object> loginCaller(Object xmlType){
logger.debug("loginCaller started.");
Map<String, Object> infoStore = new ManagedMap<String, Object>();
try {
setLoginCert(loginService.login(datasource, userName, password));
logger.debug("loginCaller finished.");
logger.info(loginCert);
infoStore.put("loginCert", loginCert);
infoStore.put("Object",xmlType);
return infoStore;
} catch (javax.xml.ws.WebServiceException ex) {
logger.error("loginCaller: Unable to talk to web service.", ex);
infoStore.put("loginCert", "-1");
infoStore.put("Object",xmlType);
return infoStore;
}
}
On some places i have stars cause it's internal project and i'm not able to show whole code as well so sorry for that. The interesting thing is that it's working ok in work on my PC, but when i tried to run that on my personal workstation the excepion SOAPFault appears and i can't find where should be some differences.
Edited by: nohaapav on Feb 20, 2011 1:38 PM
|
|
|
|
|
Posts:
27
Registered:
01/06/11
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Feb 20, 2011 5:01 PM
in response to: nohaapav
|
|
|
Thanks guys.
After i've imported :
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-http.xml" />
<import resource="classpath:META-INF/cxf/osgi/cxf-extension-osgi.xml" />
in my spring file ws works great  But is interesting why i need this import from my home office and from work office it works without it  .. i need to somehow check
Edit:
I finally find out where was the differences between work and home version : at work i'm always deploying bundles like feature and at home i was deploying one by one :):
<feature name="services-adapter-features" version="${version}">
<feature version="${servicemix.version}">activemq-broker</feature>
<feature version="${camel.version}">camel-jaxb</feature>
<feature version="${cxf.version}">cxf</feature>
<bundle>mvn:com.xxx/login-jaxws/0.0.1-SNAPSHOT</bundle>
<bundle>mvn:com.xxx/service-jaxws/0.0.1-SNAPSHOT</bundle>
<bundle>mvn:com.xxx/services-adapter/0.0.1SNAPSHOT</bundle>
</feature>
so i don't need to import previous stuff cause i've already imported cxf here  and also i forgot about /etc/org.apache.karaf.features.cfg file which i rewrite with the work version
Edited by: nohaapav on Feb 20, 2011 7:22 PM
|
|
|
|
|
Posts:
572
Registered:
09/17/07
|
|
|
|
Re: SOAPFaultException: Could not find conduit initiator for transport
Posted:
Feb 22, 2011 12:40 AM
in response to: nohaapav
|
|
|
|
If you deploy you application with Feature, you application my always uses a same bus, as the bus can be get from thread local by default.
If you deploy the application bundle per bundle, I can't guarantee there is one thread to load the bundle, and your CXF application can use a different bus. By specify the imports of the spring files can make sure you get a right configured bus.
Willem
|
|
|
|
|
|