cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Julio Arias <julio.ar...@rbxglobal.com>
Subject Endpoint config problems
Date Wed, 18 Jul 2007 16:39:50 GMT
Hi all -

Just to let you now about this problem I have. I got the following  
spring endpoint config:

<jaxws:endpoint id="documentService" address="/DocumentService">
<jaxws:implementor>		
	<bean class="com.rbx.lor.ws.DocumentServiceImpl">
		<property name="documentManager" ref="documentManager"/>
	</bean>
</jaxws:implementor>
<jaxws:inInterceptors>
	<bean class="org.apache.cxf.binding.soap.saaj.SAAJInInterceptor"/>
	<bean class="org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor">
		<constructor-arg>
			<map>
				<entry key="action" value="UsernameToken"/>
				<entry key="passwordType" value="PasswordText"/>
				<entry key="passwordCallbackClass"  
value="com.rbx.lor.ws.security.AuthenticationCallback"/>
			</map>
		</constructor-arg>
	</bean>
</jaxws:inInterceptors>
</jaxws:endpoint>


I like this config but I get a spring xml context exception

2007-07-18 10:33:28,686 ERROR [org.apache.catalina.core.ContainerBase. 
[Catalina].[localhost].[/lor]] - Exception sending context  
initialized event to listener instance of class  
org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.parsing.BeanDefinitionParsingException 
: Configuration problem: <constructor-arg> element must not contain  
more than one sub-element

I fix it by changing the implementor as an attribute of the endpoint  
using # to point to by implementing bean and now it works fine, but  
like my initial config is simpler and I have everything in one place,  
is there another workaround for this??

The working config is this:

<bean id="documentServiceImpl"  
class="com.rbx.lor.ws.DocumentServiceImpl">
	<property name="documentManager" ref="documentManager"/>
</bean>

<jaxws:endpoint id="documentService" address="/DocumentService"  
implementor="#documentServiceImpl">
	<jaxws:inInterceptors>
		<bean class="org.apache.cxf.binding.soap.saaj.SAAJInInterceptor"/>
		<bean class="org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor">
			<constructor-arg>
				<map>
					<entry key="action" value="UsernameToken"/>
					<entry key="passwordType" value="PasswordText"/>
					<entry key="passwordCallbackClass"  
value="com.rbx.lor.ws.security.AuthenticationCallback"/>
				</map>
			</constructor-arg>
		</bean>
	</jaxws:inInterceptors>
</jaxws:endpoint>


Julio Arias
Java Developer
Roundbox Global : enterprise : technology : genius
---------------------------------------------------------------------
Avenida 11 y Calle 7-9, Barrio Amón, San Jose, Costa Rica
tel: 404.567.5000 ext. 2001 | cell: 11.506.849.5981
email: julio.arias@rbxglobal.com | www.rbxglobal.com
---------------------------------------------------------------------


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message