After the decision to design my upcoming ERP solution as OSGI - Client/Server application using Eclipse Riena (Remoting, ObjectTransactions), Equinox (OSGI) and Hibernate (JPA / ORM) one point remains open: how to integrate EJB (Stateless and Stateful Sessionbeans) ?
The answer: there's a great open source EJB - OSGI solution: EasyBeans.
First step:
Integrate EasyBeans with Eclipse 3.4 + Equinox 3.4. (EasyBeans default OSGI framework is Felix from Apache)
... here's my HowTo:
What do we need: Eclipse Platform SDK, Equinox SDK and Easybeans OSGI - Hibernate-Version. All tests are done and are only running under Eclipse 3.4. At the moment of writing this blog Eclipse 3.4.RC3 is the newest one and EasyBeans OSGI 1.0.0:
We have to differentiate between Eclipse as IDE and as target platform. At first you should install Eclipse Platform SDK as IDE as usual.
If you want to follow this tutorial then you should create a folder structure for the target platform as below.
Then we create the following structure at
${target_easybeans}/
No we have to copy the needed plug-ins (bundles).
Which plug-ins you should copy depends on the needs of your project - to be flexible I made examples for two different target platforms: easybeans_target_full and easybeans_target_minimal.
easybeans_target_full (complete environment)
please copy into ${target_easybeans}/easybeans_target_full/eclipse/configuration/plugins:
- all from Eclipse Platform SDK plugins - folder
- all from Equinox SDK plugins - Ordner, if not contained in Platform SDK - Plugins)
- from ow2-easybeans-osgi-1.0.0/bundles: all without *.felix.*
easybeans_target_minimal (Target Platform only with needed bundles)
please copy into ${target_easybeans}/easybeans_target_minimal/eclipse/configuration/plugins:
from Equinox SDK:
- org.eclipse.osgi
- org.eclipse.equinox.common
- org.eclipse.osgi.services
- org.eclipse.equinox.cm
- org.eclipse.equinox.ds
- org.eclipse.equinox.log
- org.eclipse.equinox.util
- ow2-bundles-externals-commons-logging
- easybeans-core
- easybeans-component-carol
- easybeans-component-hsqldb
- easybeans-component-jdbcpool
- easybeans-component-joram
- easybeans-component-jotm
- easybeans-component-quartz
- easybeans-agent
if wanted also the examples - bundles from EasyBeans:
- easybeans-example-osgi
- easybeans-examples-entitybean
- easybeans-examples-mdb
- easybeans-examples-migrationejb21
- easybeans-examples-security
- easybeans-examples-statefulbean
- easybeans-examples-statelessbean
- easybeans-examples-timerservice
Warning
-
Bundles from EasyBeans (Version 1.0.0) were not named like Equinox - rules: easybeans-core-1.0.0 should be easybeans-core_1.0.0. You can simple rename the bundles (change minus inti underline) or to use the name together with the version if adding bundles to bundle.info from config.ini. (Bug JIRA)
-
Bundle easybeans-component-joram-1.0.0 contains a wrong import in MANIFEST.MF: com.scalagent.scheduler This import must be removed. (Bug JIRA)
After defining the targets you can change to this target with one click from within the target definition file or you do it directly from Preferences - Plug-in Development - Target Platform:
Please check the box (yellow marked). Because we want to build the target platform only using the plug-ins (bundles) stored at target platform location. (see the blog from Chris Aniszczyk)
To start EasyBeans easy ;-) in Eclipse we create OSGI Launch configurations.
Run Configurations...
We need two different OSGI Launch configurations:
- first launcher uses a configuration file (config.ini in folder configuration), where all bundles were listed under property bundle.info
- second launcher runs without using a configuration file - all bundles and arguments are defined directly in the launch configuration
OSGI Framework Launch Configuration with config.ini
There are no bundles selected from target platform, because they are all listed inside config.ini.
The most important program argument is -configuration, you also see the use of the defined variable. Inside this configuration folder you have to place the config.ini.
Its no application - we only want to run these bundles:
- eclipse.ignoreApp=true
- osgi.noShutdown=true
- osgi.bundles=\
- org.eclipse.equinox.common@2:start, \
- org.eclipse.osgi.services@start, \
- org.eclipse.equinox.cm@start, \
- org.eclipse.equinox.ds@start, \
- org.eclipse.equinox.log@start, \
- org.eclipse.equinox.util@start, \
- ow2-bundles-externals-commons-logging-1.0.5@start, \
- easybeans-core-1.0.0, \
- easybeans-component-carol-1.0.0, \
- easybeans-component-hsqldb-1.0.0, \
- easybeans-component-jdbcpool-1.0.0, \
- easybeans-component-joram-1.0.0, \
- easybeans-component-jotm-1.0.0, \
- easybeans-component-quartz-1.0.0, \
- easybeans-agent-1.0.0@start, \
- easybeans-example-osgi-1.0.0, \
- easybeans-examples-entitybean-1.0.0, \
- easybeans-examples-mdb-1.0.0, \
- easybeans-examples-migrationejb21-1.0.0, \
- easybeans-examples-security-1.0.0, \
- easybeans-examples-statefulbean-1.0.0, \
- easybeans-examples-statelessbean-1.0.0, \
- easybeans-examples-timerservice-1.0.0
- org.osgi.framework.bootdelegation=sun.*,com.sun.*
- org.osgi.framework.system.packages=org.osgi.framework; version=1.3.0, \
- javax.accessibility; \
- javax.activity; \
- javax.imageio; \
- javax.imageio.event; \
- javax.imageio.metadata; \
- javax.imageio.plugins.bmp; \
- javax.imageio.plugins.jpeg; \
- javax.imageio.spi; \
- javax.imageio.stream; \
- javax.management; \
- javax.management.loading; \
- javax.management.modelmbean; \
- javax.management.monitor; \
- javax.management.openmbean; \
- javax.management.relation; \
- javax.management.remote; \
- javax.management.remote.rmi; \
- javax.management.timer; \
- javax.naming; \
- javax.naming.directory; \
- javax.naming.event; \
- javax.naming.ldap; \
- javax.naming.spi; \
- javax.net; \
- javax.net.ssl; \
- javax.print; \
- javax.print.attribute; \
- javax.print.attribute.standard; \
- javax.print.event; \
- javax.rmi; \
- javax.rmi.CORBA; \
- javax.rmi.ssl; \
- javax.security.auth; \
- javax.security.auth.callback; \
- javax.security.auth.kerberos; \
- javax.security.auth.login; \
- javax.security.auth.spi; \
- javax.security.auth.x500; \
- javax.security.sasl; \
- javax.sound.midi; \
- javax.sound.midi.spi; \
- javax.sound.sampled; \
- javax.sound.sampled.spi; \
- javax.sql; \
- javax.sql.rowset; \
- javax.sql.rowset.serial; \
- javax.sql.rowset.spi; \
- javax.swing; \
- javax.swing.border; \
- javax.swing.colorchooser; \
- javax.swing.event; \
- javax.swing.filechooser; \
- javax.swing.plaf; \
- javax.swing.plaf.basic; \
- javax.swing.plaf.metal; \
- javax.swing.plaf.multi; \
- javax.swing.plaf.synth; \
- javax.swing.table; \
- javax.swing.text; \
- javax.swing.text.html; \
- javax.swing.text.html.parser; \
- javax.swing.text.rtf; \
- javax.swing.tree; \
- javax.swing.undo; \
- javax.xml; \
- javax.xml.datatype; \
- javax.xml.namespace; \
- javax.xml.parsers; \
- javax.xml.transform; \
- javax.xml.transform.dom; \
- javax.xml.transform.sax; \
- javax.xml.transform.stream; \
- javax.xml.validation; \
- javax.xml.xpath; \
- org.ietf.jgss; \
- org.omg.CORBA; \
- org.omg.CORBA_2_3; \
- org.omg.CORBA_2_3.portable; \
- org.omg.CORBA.DynAnyPackage; \
- org.omg.CORBA.ORBPackage; \
- org.omg.CORBA.portable; \
- org.omg.CORBA.TypeCodePackage; \
- org.omg.CosNaming; \
- org.omg.CosNaming.NamingContextExtPackage; \
- org.omg.CosNaming.NamingContextPackage; \
- org.omg.Dynamic; \
- org.omg.DynamicAny; \
- org.omg.DynamicAny.DynAnyFactoryPackage; \
- org.omg.DynamicAny.DynAnyPackage; \
- org.omg.IOP; \
- org.omg.IOP.CodecFactoryPackage; \
- org.omg.IOP.CodecPackage; \
- org.omg.Messaging; \
- org.omg.PortableInterceptor; \
- org.omg.PortableInterceptor.ORBInitInfoPackage; \
- org.omg.PortableServer; \
- org.omg.PortableServer.CurrentPackage; \
- org.omg.PortableServer.POAManagerPackage; \
- org.omg.PortableServer.POAPackage; \
- org.omg.PortableServer.portable; \
- org.omg.PortableServer.ServantLocatorPackage; \
- org.omg.SendingContext; \
- org.omg.stub.java.rmi; \
- org.omg.stub.javax.management.remote.rmi; \
- org.w3c.dom; \
- org.w3c.dom.bootstrap; \
- org.w3c.dom.css; \
- org.w3c.dom.events; \
- org.w3c.dom.html; \
- org.w3c.dom.ls; \
- org.w3c.dom.ranges; \
- org.w3c.dom.stylesheets; \
- org.w3c.dom.traversal; \
- org.w3c.dom.views; \
- org.xml.sax; \
- org.xml.sax.ext; \
- org.xml.sax.helpers; \
- sun.rmi.server; \
- sun.rmi.transport; \
- sun.rmi.registry; \
- version=1.5.0
Even while testing its a good idea to use an own location for the Configuration Area in the settings of the launch configuration. (We also use our above defined variable here).
And the config.ini for this scenario: config.ini.zip
OSGI Framework Launch Configuration without config.ini
In this case you have to select the needed bundles in the launcher.
Please watch the Start Level: equinox.common needs Level 2, all the other bundles get automatically the Default Start Level 4 and then the easybeans.agent with Start Level 5 will be started.
At programm arguments there's no -configuration - of course all of them now have to be defined as VM Arguments.
Please watch, that -Dorg.osgi.framework.system.packages has to be entered without any spaces - the other arguments are identical to the content of the config.ini in the first scenario.
YOU ARE READY - all configuration and installation is done and you can run EasyBeans with different target platforms and different OSGI Framework launch configurations.
Framework is launched.
idState Bundle
0ACTIVE org.eclipse.osgi_3.4.0.v20080521-1400
1ACTIVE org.eclipse.equinox.common_3.4.0.v20080421-2006
2ACTIVE org.eclipse.osgi.services_3.1.200.v20071203
3ACTIVE org.eclipse.equinox.cm_1.0.0.v20080509-1800
4ACTIVE org.eclipse.equinox.ds_1.0.0.v20080427-0830
5ACTIVE org.eclipse.equinox.log_1.1.0.v20080414
6ACTIVE org.eclipse.equinox.util_1.0.0.v20080414
7ACTIVE org.ow2.bundles.ow2-bundles-externals-commons-logging_1.0.5
8ACTIVE org.ow2.easybeans.core_1.0.0
9ACTIVE org.ow2.easybeans.component.carol_1.0.0
10ACTIVE org.ow2.easybeans.component.hsqldb_1.0.0
11ACTIVE org.ow2.easybeans.component.jdbcpool_1.0.0
12ACTIVE org.ow2.easybeans.component.joram_1.0.0
13ACTIVE org.ow2.easybeans.component.jotm_1.0.0
14ACTIVE org.ow2.easybeans.component.quartz_1.0.0
15ACTIVE org.ow2.easybeans.agent_1.0.0
16RESOLVED org.ow2.easybeans.examples.osgi_1.0.0
17RESOLVED org.ow2.easybeans.examples.entitybean_1.0.0
18RESOLVED org.ow2.easybeans.examples.messagedriven_1.0.0
19RESOLVED org.ow2.easybeans.examples.migrationejb21_1.0.0
20RESOLVED org.ow2.easybeans.examples.security_1.0.0
21RESOLVED org.ow2.easybeans.examples.stateful_1.0.0
22RESOLVED org.ow2.easybeans.examples.stateless_1.0.0
23RESOLVED org.ow2.easybeans.examples.timer_1.0.0
Good luck and have fun with EasyBeans. In some days I'll report my experiences how to run EasyBeans and Eclipse Riena together.
2 comments:
Hi ekke,
After Integrate EasyBeans with Eclipse proceed this "how to".
I’m getting this error on OSGI. It’s possible to fix this?
22/08/08 19:15:28 (S) NamingManager.createEnvironmentContext : Cannot lookup UserTransaction.
javax.naming.NameNotFoundException: javax.transaction.UserTransaction [Root exception is java.rmi.NotBoundException: javax.transaction.UserTransaction]
at org.ow2.carol.jndi.registry.AbsRegistryWrapperContext.lookup(AbsRegistryWrapperContext.java:99)
at org.ow2.carol.jndi.spi.AbsContext.lookup(AbsContext.java:142)
at org.ow2.carol.jndi.spi.AbsContext.lookup(AbsContext.java:152)
at javax.naming.InitialContext.lookup(Unknown Source)
at org.ow2.carol.jndi.spi.MultiContext.lookup(MultiContext.java:117)
at javax.naming.InitialContext.lookup(Unknown Source)
at org.ow2.easybeans.naming.NamingManager.createEnvironmentContext(NamingManager.java:121)
at org.ow2.easybeans.deployment.helper.JavaContextHelper.build(JavaContextHelper.java:76)
at org.ow2.easybeans.container.JContainer3.createBeanFactories(JContainer3.java:425)
at org.ow2.easybeans.container.JContainer3.start(JContainer3.java:340)
at org.ow2.easybeans.osgi.ejbjar.Activator.startContainer(Activator.java:147)
at org.ow2.easybeans.osgi.ejbjar.EmbeddedServiceListener.serviceChanged(EmbeddedServiceListener.java:67)
at org.eclipse.osgi.framework.internal.core.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:91)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1248)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEventPrivileged(Framework.java:1563)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEvent(Framework.java:1538)
at org.eclipse.osgi.framework.internal.core.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:122)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.createServiceRegistration(BundleContextImpl.java:666)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:617)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:685)
at org.ow2.easybeans.osgi.core.EZBCoreService.start(EZBCoreService.java:138)
at org.ow2.easybeans.osgi.core.EZBCoreService.activate(EZBCoreService.java:187)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:118)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:149)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:290)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:578)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:195)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:317)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:213)
at org.eclipse.osgi.framework.internal.core.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:91)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1248)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEventPrivileged(Framework.java:1563)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEvent(Framework.java:1538)
at org.eclipse.osgi.framework.internal.core.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:122)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.createServiceRegistration(BundleContextImpl.java:666)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:617)
at org.ow2.easybeans.osgi.component.EZBComponentServiceFactory.updateMapsAndRegisterService(EZBComponentServiceFactory.java:219)
at org.ow2.easybeans.osgi.component.EZBComponentServiceFactory.updated(EZBComponentServiceFactory.java:198)
at org.eclipse.equinox.internal.cm.ManagedServiceFactoryTracker$2.run(ManagedServiceFactoryTracker.java:177)
at org.eclipse.equinox.internal.cm.SerializedTaskQueue$1.run(SerializedTaskQueue.java:36)
Caused by: java.rmi.NotBoundException: javax.transaction.UserTransaction
at org.ow2.carol.jndi.registry.jrmp.ManageableRegistry.lookup(ManageableRegistry.java:126)
at org.ow2.carol.jndi.registry.AbsRegistryWrapperContext.lookup(AbsRegistryWrapperContext.java:97)
... 47 more
22/08/08 19:15:28 (S) ContextImpl.unbind : CompNamingContext nothing to unbind
!SESSION 2008-08-22 19:15:21.656 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.6.0_07
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=pt_BR
Command-line arguments: -dev file:C:/dsbi/plataform/osgi_temp/configuration_area/easybeans_launch_config/dev.properties -os win32 -ws win32 -arch x86 -console -clean -consoleLog
!ENTRY org.eclipse.osgi 4 0 2008-08-22 19:15:28.203
!MESSAGE An unexpected runtime error has occurred.
!STACK 0
java.lang.IllegalStateException: Cannot remove java:comp/UserTransaction object
at org.ow2.easybeans.deployment.helper.JavaContextHelper.build(JavaContextHelper.java:99)
at org.ow2.easybeans.container.JContainer3.createBeanFactories(JContainer3.java:425)
at org.ow2.easybeans.container.JContainer3.start(JContainer3.java:340)
at org.ow2.easybeans.osgi.ejbjar.Activator.startContainer(Activator.java:147)
at org.ow2.easybeans.osgi.ejbjar.EmbeddedServiceListener.serviceChanged(EmbeddedServiceListener.java:67)
at org.eclipse.osgi.framework.internal.core.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:91)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1248)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEventPrivileged(Framework.java:1563)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEvent(Framework.java:1538)
at org.eclipse.osgi.framework.internal.core.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:122)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.createServiceRegistration(BundleContextImpl.java:666)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:617)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:685)
at org.ow2.easybeans.osgi.core.EZBCoreService.start(EZBCoreService.java:138)
at org.ow2.easybeans.osgi.core.EZBCoreService.activate(EZBCoreService.java:187)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:118)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:149)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:290)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:578)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:195)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:317)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:213)
at org.eclipse.osgi.framework.internal.core.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:91)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1248)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEventPrivileged(Framework.java:1563)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEvent(Framework.java:1538)
at org.eclipse.osgi.framework.internal.core.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:122)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.createServiceRegistration(BundleContextImpl.java:666)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:617)
at org.ow2.easybeans.osgi.component.EZBComponentServiceFactory.updateMapsAndRegisterService(EZBComponentServiceFactory.java:219)
at org.ow2.easybeans.osgi.component.EZBComponentServiceFactory.updated(EZBComponentServiceFactory.java:198)
at org.eclipse.equinox.internal.cm.ManagedServiceFactoryTracker$2.run(ManagedServiceFactoryTracker.java:177)
at org.eclipse.equinox.internal.cm.SerializedTaskQueue$1.run(SerializedTaskQueue.java:36)
Caused by: javax.naming.NameNotFoundException: UserTransaction
at org.ow2.easybeans.naming.context.ContextImpl.unbind(ContextImpl.java:309)
at org.ow2.easybeans.deployment.helper.JavaContextHelper.build(JavaContextHelper.java:97)
... 40 more
!ENTRY br.com.cgsys.easybeans.demo 4 0 2008-08-22 19:15:28.203
!MESSAGE
!STACK 0
java.lang.IllegalStateException: Cannot remove java:comp/UserTransaction object
at org.ow2.easybeans.deployment.helper.JavaContextHelper.build(JavaContextHelper.java:99)
at org.ow2.easybeans.container.JContainer3.createBeanFactories(JContainer3.java:425)
at org.ow2.easybeans.container.JContainer3.start(JContainer3.java:340)
at org.ow2.easybeans.osgi.ejbjar.Activator.startContainer(Activator.java:147)
at org.ow2.easybeans.osgi.ejbjar.EmbeddedServiceListener.serviceChanged(EmbeddedServiceListener.java:67)
at org.eclipse.osgi.framework.internal.core.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:91)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1248)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEventPrivileged(Framework.java:1563)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEvent(Framework.java:1538)
at org.eclipse.osgi.framework.internal.core.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:122)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.createServiceRegistration(BundleContextImpl.java:666)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:617)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:685)
at org.ow2.easybeans.osgi.core.EZBCoreService.start(EZBCoreService.java:138)
at org.ow2.easybeans.osgi.core.EZBCoreService.activate(EZBCoreService.java:187)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:118)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:149)
at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:290)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:578)
at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:195)
at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:317)
at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:213)
at org.eclipse.osgi.framework.internal.core.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:91)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1248)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:141)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEventPrivileged(Framework.java:1563)
at org.eclipse.osgi.framework.internal.core.Framework.publishServiceEvent(Framework.java:1538)
at org.eclipse.osgi.framework.internal.core.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:122)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.createServiceRegistration(BundleContextImpl.java:666)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:617)
at org.ow2.easybeans.osgi.component.EZBComponentServiceFactory.updateMapsAndRegisterService(EZBComponentServiceFactory.java:219)
at org.ow2.easybeans.osgi.component.EZBComponentServiceFactory.updated(EZBComponentServiceFactory.java:198)
at org.eclipse.equinox.internal.cm.ManagedServiceFactoryTracker$2.run(ManagedServiceFactoryTracker.java:177)
at org.eclipse.equinox.internal.cm.SerializedTaskQueue$1.run(SerializedTaskQueue.java:36)
Caused by: javax.naming.NameNotFoundException: UserTransaction
at org.ow2.easybeans.naming.context.ContextImpl.unbind(ContextImpl.java:309)
at org.ow2.easybeans.deployment.helper.JavaContextHelper.build(JavaContextHelper.java:97)
... 40 more
hi missias,
the stacktrace isn't enough to see what went wrong.
at the moment I'm on vacation and have not much time to look into it.
but I'll place soon a new blog entry about integration of Easybeans 1.1.0 + Riena M3 (or upcoming M4) + Eclipse / Equinox 3.4
this works great, but there are some pitfalls to watch.
ekke
Post a Comment