Purpose
The purpose of the EasyBeans OSGi integration is to add modularity
and dynamicity to EasyBeans. EasyBeans main components are exposed
as OSGi Services that can be used by other Components.
Configuration
EasyBeans/OSGi has been tested with
Felix and
Equinox
which are 2 Open-Source implementation of the
OSGi R4 Specification.
Apache Felix
Apache Felix can only be downloaded from the
Apache Felix Downloads Page.
A configuration file for Apache Felix is located in the 'conf/config.properties' file provided in
the OSGi assembly. This file should replace the Felix default's one.
Summary of the changes :
- Automatically create/start an 'ezb' profile containing all necessary bundles
- Uncomment the 'org.osgi.framework.bootdelegation' OSGi property exposing System classes
- Add some system packages
Equinox
By having an existing Eclipse 3.3 install, Equinox is already provided in the system.
Else, it can be downloaded from
Eclipse Equinox Download PageIn a directory where Equinox needs to be launched, a 'configuration' directory needs to be created.
The 'configuration/config.ini' configuration file provided by the OSGi assembly must be placed in this newly created directory.
Deploying
The assembly can be unpacked
The assembly is structured like :
bundles/
*.jar <-- EasyBeans bundles
lib/
ow_easybeans_osgi_client_rt.jar <-- Extra classes for entity clients
configuration/
config.ini <-- Equinox configuration file
conf/
config.properties <-- Felix configuration file
repository.xml <-- OBR2 Repository descriptor
build.xml <-- Client Runner
README
On Felix (OBR)
Configure felix
Copy <EZB-HOME>/conf/config.properties into <FELIX-HOME>/conf/config.properties.
Warning this config file is written for felix 1.0.0. If you own a later
version of felix, you may have to change bundle version of shell, shell.tui
and bundlerepository.
Add the repository URL
First, try to remove the default URL if you're behind a proxy
Felix comes pre-installed with the BundleRepository bundle, which
greatly simplify bundle deployment :
obr add-url file://<path/to/unpacked/assembly>/repository.xml
List availables bundles :
Produces the following output :
-> obr list EasyBeans
EasyBeans/OSGi :: Agent (1.0.0.RC1)
EasyBeans/OSGi :: Components :: Carol (1.0.0.RC1)
EasyBeans/OSGi :: Components :: HSQLDB (1.0.0.RC1)
EasyBeans/OSGi :: Components :: JDBC Pool (1.0.0.RC1)
EasyBeans/OSGi :: Components :: JORAM (1.0.0.RC1)
EasyBeans/OSGi :: Components :: JOTM (1.0.0.RC1)
EasyBeans/OSGi :: Components :: Quartz (1.0.0.RC1)
EasyBeans/OSGi :: Core (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Entity Bean (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Message Driven Bean (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Migration EJB 2.1 -> 3.0 (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Security (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Stateful Session Bean (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Stateless Session Bean (1.0.0.RC1)
EasyBeans/OSGi :: Examples :: Timer (1.0.0.RC1)
Deploy the bundles
The 3 required bundles of EasyBeans have to be deployed.
obr deploy org.apache.felix.scr
obr deploy org.apache.felix.configadmin
obr deploy org.apache.felix.log
You have to deploy each bundles (future version may automate that step) :
obr deploy org.ow2.easybeans.core
obr deploy org.ow2.easybeans.agent
obr deploy org.ow2.easybeans.component.carol
obr deploy org.ow2.easybeans.component.jotm
obr deploy org.ow2.easybeans.component.joram
obr deploy org.ow2.easybeans.component.quartz
obr deploy org.ow2.easybeans.component.hsqldb
obr deploy org.ow2.easybeans.component.jdbcpool
Optionnaly, you may deploy EJB 3.0 Samples too :
obr deploy org.ow2.easybeans.examples.entitybean
obr deploy org.ow2.easybeans.examples.stateless
obr deploy org.ow2.easybeans.examples.stateful
obr deploy org.ow2.easybeans.examples.messagedrivenbean
obr deploy org.ow2.easybeans.examples.migrationejb21
obr deploy org.ow2.easybeans.examples.timer
obr deploy org.ow2.easybeans.examples.security
Check
Using the 'ps' Felix Shell Command, you can verify that all your
bundles have been installed :
-> ps
START LEVEL 1
ID State Level Name
[ 0] [Active ] [ 0] System Bundle (1.0.0)
[ 1] [Active ] [ 1] Apache Felix Shell Service (1.0.0)
[ 2] [Active ] [ 1] Apache Felix Shell TUI (1.0.0)
[ 3] [Active ] [ 1] Apache Felix Bundle Repository (1.0.0)
…
[ 4] [Installed ] [ 1] Apache Felix Declarative Services (0.9.0.SNAPSHOT)
[ 5] [Installed ] [ 1] Apache Felix Configuration Admin Service (0.9.0.SNAPSHOT)
[ 6] [Installed ] [ 1] Apache Felix Log Service (0.9.0.incubator-SNAPSHOT)
[ 7] [Installed ] [ 1] EasyBeans/OSGi :: Core (1.0.0.RC1)
[ 8] [Installed ] [ 1] EasyBeans/OSGi :: Agent (1.0.0.RC1)
[ 9] [Installed ] [ 1] EasyBeans/OSGi :: Components :: Carol (1.0.0.RC1)
[ 10] [Installed ] [ 1] EasyBeans/OSGi :: Components :: JOTM (1.0.0.RC1)
[ 11] [Installed ] [ 1] EasyBeans/OSGi :: Components :: JORAM (1.0.0.RC1)
[ 12] [Installed ] [ 1] EasyBeans/OSGi :: Components :: Quartz (1.0.0.RC1)
[ 13] [Installed ] [ 1] EasyBeans/OSGi :: Components :: HSQLDB (1.0.0.RC1)
[ 14] [Installed ] [ 1] EasyBeans/OSGi :: Components :: JDBC Pool (1.0.0.RC1)
[ 15] [Installed ] [ 1] EasyBeans/OSGi :: Examples :: Entity Bean (1.0.0.RC1)
[ 16] [Installed ] [ 1] EasyBeans/OSGi :: Examples :: Stateless Session Bean (1.0.0.RC1)
[ 17] [Installed ] [ 1] EasyBeans/OSGi :: Examples :: Stateful Session Bean (1.0.0.RC1)
[ 18] [Installed ] [ 1] EasyBeans/OSGi :: Examples :: Migration EJB 2.1 -> 3.0 (1.0.0.RC1)
[ 19] [Installed ] [ 1] EasyBeans/OSGi :: Examples :: Security (1.0.0.RC1)
[ 20] [Installed ] [ 1] EasyBeans/OSGi :: Examples :: Timer (1.0.0.RC1)
...
Starting
Felix and Equinox provides the same shell command used to start bundles.
EasyBeans provides an "EasyBeans Agent" bundle which has the responsability
to start needed bundles in the right order.
Start the required services
[ 4] [Installed ] [ 1] Apache Felix Declarative Services (0.9.0.SNAPSHOT)
[ 5] [Installed ] [ 1] Apache Felix Configuration Admin Service (0.9.0.SNAPSHOT)
[ 6] [Installed ] [ 1] Apache Felix Log Service (0.9.0.incubator-SNAPSHOT)
So simply start this agent to start EasyBeans :
start <EasyBeans Agent - Bundle ID>
10/17/07 2:40:16 PM (W) Activator.start : Cannot find User configuration (easybeans.xml) for Easybeans. Using default configuration
INFO - 2:40:16 PM [B: org.ow2.easybeans.component.quartz] - BundleEvent RESOLVED.
INFO - 2:40:16 PM [B: org.ow2.easybeans.component.carol] - BundleEvent RESOLVED.
INFO - 2:40:16 PM [B: org.ow2.easybeans.component.jotm] - BundleEvent RESOLVED.
INFO - 2:40:16 PM [B: org.ow2.easybeans.component.joram] - BundleEvent RESOLVED.
INFO - 2:40:16 PM [B: org.ow2.easybeans.component.hsqldb] - BundleEvent RESOLVED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.jdbcpool] - BundleEvent RESOLVED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.component.carol [9]
INFO - 2:40:17 PM [S: carol-component-factory] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.carol] - BundleEvent STARTED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.component.jotm [10]
INFO - 2:40:17 PM [S: jotm-component-factory] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.jotm] - BundleEvent STARTED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.component.quartz [12]
INFO - 2:40:17 PM [S: quartz-component-factory] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.quartz] - BundleEvent STARTED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.component.hsqldb [13]
INFO - 2:40:17 PM [S: hsqldb-component-factory] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.hsqldb] - BundleEvent STARTED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.core [7]
INFO - 2:40:17 PM [S: core-component] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.core] - BundleEvent STARTED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.component.joram [11]
INFO - 2:40:17 PM [S: joram-component-factory] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.joram] - BundleEvent STARTED.
INFO - 2:40:17 PM [S: org.ow2.easybeans.component.carol.carolcomponent] - ServiceEvent REGISTERED.
10/17/07 2:40:17 PM (I) Activator.start : Starting Bundle org.ow2.easybeans.component.jdbcpool [14]
INFO - 2:40:17 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [S: jdbcpool-component-factory] - ServiceEvent REGISTERED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.component.jdbcpool] - BundleEvent STARTED.
INFO - 2:40:17 PM [B: org.ow2.easybeans.agent] - BundleEvent STARTED.
-> 10/17/07 2:40:17 PM (I) HSQLDBComponent.start : Starting 'HSQLDB server' '1.8.0' on port '9001'
10/17/07 2:40:18 PM (I) HSQLDBComponent.start : HSQLDB server started with URL jdbc:hsqldb:hsql://localhost:9001/jdbc_1
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent.13cd7594-68e7-48ea-8adf-48485390cfc6] - ServiceEvent REGISTERED.
10/17/07 2:40:18 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.hsqldb.hsqldbcomponent.13cd7594-68e7-48ea-8adf-48485390cfc6 created
10/17/07 2:40:18 PM (I) HSQLDBComponent.start : Starting 'HSQLDB server' '1.8.0' on port '9002'
10/17/07 2:40:18 PM (I) HSQLDBComponent.start : HSQLDB server started with URL jdbc:hsqldb:hsql://localhost:9002/jdbc_2
10/17/07 2:40:18 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.hsqldb.hsqldbcomponent.1326a5fa-e8b7-48f7-973b-a1f1841681ac created
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.carol.carolcomponent] - ServiceEvent REGISTERED.
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent] - ServiceEvent UNREGISTERING.
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.carol.carolcomponent] - ServiceEvent UNREGISTERING.
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent.1326a5fa-e8b7-48f7-973b-a1f1841681ac] - ServiceEvent REGISTERED.
10/17/07 2:40:18 PM (I) EZBComponentServiceFactory.deleted : Component with pid org.ow2.easybeans.component.hsqldb.hsqldbcomponent.1326a5fa-e8b7-48f7-973b-a1f1841681ac deleted
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent.1326a5fa-e8b7-48f7-973b-a1f1841681ac] - ServiceEvent UNREGISTERING.
10/17/07 2:40:18 PM (I) EZBComponentServiceFactory.deleted : Component with pid org.ow2.easybeans.component.hsqldb.hsqldbcomponent.13cd7594-68e7-48ea-8adf-48485390cfc6 deleted
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent.13cd7594-68e7-48ea-8adf-48485390cfc6] - ServiceEvent UNREGISTERING.
INFO - 2:40:18 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent] - ServiceEvent REGISTERED.
10/17/07 2:40:18 PM (I) TraceCarol.infoCarol : Name service for jrmp is started on port 1099
10/17/07 2:40:19 PM (I) EZBCoreService.activate : Activating EasyBeans/OSGi/Core
INFO - 2:40:19 PM [S: org.ow2.easybeans.component.carol.carolcomponent.703c04e3-da84-4d27-8161-bbd395aaa393] - ServiceEvent REGISTERED.
10/17/07 2:40:19 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.carol.carolcomponent.703c04e3-da84-4d27-8161-bbd395aaa393 created
10/17/07 2:40:20 PM (I) HSQLDBComponent.start : Starting 'HSQLDB server' '1.8.0' on port '9002'
10/17/07 2:40:20 PM (I) PolicyProvider.init : Using EasyBeans policy provider 'org.ow2.easybeans.security.jacc.provider.JPolicy'.
10/17/07 2:40:20 PM (I) PolicyProvider.init : Using EasyBeans PolicyConfigurationFactory provider and EasyBeans Policy provider
10/17/07 2:40:20 PM (I) HSQLDBComponent.start : HSQLDB server started with URL jdbc:hsqldb:hsql://localhost:9002/jdbc_2
10/17/07 2:40:20 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.hsqldb.hsqldbcomponent.1326a5fa-e8b7-48f7-973b-a1f1841681ac created
INFO - 2:40:20 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent.1326a5fa-e8b7-48f7-973b-a1f1841681ac] - ServiceEvent REGISTERED.
10/17/07 2:40:20 PM (I) HSQLDBComponent.start : Starting 'HSQLDB server' '1.8.0' on port '9001'
10/17/07 2:40:20 PM (I) JMXRemoteHelper.init : Creating JMXRemote connector with URL 'service:jmx:rmi:///jndi/rmi://localhost:1099/EasyBeansConnector'
10/17/07 2:40:20 PM (I) HSQLDBComponent.start : HSQLDB server started with URL jdbc:hsqldb:hsql://localhost:9001/jdbc_1
INFO - 2:40:20 PM [S: org.ow2.easybeans.component.hsqldb.hsqldbcomponent.13cd7594-68e7-48ea-8adf-48485390cfc6] - ServiceEvent REGISTERED.
10/17/07 2:40:20 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.hsqldb.hsqldbcomponent.13cd7594-68e7-48ea-8adf-48485390cfc6 created
10/17/07 2:40:21 PM (I) Embedded.start : Startup of EasyBeans '' was done in '959' ms.
INFO - 2:40:21 PM [S: null] - ServiceEvent REGISTERED.
INFO - 2:40:21 PM [S: org.ow2.easybeans.core] - ServiceEvent REGISTERED.
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.quartz.quartzcomponent] - ServiceEvent REGISTERED.
10/17/07 2:40:21 PM (I) QuartzScheduler.<init> : Quartz Scheduler v.1.6.0 created.
10/17/07 2:40:21 PM (I) RAMJobStore.initialize : RAMJobStore initialized.
10/17/07 2:40:21 PM (I) StdSchedulerFactory.instantiate : Quartz scheduler 'EasyBeans' initialized from an externally provided properties instance.
10/17/07 2:40:21 PM (I) StdSchedulerFactory.instantiate : Quartz scheduler version: 1.6.0
10/17/07 2:40:21 PM (I) QuartzScheduler.start : Scheduler EasyBeans_$_NON_CLUSTERED started.
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.quartz.quartzcomponent.d970f5e5-72c7-40b1-b271-649f2010de03] - ServiceEvent REGISTERED.
10/17/07 2:40:21 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.quartz.quartzcomponent.d970f5e5-72c7-40b1-b271-649f2010de03 created
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.jotm.jotmcomponent] - ServiceEvent REGISTERED.
10/17/07 2:40:21 PM (I) Current.<init> : JOTM 2.0.10
10/17/07 2:40:21 PM (I) JOTMComponent.start : Register javax.transaction.UserTransaction as transaction manager object
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.jotm.jotmcomponent.611f659c-6edc-4461-b1c5-8bce9dab15bc] - ServiceEvent REGISTERED.
10/17/07 2:40:21 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.jotm.jotmcomponent.611f659c-6edc-4461-b1c5-8bce9dab15bc created
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.jdbcpool.jdbcpoolcomponent] - ServiceEvent REGISTERED.
10/17/07 2:40:21 PM (I) JDBCPoolComponent.start : DS 'jdbc_2', URL 'jdbc:hsqldb:hsql://localhost:9002/jdbc_2', Driver = 'org.hsqldb.jdbcDriver'.
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.jdbcpool.jdbcpoolcomponent.e778269f-fce4-40a1-87fa-33119f5d3bde] - ServiceEvent REGISTERED.
10/17/07 2:40:21 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.jdbcpool.jdbcpoolcomponent.e778269f-fce4-40a1-87fa-33119f5d3bde created
10/17/07 2:40:21 PM (I) JDBCPoolComponent.start : DS 'jdbc_1', URL 'jdbc:hsqldb:hsql://localhost:9001/jdbc_1', Driver = 'org.hsqldb.jdbcDriver'.
10/17/07 2:40:21 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.jdbcpool.jdbcpoolcomponent.80097f80-eed9-4b99-a4e3-5ff1b05c52a0 created
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.jdbcpool.jdbcpoolcomponent.80097f80-eed9-4b99-a4e3-5ff1b05c52a0] - ServiceEvent REGISTERED.
INFO - 2:40:21 PM [S: org.ow2.easybeans.component.joram.joramcomponent] - ServiceEvent REGISTERED.
10/17/07 2:40:22 PM (I) JoramComponent.start : Joram version '5.0.6' started on localhost:16030.
INFO - 2:40:22 PM [S: org.ow2.easybeans.component.joram.joramcomponent.afdee04d-ef2b-4051-b706-a8901c4879f1] - ServiceEvent REGISTERED.
10/17/07 2:40:22 PM (I) EZBComponentServiceFactory.updated : Component with pid org.ow2.easybeans.component.joram.joramcomponent.afdee04d-ef2b-4051-b706-a8901c4879f1 created
Samples
Deployment
See Section III if EJB 3.0 Samples bundles are not deployed on the gateway.
Start
EJB 3.0 Sample bundles can be started like all other bundles :
start <EasyBeans Sample - Bundle ID>
0
INFO - 2:41:14 PM [B: org.ow2.easybeans.examples.stateless] - BundleEvent RESOLVED.
10/17/07 2:41:15 PM (I) JContainer3.start : Container started in : 864 ms
INFO - 2:41:15 PM [S: null] - ServiceEvent REGISTERED.
INFO - 2:41:15 PM [B: org.ow2.easybeans.examples.stateless] - BundleEvent STARTED.
10/17/07 2:41:32 PM (I) JContainer3.start : Container started in : 174 ms
-> INFO - 2:41:32 PM [B: org.ow2.easybeans.examples.migrationejb21] - BundleEvent STARTED.
INFO - 2:41:32 PM [S: null] - ServiceEvent REGISTERED.
INFO - 2:41:32 PM [B: org.ow2.easybeans.examples.migrationejb21] - BundleEvent RESOLVED.
- Entity Bean (deployed by Hibernate's EntityManager)
INFO - 2:41:48 PM [B: org.ow2.easybeans.examples.entitybean] - BundleEvent RESOLVED.
10/17/07 2:41:49 PM (I) JPersistenceUnitInfoHelper.loadDefaultValues : Default persistence provider set to value org.hibernate.ejb.HibernatePersistence.
10/17/07 2:41:49 PM (I) JPersistenceUnitInfoHelper.getPersistenceUnitInfo : No persistence provider was set, set to value org.hibernate.ejb.HibernatePersistence.
10/17/07 2:41:49 PM (I) Version.<clinit> : Hibernate Annotations 3.3.0.GA
10/17/07 2:41:49 PM (I) Environment.<clinit> : Hibernate 3.2.5
10/17/07 2:41:49 PM (I) Environment.<clinit> : hibernate.properties not found
10/17/07 2:41:49 PM (I) Environment.buildBytecodeProvider : Bytecode provider name : cglib
10/17/07 2:41:49 PM (I) Environment.<clinit> : using JDK 1.4 java.sql.Timestamp handling
10/17/07 2:41:49 PM (I) Version.<clinit> : Hibernate EntityManager 3.3.1.GA
10/17/07 2:41:49 PM (I) Ejb3Configuration.configure : Processing PersistenceUnitInfo [
name: entity
...]
10/17/07 2:41:49 PM (I) Ejb3Configuration.scanForClasses : found EJB3 Entity bean: org.ow2.easybeans.examples.entitybean.Employee
10/17/07 2:41:49 PM (I) Ejb3Configuration.scanForClasses : found EJB3 Entity bean: org.ow2.easybeans.examples.entitybean.Employee
10/17/07 2:41:49 PM (I) AnnotationBinder.bindClass : Binding entity from annotated class: org.ow2.easybeans.examples.entitybean.Employee
10/17/07 2:41:49 PM (I) EntityBinder.bindTable : Bind entity org.ow2.easybeans.examples.entitybean.Employee on table EMPLOYEES
10/17/07 2:41:49 PM (I) Version.<clinit> : Hibernate Validator 3.0.0.GA
10/17/07 2:41:50 PM (I) ConnectionProviderFactory.newConnectionProvider : Initializing connection provider: org.hibernate.ejb.connection.InjectedDataSourceConnectionProvider
10/17/07 2:41:50 PM (I) InjectedDataSourceConnectionProvider.configure : Using provided datasource
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : RDBMS: HSQL Database Engine, version: 1.8.0
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : JDBC driver: HSQL Database Engine Driver, version: 1.8.0
10/17/07 2:41:50 PM (I) Dialect.<init> : Using dialect: org.hibernate.dialect.HSQLDialect
10/17/07 2:41:50 PM (I) TransactionFactoryFactory.buildTransactionFactory : Transaction strategy: org.hibernate.ejb.transaction.JoinableCMTTransactionFactory
10/17/07 2:41:50 PM (I) TransactionManagerLookupFactory.getTransactionManagerLookup : instantiating TransactionManagerLookup: org.hibernate.transaction.JOTMTransactionManagerLookup
10/17/07 2:41:50 PM (I) TransactionManagerLookupFactory.getTransactionManagerLookup : instantiated TransactionManagerLookup
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Automatic flush during beforeCompletion(): disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Automatic session close at end of transaction: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : JDBC batch size: 15
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : JDBC batch updates for versioned data: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Scrollable result sets: enabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : JDBC3 getGeneratedKeys(): disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Connection release mode: auto
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Default batch fetch size: 1
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Generate SQL with comments: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Order SQL updates by primary key: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Order SQL inserts for batching: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.createQueryTranslatorFactory : Query translator: org.hibernate.hql.ast.ASTQueryTranslatorFactory
10/17/07 2:41:50 PM (I) ASTQueryTranslatorFactory.<init> : Using ASTQueryTranslatorFactory
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Query language substitutions: {}
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : JPA-QL strict compliance: enabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Second-level cache: enabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Query cache: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.createCacheProvider : Cache provider: org.hibernate.cache.HashtableCacheProvider
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Optimize cache for minimal puts: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Structured second-level cache entries: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Statistics: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Deleted entity synthetic identifier rollback: disabled
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Default entity-mode: pojo
10/17/07 2:41:50 PM (I) SettingsFactory.buildSettings : Named query checking : enabled
10/17/07 2:41:50 PM (I) SessionFactoryImpl.<init> : building session factory
10/17/07 2:41:51 PM (I) SessionFactoryObjectFactory.addInstance : Not binding factory to JNDI, no JNDI name configured
10/17/07 2:41:51 PM (I) SchemaExport.execute : Running hbm2ddl schema export
10/17/07 2:41:51 PM (I) SchemaExport.execute : exporting generated schema to database
10/17/07 2:41:51 PM (I) SchemaExport.execute : schema export complete
10/17/07 2:41:51 PM (I) JContainer3.start : Container started in : 2713 ms
-> INFO - 2:41:51 PM [S: null] - ServiceEvent REGISTERED.
INFO - 2:41:51 PM [B: org.ow2.easybeans.examples.entitybean] - BundleEvent STARTED.
Run the clients (Stateless, Stateful, Entity and MessageDriven)
In the unpacked assembly directory, there is a 'build.xml' Ant file
that must be used to launch Clients :
Conclusion
The EasyBeans/OSGi integration have been succesfully tested with Apache Felix and Eclipse Equinox.
You own EjbJars can be easily packaged as bundles : it's as simple as adding a META-INF/MANIFEST.MF file in your EjbJar.