Hi Romain,
I've try many ways to set the value of the resource, but always got the
error :
org.apache.openejb.OpenEjbContainer$InitializationException:
java.lang.NullPointerException: name cannot be null
at
org.apache.openejb.OpenEjbContainer$Provider.createEJBContainer(OpenEjbContainer.java:419)
at
javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:56)
at fr.myfooTest.start(ServiceFooTest.java:109)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at
org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
at
org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:30)
at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.NullPointerException: name cannot be null
at
org.apache.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:83)
at
org.apache.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:73)
at
org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2155)
at
org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:1721)
at
org.apache.openejb.config.AnnotationDeployer.deploy(AnnotationDeployer.java:342)
at
org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:338)
at
rg.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:827)
at
org.apache.openejb.OpenEjbContainer$Provider.createEJBContainer(OpenEjbContainer.java:371)
... 18 more
I've try to put ejb-jar.xml into src/test/java with :
<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" version="3.1"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/ejb-jar_3_1.xsd">
<enterprise-beans>
<session>
<ejb-name>ServiceFoo</ejb-name>
<env-entry>
<env-entry-name>thepath</env-entry-name>
<env-entry-type>java.lang.String</env-entry-type>
<env-entry-value>the_testing_path</env-entry-value>
</env-entry>
</session>
</enterprise-beans>
</ejb-jar>
As I use the openejb.altdd.prefix property set to test-, tried to put a
test-ejb-jar.xml into src/resources/ ... same
--
View this message in context:
http://openejb.979440.n4.nabble.com/resource-ref-settings-within-openEJB-tp4665781p4665804.html
Sent from the OpenEJB User mailing list archive at Nabble.com.