commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rico Neubauer (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CONFIGURATION-639) OSGi Import-Package declaration not complete regarding optional dependencies
Date Wed, 07 Sep 2016 07:54:22 GMT

     [ https://issues.apache.org/jira/browse/CONFIGURATION-639?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Rico Neubauer updated CONFIGURATION-639:
----------------------------------------
    Description: 
common-configuration2's pom.xml correctly defines optional dependencies like vfs2 or spring
with <optional>.
However, it does only declare a subset of those as optional OSGi-dependencies:
{code:xml}
    <!-- Explicitly declare optional dependencies for the OSGi manifest. -->
    <commons.osgi.import>
      org.apache.commons.beanutils.*;resolution:=optional,
      org.apache.commons.codec.*;resolution:=optional,
      org.apache.commons.jxpath.*;resolution:=optional,
      org.apache.xml.resolver.*;resolution:=optional,
      javax.servlet.*;resolution:=optional,
      org.apache.commons.jexl2.*;resolution:=optional,
      org.apache.commons.vfs2.*;resolution:=optional,
      *
    </commons.osgi.import>
{code}
See https://github.com/apache/commons-configuration/blob/trunk/pom.xml for both above.
Due to the missing "resolution:=optional, commons-configuration2 cannot be deployed in an
OSGi-environment not providing the optional bundles.

Example error on deploy:
{code}
Unable to resolve Module[org.apache.commons.configuration:2.1.0]: missing requirement [Module[org.apache.commons.configuration:2.1.0]]
package; (package=org.springframework.beans.factory)
{code}

Please have a look if you agree and add the missing instructions for the remaining optional
dependencies.

Manually fixed export-package statement looks like this (disregarding line-breaks):
{code}
Export-Package: org.apache.commons.configuration2;version="2.1",org.apache.commons.configuration2.beanutils;version="2.1",org.apache.commons.configuration2.builder;version="2.1",org.apache.commons.configuration2.builder.combined;version="2.1",org.apache.commons.configuration2.builder.fluent;version="2.1",org.apache.commons.configuration2.convert;version="2.1",org.apache.commons.configuration2.event;version="2.1",org.apache.commons.configuration2.ex;version="2.1",org.apache.commons.configuration2.interpol;version="2.1",org.apache.commons.configuration2.io;version="2.1",org.apache.commons.configuration2.plist;version="2.1",org.apache.commons.configuration2.reloading;version="2.1",org.apache.commons.configuration2.resolver;version="2.1",org.apache.commons.configuration2.spring;version="2.1",org.apache.commons.configuration2.sync;version="2.1",org.apache.commons.configuration2.tree;version="2.1",org.apache.commons.configuration2.tree.xpath;version="2.1",org.apache.commons.configuration2.web;version="2.1"
{code}

  was:
common-configuration2's pom.xml correctly defines optional dependencies like vfs2 or spring
with <optional>.
However, it does only declare a subset of those as optional OSGi-dependencies:
{code:xml}
    <!-- Explicitly declare optional dependencies for the OSGi manifest. -->
    <commons.osgi.import>
      org.apache.commons.beanutils.*;resolution:=optional,
      org.apache.commons.codec.*;resolution:=optional,
      org.apache.commons.jxpath.*;resolution:=optional,
      org.apache.xml.resolver.*;resolution:=optional,
      javax.servlet.*;resolution:=optional,
      org.apache.commons.jexl2.*;resolution:=optional,
      org.apache.commons.vfs2.*;resolution:=optional,
      *
    </commons.osgi.import>
{code}
See https://github.com/apache/commons-configuration/blob/trunk/pom.xml for both above.
Due to the missing "resolution:=optional, commons-configuration2 cannot be deployed in an
OSGi-environment not providing the optional bundles.

Example error on deploy:
{code}
Unable to resolve Module[org.apache.commons.configuration:2.1.0]: missing requirement [Module[org.apache.commons.configuration:2.1.0]]
package; (package=org.springframework.beans.factory)
{code}

Please have a look if you agree and add the missing instructions for the remaining optional
dependencies.


> OSGi Import-Package declaration not complete regarding optional dependencies
> ----------------------------------------------------------------------------
>
>                 Key: CONFIGURATION-639
>                 URL: https://issues.apache.org/jira/browse/CONFIGURATION-639
>             Project: Commons Configuration
>          Issue Type: Bug
>    Affects Versions: 2.1
>         Environment: OSGi-container
>            Reporter: Rico Neubauer
>              Labels: commons-configuration, osgi
>
> common-configuration2's pom.xml correctly defines optional dependencies like vfs2 or
spring with <optional>.
> However, it does only declare a subset of those as optional OSGi-dependencies:
> {code:xml}
>     <!-- Explicitly declare optional dependencies for the OSGi manifest. -->
>     <commons.osgi.import>
>       org.apache.commons.beanutils.*;resolution:=optional,
>       org.apache.commons.codec.*;resolution:=optional,
>       org.apache.commons.jxpath.*;resolution:=optional,
>       org.apache.xml.resolver.*;resolution:=optional,
>       javax.servlet.*;resolution:=optional,
>       org.apache.commons.jexl2.*;resolution:=optional,
>       org.apache.commons.vfs2.*;resolution:=optional,
>       *
>     </commons.osgi.import>
> {code}
> See https://github.com/apache/commons-configuration/blob/trunk/pom.xml for both above.
> Due to the missing "resolution:=optional, commons-configuration2 cannot be deployed in
an OSGi-environment not providing the optional bundles.
> Example error on deploy:
> {code}
> Unable to resolve Module[org.apache.commons.configuration:2.1.0]: missing requirement
[Module[org.apache.commons.configuration:2.1.0]] package; (package=org.springframework.beans.factory)
> {code}
> Please have a look if you agree and add the missing instructions for the remaining optional
dependencies.
> Manually fixed export-package statement looks like this (disregarding line-breaks):
> {code}
> Export-Package: org.apache.commons.configuration2;version="2.1",org.apache.commons.configuration2.beanutils;version="2.1",org.apache.commons.configuration2.builder;version="2.1",org.apache.commons.configuration2.builder.combined;version="2.1",org.apache.commons.configuration2.builder.fluent;version="2.1",org.apache.commons.configuration2.convert;version="2.1",org.apache.commons.configuration2.event;version="2.1",org.apache.commons.configuration2.ex;version="2.1",org.apache.commons.configuration2.interpol;version="2.1",org.apache.commons.configuration2.io;version="2.1",org.apache.commons.configuration2.plist;version="2.1",org.apache.commons.configuration2.reloading;version="2.1",org.apache.commons.configuration2.resolver;version="2.1",org.apache.commons.configuration2.spring;version="2.1",org.apache.commons.configuration2.sync;version="2.1",org.apache.commons.configuration2.tree;version="2.1",org.apache.commons.configuration2.tree.xpath;version="2.1",org.apache.commons.configuration2.web;version="2.1"
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message