You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by exabrial <ex...@gmail.com> on 2012/07/12 20:34:07 UTC

Injecting an external webservice with @WebServiceRef

Hey guys, I'm getting an exception while trying to inject a webservice
running on a different JVM.  I get the feeling I don't understand
WebServiceRef...

Here is my Managed bean.  ThemeQueryService is a JAXWS annotated interface.

@SessionScoped
@Named("managedBeanMB")
public class ManagedBeanMB implements Serializable {
	private static final long serialVersionUID = 1L;

	String themeName;

	@WebServiceRef(wsdlLocation =
"http://localhost:8777/services/themeQuery?wsdl")
	private ThemeQueryService queryService;
....
}

Caused by: java.lang.NullPointerException
	at
org.apache.openejb.core.ivm.naming.JaxWsServiceReference.getObject(JaxWsServiceReference.java:73)
	at
org.apache.openejb.core.ivm.naming.IvmContext.lookup(IvmContext.java:173)
	at
org.apache.openejb.cdi.CdiResourceInjectionService.lookup(CdiResourceInjectionService.java:134)
	at
org.apache.openejb.cdi.CdiResourceInjectionService.fillInjectionProperties(CdiResourceInjectionService.java:112)
	at
org.apache.openejb.cdi.CdiResourceInjectionService.injectJavaEEResources(CdiResourceInjectionService.java:96)
	at
org.apache.webbeans.component.AbstractInjectionTargetBean.injectResources(AbstractInjectionTargetBean.java:432)
	at
org.apache.webbeans.portable.creation.InjectionTargetProducer.inject(InjectionTargetProducer.java:91)
	at
org.apache.webbeans.component.InjectionTargetWrapper.inject(InjectionTargetWrapper.java:79)
	at
org.apache.webbeans.component.AbstractOwbBean.create(AbstractOwbBean.java:182)

--
View this message in context: http://openejb.979440.n4.nabble.com/Injecting-an-external-webservice-with-WebServiceRef-tp4656257.html
Sent from the OpenEJB User mailing list archive at Nabble.com.