Hi,
is it possible to either not deploy MessageDriven Beans at all in openejb or
turn off FailOnUnknowActivationSpec for all Container/MDB using properties? I
use openEjb for my container based unit-tests and it fails to deploy a JMS MDB
with
messageListenerInterface = MessageListener.class,
activationConfig = {
@ActivationConfigProperty(propertyName="maxSession", propertyValue="1")
}
I found you can declare it in Properties using
http://tomee.apache.org/admin/configuration/containers.html
But after adding that I get:
Assembler failed to build the container system.
org.apache.openejb.OpenEJBException: No existing resource adapter defined with
id 'Default JMS Resource Adapter'.
My original error without trying to set FailOnUnknowActivationSpec to false is:
org.apache.openejb.OpenEjbContainer$AssembleApplicationException:
org.apache.openejb.OpenEJBException: Creating application failed: C:\test:
Error deploying 'ListenerMDB'. Exception: class
org.apache.openejb.OpenEJBException: Unable to create activation spec: No
setter found for the activation spec properties: [maxSession]: Unable to create
activation spec: No setter found for the activation spec properties:
[maxSession]
at
org.apache.openejb.OpenEjbContainer$Provider.createEJBContainer(OpenEjbContainer.java:347)
at
javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:127)
at
de.evelopment.openejb.util.EjbTestHelper.startContainer(EjbTestHelper.java:91)
at de.evelopment.openejb.EjbTestCase.startUp(EjbTestCase.java:39)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at
org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
at
org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:55)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at
org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at
org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
at
org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:55)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:538)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:760)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:460)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:206)
Caused by: org.apache.openejb.OpenEJBException: Creating application failed:
C:\test: Error deploying 'ListenerMDB'. Exception: class
org.apache.openejb.OpenEJBException: Unable to create activation spec: No
setter found for the activation spec properties: [maxSession]: Unable to create
activation spec: No setter found for the activation spec properties:
[maxSession]
at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:1050)
at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:721)
at
org.apache.openejb.OpenEjbContainer$Provider.createEJBContainer(OpenEjbContainer.java:343)
... 33 more
Caused by: org.apache.openejb.OpenEJBException: Error deploying 'ListenerMDB'.
Exception: class org.apache.openejb.OpenEJBException: Unable to create
activation spec: No setter found for the activation spec properties:
[maxSession]: Unable to create activation spec: No setter found for the
activation spec properties: [maxSession]
at
org.apache.openejb.assembler.classic.Assembler.startEjbs(Assembler.java:1640)
at
org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:951)
... 35 more
Caused by: org.apache.openejb.OpenEJBException: Unable to create activation
spec: No setter found for the activation spec properties: [maxSession]
at
org.apache.openejb.core.mdb.MdbContainer.createActivationSpec(MdbContainer.java:318)
at
org.apache.openejb.core.mdb.MdbContainer.deploy(MdbContainer.java:167)
at
org.apache.openejb.assembler.classic.Assembler.startEjbs(Assembler.java:1627)
... 36 more
Caused by: java.lang.IllegalArgumentException: No setter found for the
activation spec properties: [maxSession]
at
org.apache.openejb.core.mdb.MdbContainer.createActivationSpec(MdbContainer.java:288)
... 38 more
Volker Gropp
Senior Software Developer
Phone: +49 40 - 85 187 - 0
Fax: +49 40 - 85 187 - 444
eMail: [email protected]<mailto:[email protected]>
e-velopment GmbH
Bahrenfelder Chaussee 49
22761 Hamburg
www.e-velopment.de<http://www.e-velopment.de/>
AG Hamburg, HRB 67471
Geschäftsführer: Oliver Kählert, Guido Sadler
[_evelopment_icon_2018]<http://www.e-velopment.de/>[_xing_icon_2018]<https://www.xing.com/companies/e-velopmentgmbh>[_youtube_icon_2018]<https://www.youtube.com/channel/UCE5iY1435GV7Vyc4ihXBdBg>[_google+_icon_2018]<https://plus.google.com/117326665347164316748>