bnd

Unable to use Maven Central Repository with bnd to resolve dependencies

和自甴很熟 提交于 2019-12-13 00:46:50
问题 With Eclipse Oxygen.2 Release (4.7.2), I'm trying to use bndtools to make some OSGi bundles. By default (with the JPM repository) I am able to resolve dependencies fine. But I have no way of seeing what libraries are there. Because of this, I'd like to use Maven Central to handle my dependencies. I can browse the website, see what versions are there, and make choices on that information. The default build.bnd file in the cnf project has the repositories setup like # Configure Repositories

BND puts the same package to both export and import sections of manifest.mf

余生长醉 提交于 2019-12-12 14:39:35
问题 I have a Vaadin application, which I'm trying to build as a set of OSGI bundles using Maven + BND. I can't deploy the bundles To Apache Felix because some dependencies can't be resolved. Apache Felix complains that can't find package XYZ required by bundle "A", although this package is defined in this same bundle!! I looked at the MANIFEST.MF file generated by Maven + BND and saw that the package (XYZ) from this bundle is added to both "import" and "export" sections. I understand why "export"

Wrap third party jar that imports from default package using bndtools

半世苍凉 提交于 2019-12-11 22:06:27
问题 I want to wrap a third party jar. Unfortunately the vendor placed one single class (a.class) with one single method into the default package. When I try to include the resource using Include-Resource: @lib/acme-8.0.jar , it results in the following error: The default package '.' is not permitted by the Import-Package syntax. This can be caused by compile errors in Eclipse because Eclipse creates valid class files regardless of compile errors. The following package(s) import from the default

Error implementing a OSGI REST: `OSGi bundle not started : missing requirement`

三世轮回 提交于 2019-12-11 04:13:50
问题 I'm trying to code a OSGI REST bundle with bndtools. I added all the jars that I need in the cnf project. Then I added them to the bundle build path. I get the following runtime exception OSGi bundle not started : missing requirement osgi.wiring.package (&(osgi.wiring.package=javax.ws.rs)(version =2.0.0)( (version =3.0.0))) I don't understand the error because I use javax.ws.rs-api 2.0.1. I tried to specify the version explicitly in the buildpath like this -buildpath: \ javax.ws.rs-api

Override Require-Capability in Maven-Bundle-Plugin

被刻印的时光 ゝ 提交于 2019-12-10 19:27:07
问题 My question is similar to this one but I am using the Maven bundle plugin to achieve the same end result. I am building a bundle that contains a persistence.xml file and I have found that the maven-bundle-plugin automatically generates the following headers in the manifest: Require-Capability:osgi.service;effective:=active;objectClass=javax.persistence.spi.PersistenceProvider;javax.persistence.provider=org.apache.openjpa.persistence.PersistenceProviderImpl, Require-Capability: osgi.extender

WebLogic and OSGi

久未见 提交于 2019-12-10 06:10:06
问题 Is there a way to run an OSGi container in the Weblogic Application Server? I know that it works with JBoss, Glassfish and there are possibilities to add an Equinox servlet bridge to your OSGi project (implementation of the bridge is too old). But I want something similar to JBoss/Glassfish functionality where it is very easy to deploy your OSGi environment, because there are already OSGi implementations. Most of the articels I found were very old and there are no more recent ones. Can

How to OSGIfy a library

笑着哭i 提交于 2019-12-09 11:24:39
问题 I'm working on a project, it's integration project, we are using Apache Camel and Apache Karaf. In the project, I need to use the Jira REST Java client library. So I've read quite a lot of various articles and threads about how to wrap non-OSGI library to OSGI bundle, but I'm really not sure if I got it right. So, I've created a POM file with a dependency to the needed library. Made a package and tried to deploy it to Karaf, of course, Karaf complained for missing packages. So, I've found

WebLogic and OSGi

自古美人都是妖i 提交于 2019-12-05 14:03:30
Is there a way to run an OSGi container in the Weblogic Application Server? I know that it works with JBoss, Glassfish and there are possibilities to add an Equinox servlet bridge to your OSGi project (implementation of the bridge is too old). But I want something similar to JBoss/Glassfish functionality where it is very easy to deploy your OSGi environment, because there are already OSGi implementations. Most of the articels I found were very old and there are no more recent ones. Can someone help with hints or better some links? Maybe Bnd could create a .war file for me, but how can I

What does the private-package manifest header do?

半城伤御伤魂 提交于 2019-12-05 12:57:27
问题 I am familiar with Import-Package and Export-Package , but this is a new one for me. What does it do? 回答1: At runtime in the OSGi container it does nothing. In fact, it's not even mentioned in the OSGi specification (I checked R4). However, it can be specified in a .bnd file for use by bnd at build time. If so, it can be used to determine what goes into the bundle. When bnd builds a bundle, it automatically determines which classes need to go into the bundle. All the classes in packages that

Continuous deployment of OSGi-based application on jenkins

ぐ巨炮叔叔 提交于 2019-12-04 08:35:27
问题 After spending a couple of hours trying to understand how to make continuous deployment work in the case of an OSGi-based application , I am finally posing my first question on stackoverflow, hoping for some indications on what I might have done wrong or missed - somehow I feel being on the wrong track... This is what I want to achieve: build some bundles and install them to the maven repository (no problem here, using bnd) now having all the bundles making up my application (passing all