Hi all,
We're currently exploring Open EJB as container to run our FitNesse
tests. Everything worked like a charm until I implemented a
@WebserviceRef (SOAP over JMS).
First of all it gave me some Queue-not found exceptions, which is
obvious because OpenEJB doesn't know the queue. So I've added the the
JMS queue to the InitialContext:
p.put("MyJmsResourceAdapter",
"new://Resource?type=ActiveMQResourceAdapter");
p.put("MyJmsResourceAdapter.BrokerXmlConfig", "");
p.put("something", "new://Resource?type=javax.jms.ConnectionFactory");
p.put("something.ResourceAdapter", "MyJmsResourceAdapter");
p.put("something/else", "new://Resource?type=javax.jms.Queue");
This seemed to work, but now I'm getting the following (deep) NPE from OpenEJB:
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:171)
at
org.apache.openejb.InjectionProcessor.fillInjectionProperties(InjectionProcessor.java:182)
at
org.apache.openejb.InjectionProcessor.construct(InjectionProcessor.java:110)
at
org.apache.openejb.InjectionProcessor.createInstance(InjectionProcessor.java:83)
at
org.apache.openejb.core.stateless.StatelessInstanceManager.ceateInstance(StatelessInstanceManager.java:204)
at
org.apache.openejb.core.stateless.StatelessInstanceManager.getInstance(StatelessInstanceManager.java:165)
at
org.apache.openejb.core.stateless.StatelessContainer.invoke(StatelessContainer.java:165)
at
org.apache.openejb.core.ivm.EjbObjectProxyHandler.businessMethod(EjbObjectProxyHandler.java:217)
at
org.apache.openejb.core.ivm.EjbObjectProxyHandler._invoke(EjbObjectProxyHandler.java:77)
at
org.apache.openejb.core.ivm.BaseEjbProxyHandler.invoke(BaseEjbProxyHandler.java:282)
at $Proxy75.send(Unknown Source)
$Proxy75.send() is the first method in my code. Which looks like this:
@Stateless
public class AperakNotificationClientImpl implements AperakNotificationClient {
@WebServiceRef(wsdlLocation =
"xsd/services/notification/v0/AperakNotificationServiceBinding-v0.wsdl")
private AperakNotificationV0 aperakNotification;
@Override
public void send(final APERAK aperak) {
final AperakNotificationRequest request = new
AperakNotificationRequest();
request.setAperak(aperak);
final AperakNotificationServiceV0 aperakWebService =
aperakNotification.getAperakNotificationJmsPort();
aperakWebService.aperakNotification(request);
}
}
Any ideas what I'm missing, and why openejb is throwing NPE's? When
browsing the openejb code I've found "PortAddressRegistry" to be
missing, which should be retrieved by
"SystemInstance.get().getComponent(PortAddressRegistry.class);".
This is where my investigation stopped... Is there something missing
in my configuration?
Roy