You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Frank (JIRA)" <ji...@apache.org> on 2012/06/01 15:26:23 UTC

[jira] [Comment Edited] (CXF-2284) org.apache.cxf.BusException: No binding factory for namespace http://schemas.xmlsoap.org/wsdl/soap/ registered."

    [ https://issues.apache.org/jira/browse/CXF-2284?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13287377#comment-13287377 ] 

Frank edited comment on CXF-2284 at 6/1/12 1:25 PM:
----------------------------------------------------

I had a similar problem and i could fixed with the maven shady plugin by merge the content of each bus-extension.txt file.

Here the Maven snippet code to merge the bus-extension.txt file.

<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-shade-plugin</artifactId>
				<version>1.6</version>
				<configuration>
					<!-- put your configurations here -->
				</configuration>
				<executions>
					<execution>
						<phase>package</phase>
						<goals>
							<goal>shade</goal>
						</goals>
						<configuration>
							<transformers>
								<transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
									<resource>META-INF/cxf/bus-extensions.txt</resource>
								</transformer>
							</transformers>
						</configuration>
					</execution>
				</executions>
			</plugin>

Have a nice day
                
      was (Author: pussinboots666@googlemail.com):
    I hab a similar problem and i could fixed with the maven shady plugin by merge the content of each bus-extension.txt file.

Here the Maven snippet code to merge the bus-extension.txt file.

<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-shade-plugin</artifactId>
				<version>1.6</version>
				<configuration>
					<!-- put your configurations here -->
				</configuration>
				<executions>
					<execution>
						<phase>package</phase>
						<goals>
							<goal>shade</goal>
						</goals>
						<configuration>
							<transformers>
								<transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
									<resource>META-INF/cxf/bus-extensions.txt</resource>
								</transformer>
							</transformers>
						</configuration>
					</execution>
				</executions>
			</plugin>

Have a nice day
                  
> org.apache.cxf.BusException: No binding factory for namespace http://schemas.xmlsoap.org/wsdl/soap/ registered." 
> -----------------------------------------------------------------------------------------------------------------
>
>                 Key: CXF-2284
>                 URL: https://issues.apache.org/jira/browse/CXF-2284
>             Project: CXF
>          Issue Type: Bug
>          Components: Soap Binding
>    Affects Versions: 2.1.5
>         Environment: Win XP
>            Reporter: ANAND RAI
>            Priority: Blocker
>             Fix For: 2.3, 2.2.11
>
>         Attachments: screenshot-1.jpg
>
>
> I am writing a Component using CXF to consume an AXIS webservice  hosted on Tomcat.The component works absolutely fine as a standalone application on eclipse , but things get worst when i integrate it with rest of project which has another component exposing CXF Webservice . I am using CXF 2.1.5  accross my application (for consuming and producing) .
> Following spring configuration was used to create  stub .
> <bean id="accountService" class="org.springframework.remoting.jaxws.JaxWsPortProxyFactoryBean">
>        <property name="serviceInterface" value="x.y.AccountManagerPortType" />
>        <property name="wsdlDocumentUrl" value="http://xyz:8084/someName/services/AccountManager?wsdl" />
>        <property name="namespaceUri" value="http://x.y" />
>        <property name="serviceName" value="AccountManager" />
>        <property name="portName" value="AccountManagerSOAP11port_http" />
> </bean>  
> Spring logs show that spring is not able to create  AccountManagerSOAP11port_http.jaxws-client.proxy .
> CXF logging was enable by following configuration
> <cxf:bus>
> 	<cxf:features>
> 		<cxf:logging />
> 	</cxf:features>
> </cxf:bus>
> to notice that CXF is able to send and recieve message ,but its returning back a null object.Initially it appeared to me as if it is some issue with SOAPHandler or jaxb .After some debugging i noticed that spring is getting an exception while creating above service the exception was 
> "org.apache.cxf.BusException: No binding factory for namespace http://schemas.xmlsoap.org/wsdl/soap/ registered ".
> I wasn't able to get a stack trace, because spring was eating up the exception and rather giving a friendly message which didn't make much sense to me except that it failed to create "AccountManagerSOAP11port_http.jaxws-client.proxy " .
> Below is a snapshot of eclipse in debug persepective
> this     DefaultListableBeanFactory  (id=257)     
> ex       WebServiceException  (id=485)    
>    cause  ServiceConstructionException  (id=629)   
>        cause  BusException  (id=633)      
>            cause  BusException  (id=633)      
>            detailMessage         null    
>            message       Message  (id=638)  
> 	           bundle          PropertyResourceBundle  (id=641)         
>                    code   "NO_BINDING_FACTORY_EXC" (id=644)         
>                    parameters   Object[1]  (id=645) 
>                    stackTrace     null    
>            detailMessage         "org.apache.cxf.BusException: No binding factory for namespace 				 http://schemas.xmlsoap.org/wsdl/soap/ registered." (id=636)             message       null    
>         stackTrace     null    
>    detailMessage         "org.apache.cxf.service.factory.ServiceConstructionException" (id=632)     stackTrace     null    
> beanName    "subscriberService" (id=488)        
> bean   JaxWsPortProxyFactoryBean  (id=440)    
> mbd   RootBeanDefinition  (id=490)       
> wrappedBean          JaxWsPortProxyFactoryBean  (id=440)    
> I googled this exception and found that many people  have reported same problem and for most of queries the cause is suggested to be missing CXF-extension-soap.xml or cxf-rt-bindings-soap-2.1.3.jar missing in classpath .But in my case i have both of them 
> I have following spring imports in spring configuration
>  <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-servlet.xml" />      
> and cxf-rt-bindings-soap-2.1.3.jar is present in web-inf/lib of the war file .
> I added some more imports ,but didn't prooved to be any help . 
> <import resource="classpath:META-INF/cxf/cxf.xml"/>
> <import resource="classpath:META-INF/cxf/cxf-extension-jaxws.xml"/>
> <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml"/>
> <import resource="classpath:META-INF/cxf/cxf-extension-management.xml"/>
> <import resource="classpath:META-INF/cxf/cxf-servlet.xml"/>
> <import resource="classpath:META-INF/cxf/cxf-extension-addr.xml"/>
>    
> I tried another approach to consume webservice .
> <beans default-init-method="beanInit" default-destroy-method="beanDestroy"
> xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:jaxws="http://cxf.apache.org/jaxws"
> xmlns:hlapi="http://x.y"
> xmlns:context="http://www.springframework.org/schema/context"
> xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
> http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
> http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd">
> <jaxws:client id="accountService"
> serviceClass="x.y.AccountManagerPortType"
> address="http://xyz:8084/someName/services/AccountManager"
> serviceName="hlapi:AccountManager"
> endpointName="hlapi:AccountManagerSOAP11port_http"/>
> I wasn't able to get any exception while debugging , but i am facing the same issue as with previous approach , CXF logs inbound and outbound messages , but its returning me a null object .
> This has become a blocking issue for me and my team ,i am stuck on this issue since past week .
> Please advise any possible solution .  

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira