Hi Please remove ws-discovery modules from the distro for now,
It definitely won't happen in soon to be released CXF 2.7.3 - this issue (won't show itself with Maven) was there before 2.7.2 was out but my fix was incomplete at a time - I've verified the latest fix to the snapshot fixes it, I honestly hopes so :-).
Sergey On 25/01/13 09:15, Nishant Chandra wrote:
I am using CXF v 2.7.2, Spring 3.1.2. A REST endpoint is declared: <jaxrs:server id="healthCheckService" address="/healthCheck"> <jaxrs:serviceBeans> <ref bean="healthCheck" /> </jaxrs:serviceBeans> </jaxrs:server> Getting this NPE exception: SEVERE: Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'he althCheckService': Invocation of init method failed; nested exception is org.apache.cxf.se rvice.factory.ServiceConstructionException at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.in itializeBean(AbstractAutowireCapableBeanFactory.java:1455) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.do CreateBean(AbstractAutowireCapableBeanFactory.java:519) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.cr eateBean(AbstractAutowireCapableBeanFactory.java:456) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(Abstr actBeanFactory.java:294) .... Caused by: org.apache.cxf.service.factory.ServiceConstructionException at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java: 201) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.in vokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1581) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.in vokeInitMethods(AbstractAutowireCapableBeanFactory.java:1522) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.in itializeBean(AbstractAutowireCapableBeanFactory.java:1452) ... 26 more Caused by: java.lang.NullPointerException at org.apache.cxf.ws.discovery.listeners.WSDiscoveryServerListener.getServiceQName (WSDiscoveryServerListener.java:89) at org.apache.cxf.ws.discovery.listeners.WSDiscoveryServerListener.startServer(WSD iscoveryServerListener.java:68) at org.apache.cxf.bus.managers.ServerLifeCycleManagerImpl.startServer(ServerLifeCy cleManagerImpl.java:61) at org.apache.cxf.endpoint.ServerImpl.start(ServerImpl.java:146) at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java: 192) How can I fix this? Thanks, Nishant
-- Sergey Beryozkin Talend Community Coders http://coders.talend.com/ Blog: http://sberyozkin.blogspot.com