osgi

Optional bundle resolution

天涯浪子 提交于 2019-12-11 12:18:11
问题 I'm new in OSGi. I wrote JIRA plugin which is Apache Felix Bundle. My bundle uses Sprring Framework RestTemplate and Jackson XML for a simple REST API call. So I use other bundle (available on OSGi containter) : Apache ServiceMix :: Bundles :: spring-web which has <Import-Package> set to com.fasterxml.jackson.*; version="[2,3)";resolution:="optional" I installed jackson-databind, jackson-core and jackson-annotations (all in version 2.6.5) on OSGi container to provide missing, optional

Felix How to get list of all dependent bundles from the updated bundle [duplicate]

我是研究僧i 提交于 2019-12-11 11:41:23
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: Find the dependent bundles in Eclipse at runtime How to get list of all dependent bundles from the updated bundle? For example, situation when some application loaded same bundles. In one time I will update one bundle. How can I get all bundles which depend on the updated bundle? This is necessary in order to restart all bundles which depend on the updated bundle, so they can see a new object of the updated

OSGi Bundle status is not Active (CQ5 Maven Project) WHY?

五迷三道 提交于 2019-12-11 10:55:07
问题 I know that when the status of a bundle in CQ is installed, there are dependencies and that is why the bundle cannot be "Active". I am using a Jersey Client v 2.17 in a CQ5 Service, so I need the Jersey Core Client Jar. I added the dependency in the /bundle/pom.xml . My bundle successfully compiles and deploys BUT NEVER TURNS ACTIVE I added the Jersey Client Jar in Felix Console manually, by doing this my bundle got activated but the Jersey Client Jar is not active so I keep getting

setting startlevel for OSGI bundle

让人想犯罪 __ 提交于 2019-12-11 10:47:20
问题 (I use glassfish 3.1, felix) I have a log bundle that needs to be started before other bundles in my glassfish server. Is there a way to configure startlevel for a single OSGI bundle? Any of the following ways will be fine: configuring a properties file, solution on java side, header in bundle manifest. thanks. 回答1: In Felix, you can change the launcher properties (for instance, conf/config.properties ) to start bundles with different start levels. You can use the felix.auto.deploy.install.<n

Does Eclipselink use (dynamic) bytecode weaving under Apache Felix?

萝らか妹 提交于 2019-12-11 10:43:14
问题 I'm using the Eclipselink bundles from Springsource (version 1.1.0) inside Apache Felix. My (JPA annotated) entity classes get persisted etc., so the basic mechanism works. However, I'm doubting that bytecode weaving is done. How can I verify if Eclipselink uses weaving on my classes? Is weaving generally supported when running in Felix? I didn't change anything about my configuration or startup scripts, do I have to? 回答1: See Eclipse docs - bottom of page; import org.eclipse.persistence

Startup for bundles placed in the deploy folder of Karaf

岁酱吖の 提交于 2019-12-11 10:40:19
问题 I have two bundles - bundle-A exports bnd.a.* packages and bundle-B imports bnd.a.*; I keep these bundles in the deploy folder; it works but there are times when bundle-B comes first before bundle-A and fails! Is there a way to set the start up order for bundles kept in the deploy folder? Please note that we got it working using feature's start level but not right in the deploy folder. 回答1: No, as the deploy folder is just another way of deploying bundles during development time. For

Several versions of a plugin in a feature.xml

此生再无相见时 提交于 2019-12-11 10:39:19
问题 I've created an feature-based Eclipse product where all dependencies respectively external plugins are specified in a dependencies feature project. Some dependencies need different versions of the same plugin. How can I specify several versions of a plugin in a feature.xml? Eclipse seems to always use the current version of a plugin. I've tried to add a dependency with a strict version interval, e.g. [1.6.0.v201011041432,1.6.0.v201011041432] , in the feature.xml but Eclipse doesn't accept

Eclipse RCP - Wrong plugin version gets exported

心不动则不痛 提交于 2019-12-11 10:36:37
问题 I have a eclipse 4 application project with a plug-in based product configuration. All necessary plugins are added into the dependencies tab on the .product file & generating a run configuration out of this .product file works flawless. But when exporting the .product as eclipse product, it's not working - the cause it probably, that the wrong versions from a few plugins are exported. The error log contains messages like this: org.osgi.framework.BundleException: Could not resolve module: org

usecase of metatype attribute in felix scr annotations

点点圈 提交于 2019-12-11 10:08:23
问题 I am using scr annotations in my project. Can anybody explain the usecase of metatype attribute in @Component annotation? import org.apache.felix.scr.annotations.Activate; import org.apache.felix.scr.annotations.Component; import org.apache.felix.scr.annotations.Reference; import org.apache.felix.scr.annotations.ReferenceCardinality; import org.apache.felix.scr.annotations.ReferencePolicy; import org.apache.felix.scr.annotations.Service; @Component (name = "SampleComponent", label =

OSGi - running outside eclipse

旧时模样 提交于 2019-12-11 08:23:27
问题 I have been working on getting my OSGi application to run outside eclipse. It has certainly wasn't as easy as I thought out would be certainly not just a case of running java -jar org.eclipse.osgi_3.7.1.jar and installing the plugins. I'm hoping this is the last problem java.sql.SQLException: No suitable driver found for jdbc:mysql://localhost:3306/ This works fine in Eclipse. I have a persistence bundle and several fragmentation bundles that I load depending on the database type that I