I am running into a problem with the following exception. Any help would
be appreciated. I am pasting the configuration and code for the web
service below.
Thanks in advance for your help.
Regards,
Ramanand Singh
Architecture Team
GEICO IBU Service
301.986.2791
First the exception:
Sep 14, 2007 7:22:59 PM
org.apache.cxf.service.factory.ReflectionServiceFactoryBean
buildServiceFromClass
INFO: Creating Service
{http://authentication.common.insite.service.ibu.geico.com/}EAuthService
from class com.geico.ibu.service.insite.common.authentication.EAuth
Exception in thread "main" java.lang.NoSuchMethodError:
javax/xml/soap/SOAPFactory.createFault()Ljavax/xml/soap/SOAPFault;
at
org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:150)
at $Proxy9.validateUser(Unknown Source)
at
com.geico.ibu.service.insite.common.authentication.EAuthClient.main(EAut
hClient.java:40)
Web Service Interface and class:
@WebService
public interface EAuth {
String validateUser(String xfrKey, String clinetName);
}
@WebService(endpointInterface =
"com.geico.ibu.service.insite.common.authentication.EAuth")
public class EAuthImpl implements EAuth {
/** The logger. */
private static final Logger LOG =
Logger.getLogger(EAuthImpl.class);
/**
* [EMAIL PROTECTED]
*/
public String validateUser(String xfrKey, String clinetName) {
AuthenticationResponse ar = new AuthenticationResponse();
String response = "Transfer Key: " + xfrKey + "\t client
name: " + clinetName;
LOG.info("===>> " + response);
ar.setEmailAddress("[EMAIL PROTECTED]");
ar.setPolicyHolderName("Geico Policy Holder");
ar.setPolicyNumber("pol123456677889");
ar.setSessionId(new GUIDGenerator().generate());
return ar.toString();
//return ar;
}
}
Endpoint configuration:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jaxws="http://cxf.apache.org/jaxws"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd">
<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" />
<jaxws:endpoint
id="eauth"
implementor="com.geico.ibu.service.insite.common.authentication.EAuthImp
l"
address="/eauth" />
</beans>
Test Client:
public class EAuthClient {
private EAuthClient() {
// empty constructor
}
/**
* @param args
*/
public static void main(String args[]) throws Exception {
ClassPathXmlApplicationContext context
= new ClassPathXmlApplicationContext(new String[]
{"conf/spring/eauthClientContext.xml"});
EAuth eauthClient = (EAuth)context.getBean("eauthClient");
String response = eauthClient.validateUser("1234567890",
"CLAIMS");
System.out.println("Response: " + response);
System.exit(0);
// END SNIPPET: client
}
}
Client Configuration:
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jaxws="http://cxf.apache.org/jaxws"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
<bean id="eauthClient"
class="com.geico.ibu.service.insite.common.authentication.EAuth"
factory-bean="clientFactory" factory-method="create"/>
<bean id="clientFactory"
class="org.apache.cxf.jaxws.JaxWsProxyFactoryBean">
<property name="serviceClass"
value="com.geico.ibu.service.insite.common.authentication.EAuth"/>
<property name="address"
value="http://localhost:8080/insite/eservices/eauth"/>
</bean>
</beans>
====================
This email/fax message is for the sole use of the intended
recipient(s) and may contain confidential and privileged information.
Any unauthorized review, use, disclosure or distribution of this
email/fax is prohibited. If you are not the intended recipient, please
destroy all paper and electronic copies of the original message.