db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Chemouil (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-4120) derbyclient.jar is not a complete OSGi bundle
Date Thu, 24 Feb 2011 16:54:38 GMT

    [ https://issues.apache.org/jira/browse/DERBY-4120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12998932#comment-12998932
] 

Simon Chemouil commented on DERBY-4120:
---------------------------------------

Using 10.6.1, we experienced a problem with the manifest of derbyclient.jar which exports
org.apache.derby.jdbc, a package that is *already* exported by derby.jar. It is thus impossible
to use them both at the same time, in the same OSGi container, because the resolver will do
the package wiring with only one of these. In our case it prevented us from using the Embedded
JDBC driver from derby.jar.

Three fixes are possible:
- change the name of the jdbc driver package of derbyclient (e.g org.apache.derby.client.jdbc).
That's the cleanest solution, even though it might break code. The *old* package name could
be kept for backwards compatibility but not exported, so only non-OSGi installations would
be affected.
- make derbyclient a "fragment" bundle of derby.jar, so they would be merged at runtime. I
don't think this is proper, because it would imply a dependency of derbyclient on derby (that
doesn't currently exist), and I'm not sure it makes sense. Then again, I don't know derby
at all :-). I'm just integrating code that's using it.
- use the split-package directive to tell the OSGi framework to do more complex package wiring,
this is not recommanded though, but it's a solution. See http://code9.com/2008/08/22/tip-split-packages-and-visibility/
(google has more on the topic)

So I believe this bug should be re-opened. Thanks

> derbyclient.jar is not a complete OSGi bundle
> ---------------------------------------------
>
>                 Key: DERBY-4120
>                 URL: https://issues.apache.org/jira/browse/DERBY-4120
>             Project: Derby
>          Issue Type: Bug
>          Components: Eclipse Plug-in, Services
>    Affects Versions: 10.4.2.0
>         Environment: OSGi
>            Reporter: JJ Snyder
>            Assignee: Bryan Pendleton
>             Fix For: 10.5.3.1, 10.6.1.0
>
>         Attachments: addToManifest.diff
>
>
> The manifest in derbyclient.jar is incomplete for usage in OSGi.  There are no packages
exported.  This appears to only be a problem in standalone equinox (outside of eclipse). 
Note that I did not try other OSGi containers.
> The fix is relatively simple.  Adding the Export-Package manifest header should take
care of the problem.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message