EasyBeans is an open source implementation by ObjectWeb of the EJB3 container specification. 
X Wiki
  History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: BUNDLE-6
Type: Improvement Improvement
Status: Open Open
Priority: Major Major
Assignee: Florent BENOIT
Reporter: ekkehard gentz
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
OW2 Bundles

Bundle-Import and Export wrong (ow2-bundles-externals-commons-logging)

Created: 12/Jul/08 03:57 PM   Updated: 15/Jul/08 05:14 PM
Component/s: Commons Logging
Affects Version/s: None
Fix Version/s: None

Environment: Eclipse 3.4, Equinox 3.4


 Description  « Hide
I'm having some problems using ow2-bundles-externals-commons-logging.
(Main problem is that you not support Log4J, but thats another JIRA ;-)

ow2-bundles-externals-commons-logging has an import of commons.logging,
also an export and also includes the commons.logging jar itself.

this causes some problems, which could be fixed:

1. remove the import commons.logging, because you have it inside the bundle

2. export the commons-logging with a version number, because other bundles rely on a version number
I've changed it into
Export-Package: org.apache.commons.logging;version="1.0.4"

 All   Comments   Change History   Related Builds   Subversion Commits      Sort Order:
Florent BENOIT - 15/Jul/08 03:58 PM
Well I think that the main issue is linked to the missing import on log4j

ekkehard gentz - 15/Jul/08 04:16 PM
yes, thats the main issue,
but its also problematic if you import the same packages you own in the bundle

I have the same problem with the core bundle: imports many many packages,
but owns the packages itself in /dependencies/xxx.jar and then exports them also

so - if there's anywhere a bundle exporting one of those packages, too,
then eclipse PDE detects a cycle and I cannot deploy a bundle with a dependency to easybeans.core -
I first have to remove those imports

but - as I wrote in the list, I'm working on it to "unbundle" all those jars from core
will take some time... I'll report my solution

ekke

Florent BENOIT - 15/Jul/08 04:24 PM
I have some problems with transforming each module into a bundle. The main issue is that we've to deploy several jars in order to get something working.
For someone that wants only get EasyBeans running on an OSGi gateway, this may be problematic.
But for users having existing bundles, this is not great to have some monolitic bundles as classes are not shared.

Maybe the best way could be to have some "installation" bundle that may install automatically a set of bundles.So users don't have to bother to install tons of jar in order to get something working and all is modular which is fine.

Also, it's a common feature to import what we export. This avoid to get ClassCastException if two bundles are exporting the same packages.

ekkehard gentz - 15/Jul/08 04:44 PM
I had the following scenario:

Eclipse 3.4, with PDE target platform

this target platform includes:

com.springsource.javax.ejb-3.0.0 (I need this for my client bundles using the API)
easybeans.core imports , owns and exports the packages from ejb.jar

then I developed a bundle with
package-import ejb.jar
and cannot deploy it from PDE, got a report:
cycle com.springsource.javax.ejb-3.0.0; easybeans.core; com.springsource.javax.ejb-3.0.0

after removing the imports from easybeans.core it works well

ekke

ekkehard gentz - 15/Jul/08 04:48 PM
>Maybe the best way could be to have some "installation" bundle that may install automatically a set of bundles.So users don't have to bother to install tons of jar in order to get something working and all is modular which is fine.
---------

yes, that would be a great soliution

at the moment its problematic if you're combining some bundle from different vendors
where each vendor has a big core.bundle containing all what a single installation would need

also problematic is an export without version number, because some bundles need versions for import

ekke

Florent BENOIT - 15/Jul/08 05:14 PM
Yes, big bundles are great in some cases and very problematic for many other cases
So we need to find a way to use "small" bundles (with maven, we already have modules, so one module = one bundle) but to make it easy for end users (and that it is fine also for advanced users)


Copyright © 2006-2007 EasyBeans / ObjectWeb consortium

http://www.easybeans.org