osgi

How do I add the command XX:-UseSplitVerifier to an OSGi bundle built in CRXDE Lite (CQ5.5)?

孤人 提交于 2019-12-13 05:08:15
问题 I am trying to create a custom WCMCommand in CQ5.5. I have JDK1.7 and am getting the dreaded VerifyError. ERROR [OsgiInstallerImpl] pack.age.name [pack.age.name] Error during instantiation of the implementation object (java.lang.VerifyError: Expecting a stackmap frame at branch target 13 in method pack.age.name.unbindRepo(Lorg/apache/sling/jcr/api/SlingRepository;)V at offset 5) java.lang.VerifyError: Expecting a stackmap frame at branch target 13 in method pack.age.name.unbindRepo(Lorg

Why should one create & use services in OSGi

限于喜欢 提交于 2019-12-13 04:35:22
问题 I have been studying OSGi for past week but the sole reason doesn't seem to fit right that why do I need to register and use any bundle when I can do it by simply importing its JAR file. What benefit do I achieve by doing so? Yea sure, I do get the dependency management but: can I use any other JAR files by importing them which are not registered as services itself? If yes, why should I take the overhead of using OSGi? 回答1: The whole idea of OSGi is that you get modularity: clear separation

CQ5 OSGi bundle does not start:- Activator cannot be found

我与影子孤独终老i 提交于 2019-12-13 04:34:43
问题 I am working on a Mollom captcha implementation (as a component), for which I need an OSGI bundle created. I created one using eclipse (because it required a couple of more jars so as to compile correctly). Although the bundle was created without any errors, when I upload the jar onto the OSGi console, it just does not start. I opened up error.log and I find this:- 27.09.2013 12:10:33.264 *INFO* [pool-6-thread-34-com/day/cq/replication/job/publish(com/day/cq/replication/job/publish)] com.day

Osgi Equinox enable component from external bundle

不想你离开。 提交于 2019-12-13 04:33:28
问题 Given this scenario: Bundle A: component 1A (enabled:false) Bundle B: component 2B How can i enable component 1A from Bundle B or Component 2B? I've tried to do it by using componentContext, dsContext.enableComponent("1A"); but it seems to work only with services in the same bundle. 回答1: Your using a mechanism that is intended for management and it seems you want to use it on application level. Declarative services should be enabled/disabled through their dependencies, or through a domain

Consume application/json in REST services using Jersey in Osgi

主宰稳场 提交于 2019-12-13 03:33:08
问题 I'm deploying some REST services in an Osgi bundle using Jersey. The services are notated like @POST @Path("/adduser") @Consumes(MediaType.APPLICATION_XML+","+MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_XML) public Message addUser(User user) { ... } The first problem I have is that the service doesn't accept both of the MIME types I put into the @Consumes notation but just the first one. The second and worst is that receive the following exeception when I try to call to the

is it possible to use OSGI with spring boot microservices? Please tell me in detail

北城余情 提交于 2019-12-13 03:15:00
问题 I want to use ODL framework for SDN development, in that internally OSGI framework is used to (karaf). Apart from that i want to use spring boot and spring cloud to achieve cloud services also. It is possible to use these all framework as a single unit. and how we can achieve this please tell. 回答1: This questions is somewhat overly broad and generic, but I'll try to answer it anyway making two assumptions: If you want to use Spring Boot / Cloud "in-process", that is within ODL/ Karaf, then

OSGi how to install two identical bundle?

只谈情不闲聊 提交于 2019-12-13 03:12:17
问题 I want to install two identical bundle or the same bundle twice in OSGi container. The OSGi container I am using is FUSE ESB. Here is the bundle information: pom.xml: <groupId>com.helloworldbundle</groupId> <artifactId>HelloWorldBundle</artifactId> <version>1.0.0-SNAPSHOT</version> blueprint: <?xml version="1.0" encoding="UTF-8"?> <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"> <bean id="helloworldbundlecopybean" class="com.helloworldbundle.HelloWorld" init-method="init"

How to generate a Karaf features descriptor

落花浮王杯 提交于 2019-12-13 02:47:20
问题 I am trying to automatically generate Apache Karaf's (2.3.0) feature desscriptor file ( features.xml ). From Karaf's doc I have learned that I can use the "features" packaging. my pom.xml <project> ... <packaging>feature</packaging> <dependencies> <dependency> <groupId>org.apache.jclouds</groupId> <artifactId>jclouds-core</artifactId> <scope>provided</scope> <version>${jclouds.version}</version> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.apache.karaf.tooling<

Is there a way to deploy exploded bundles in Apache Felix?

可紊 提交于 2019-12-13 02:38:32
问题 We are looking at rearchitecting our web application and want to move to a more modular solution, OSGi seems to meet a lot of our needs. I've come across the Apache Felix project and taken it for a spin. It looks solid yet I find the development cycle a bit slow as it requires a maven build of the bundle(s) to make any code changes effective. Instead I would like to be able to reload a bundle once classes have been compiled by Eclipse, without any extra building/packaging. Similar to how

Move a seam application to OSGI

对着背影说爱祢 提交于 2019-12-13 02:29:11
问题 i' ve some web applications developed using Seam Framework 2.3 + jBoss AS 7 + Hybernate. Since i' ve been studying OSGI for a while, i was wondering if is possible to move my applications to the osgi world for modularizing everything; i' ve read a lot of blogs and these interesting discussions as well (how-to-modularize-an-enterprise-application-with-osgi-and-ee6 and how-to-modularize-a-jsf-facelets-spring-application-with-osgi) but honestly i still don't really know where i should start from