Please file a Jira. If you could supply a patch that would be great as we are short on OSGi expertise here.
Ralph On Aug 9, 2013, at 6:41 AM, Roland wrote: > Hi all Log4j/OSGi experts! > > Yesterday I started to migrate from log4j to log4j2. I replaced all Log4j > 1.x bundles with log4j-1.2-api as described here: > http://logging.apache.org/log4j/2.x/log4j-1.2-api/index.html > > But I got following error: > > Unresolved constraint in bundle MyBundle [21]: Unable to resolve 21.0: > missing requirement [21.0] osgi.wiring.package; > (&(osgi.wiring.package=org.apache.log4j)(version>=1.2.0)(!(version>=2.0.0))) > > so...I checked the status of my OSGi-environment: > > g! inspect cap * 11 > org.apache.logging.log4j-1.2-api [11] provides: > ----------------------------------------------- > osgi.wiring.bundle; org.apache.logging.log4j-1.2-api 2.0.0.beta8 [UNUSED] > osgi.wiring.host; org.apache.logging.log4j-1.2-api 2.0.0.beta8 [UNUSED] > g! lb > START LEVEL 4 > ID|State |Level|Name > 0|Active | 0|System Bundle (4.2.1) > 4|Active | 2|Apache Felix Bundle Repository (1.6.6) > 5|Active | 2|Apache Felix Configuration Admin Service (1.6.0) > 6|Active | 2|Apache Felix Gogo Command (0.12.0) > 7|Active | 2|Apache Felix Gogo Runtime (0.10.0) > 8|Active | 2|Apache Felix Gogo Shell (0.10.0) > 9|Resolved | 2|Apache Felix Security Provider (2.2.0) > 10|Active | 2|Apache Felix Shell Service (1.4.3) > 11|Active | 2|Apache Log4j 1.x Compatibility API (2.0.0.beta8) > 12|Active | 2|Apache Log4j API (2.0.0.beta4) > 13|Active | 2|Apache Log4j Commons Logging Bridge (2.0.0.beta4) > 14|Active | 2|Apache Log4J Core (2.0.0.beta4) > 15|Active | 2|cal10n-api (0.7.4) > 16|Active | 2|Commons IO (2.4.0) > 17|Active | 2|Commons Lang (2.6.0) > 18|Active | 2|Data mapper for Jackson JSON processor (1.9.13) > 19|Active | 2|Jackson JSON processor (1.9.13) > 20|Active | 2|JSON.simple (1.1.1) > 21|Installed | 2|MyBundle (1.0.0.0) > > permissions.perm > (org.osgi.framework.PackagePermission "org.apache.log4j" "import") > > As you can see logging.log4j-1.2-api doesn't export the log4j API 1.2. It > still requires log4j 1.2. So, replacing the JARs as described in the manual > does not work. Something is wrong. What can I do? > > Thanks in advance! > Roland > > > > -- > View this message in context: > http://apache-logging.6191.n7.nabble.com/log4j-1-2-api-unresolved-package-org-apache-log4j-tp39509.html > Sent from the Log4j - Users mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
