[equinox-dev] Issue with Felix SCR and Dependency manager Annotations jars with Eclipse Equinox R4_19
Hi All, I am working on an OSGI project where I am upgrading jetty and OSGI versions from R-4.9 to R4_19_maintenance and Jetty version is getting upgraded from 9.4.11 to 9.4.44 I was using org.eclipse.equinox.ds(1.4.400) as a bundle earlier which was using org.apache.felix internally. Since org.eclipse.equinox.ds dependency has been removed from R4_19_maintenance, I have added dependency of org.apache.felix.scr(2.1.24) but the issue is org.apache.felix.scr.annotation services are not getting activated. *(Activate* *method is not being called)* Also, the same is happening with org.apache.felix.scr.dependencymanager.annotations (3.2.0) and the services are not getting started *(Start method is not being called)* Can you please help me in knowing if it is the version of org.apache.felix.scr.annotation that is causing the issue, if yes, which version it supports or what could be the possible issues that might be causing this. I appreciate your quick response and thanks in advance. Thanks, - Kuldeep Singh Budania ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev
Re: [equinox-dev] Issue with Felix SCR and Dependency manager Annotations jars with Eclipse Equinox R4_19
On Thu, Dec 9, 2021 at 12:02 PM Kuldeep Singh Budania < kuldeep.sing...@gmail.com> wrote: > Hi All, > > I am working on an OSGI project where I am upgrading jetty and OSGI > versions from R-4.9 to R4_19_maintenance and Jetty version is getting > upgraded from 9.4.11 to 9.4.44 > > I was using org.eclipse.equinox.ds(1.4.400) as a bundle earlier which was > using org.apache.felix internally. > Since org.eclipse.equinox.ds dependency has been removed from > R4_19_maintenance, > I have added dependency of org.apache.felix.scr(2.1.24) but the issue is > org.apache.felix.scr.annotation services are not getting activated. > *(Activate* *method is not being called)* > Also, the same is happening with > org.apache.felix.scr.dependencymanager.annotations (3.2.0) and the services > are not getting started *(Start method is not being called)* > > Can you please help me in knowing if it is the version of > org.apache.felix.scr.annotation that is causing the issue, if yes, which > version it supports or what could be the possible issues that might be > causing this. > I appreciate your quick response and thanks in advance. > See https://git.eclipse.org/c/equinox/rt.equinox.p2.git/commit/?id=09d81ece3fae68ac93ddb730854e54c97cbb8646 . Make sure that you have org.apache.felix.scr auto started like in this commit. > > Thanks, > - > Kuldeep Singh Budania > > ___ > equinox-dev mailing list > equinox-dev@eclipse.org > To unsubscribe from this list, visit > https://www.eclipse.org/mailman/listinfo/equinox-dev > -- Aleksandar Kurtakov Red Hat Eclipse Team ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev
Re: [equinox-dev] Issue with Felix SCR and Dependency manager Annotations jars with Eclipse Equinox R4_19
Hi, Thanks for the quick response, but my configuration is correct as per commit and it is auto start = true, Please find the below screenshot and I am completely stuck at this point. [image: image.png] So requesting you guys please help me on this issue. Thanks, - Kuldeep Singh Budania On Thu, Dec 9, 2021 at 3:45 PM Aleksandar Kurtakov wrote: > > > On Thu, Dec 9, 2021 at 12:02 PM Kuldeep Singh Budania < > kuldeep.sing...@gmail.com> wrote: > >> Hi All, >> >> I am working on an OSGI project where I am upgrading jetty and OSGI >> versions from R-4.9 to R4_19_maintenance and Jetty version is getting >> upgraded from 9.4.11 to 9.4.44 >> >> I was using org.eclipse.equinox.ds(1.4.400) as a bundle earlier which was >> using org.apache.felix internally. >> Since org.eclipse.equinox.ds dependency has been removed from >> R4_19_maintenance, >> I have added dependency of org.apache.felix.scr(2.1.24) but the issue is >> org.apache.felix.scr.annotation services are not getting activated. >> *(Activate* *method is not being called)* >> Also, the same is happening with >> org.apache.felix.scr.dependencymanager.annotations (3.2.0) and the services >> are not getting started *(Start method is not being called)* >> >> Can you please help me in knowing if it is the version of >> org.apache.felix.scr.annotation that is causing the issue, if yes, which >> version it supports or what could be the possible issues that might be >> causing this. >> I appreciate your quick response and thanks in advance. >> > > See > https://git.eclipse.org/c/equinox/rt.equinox.p2.git/commit/?id=09d81ece3fae68ac93ddb730854e54c97cbb8646 > . Make sure that you have org.apache.felix.scr auto started like in this > commit. > > >> >> Thanks, >> - >> Kuldeep Singh Budania >> >> ___ >> equinox-dev mailing list >> equinox-dev@eclipse.org >> To unsubscribe from this list, visit >> https://www.eclipse.org/mailman/listinfo/equinox-dev >> > > > -- > Aleksandar Kurtakov > Red Hat Eclipse Team > ___ > equinox-dev mailing list > equinox-dev@eclipse.org > To unsubscribe from this list, visit > https://www.eclipse.org/mailman/listinfo/equinox-dev > ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev
Re: [equinox-dev] Issue with Felix SCR and Dependency manager Annotations jars with Eclipse Equinox R4_19
Hi, It seems that you are mixing a few incompatible things here. The setup of org.apache.felix.src seems to be correct, even if I don't know why it needs to be set to autostart, as it would do so by itself. In you initial Message you state that org.apache.felix.scr.dependencymanager.annotations and org.apache.felix.scr.annotation is not started. Both bundles are unnecessary. Here is the reason why: org.apache.felix.scr.annotation at least in the version of 1.12 from central is no Bundle and seems to be used by the maven plugin that would parse you annotations. The org.apache.felix.scr.dependencymanager is a precursor to Declarative Services and should not be used together with it. The annotation Bundle in addition might only contain the annotations of the old dependencymanager and should not be part of you setup. Only use the annotation from the org.osgi.service.component.annotations bundle. This bundle should not be part of you final runtime, as all the Annotations will only be used by you tooling. If you use the PDE you need to activate the DS Annotation parsing in you preferences. It only supports Component annotations up to version 1.3. If you use bnd or the bnd-maven-plugin you can use the latest version. You tooling will parse the annotations and create component XML files in your OSGI-INF directory and reference them via the Service-Component Header in you Manifest. I hope this helps, Jürgen. Am 09/12/2021 um 11:32 schrieb Kuldeep Singh Budania: Hi, Thanks for the quick response, but my configuration is correct as per commit and it is auto start = true, Please find the below screenshot and I am completely stuck at this point. image.png So requesting you guys please help me on this issue. Thanks, - Kuldeep Singh Budania On Thu, Dec 9, 2021 at 3:45 PM Aleksandar Kurtakov wrote: On Thu, Dec 9, 2021 at 12:02 PM Kuldeep Singh Budania wrote: Hi All, I am working on an OSGI project where I am upgrading jetty and OSGI versions from R-4.9 to R4_19_maintenance and Jetty version is getting upgraded from 9.4.11 to 9.4.44 I was using org.eclipse.equinox.ds(1.4.400) as a bundle earlier which was using org.apache.felix internally. Since org.eclipse.equinox.ds dependency has been removed from R4_19_maintenance, I have added dependency of org.apache.felix.scr(2.1.24) but the issue is org.apache.felix.scr.annotation services are not getting activated. *(Activate* *method is not being called)* Also, the same is happening with org.apache.felix.scr.dependencymanager.annotations (3.2.0) and the services are not getting started *(Start method is not being called)* Can you please help me in knowing if it is the version of org.apache.felix.scr.annotation that is causing the issue, if yes, which version it supports or what could be the possible issues that might be causing this. I appreciate your quick response and thanks in advance. See https://git.eclipse.org/c/equinox/rt.equinox.p2.git/commit/?id=09d81ece3fae68ac93ddb730854e54c97cbb8646 . Make sure that you have org.apache.felix.scr auto started like in this commit. Thanks, - Kuldeep Singh Budania ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev -- Aleksandar Kurtakov Red Hat Eclipse Team ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visithttps://www.eclipse.org/mailman/listinfo/equinox-dev -- Jürgen Albert CEO Chair Eclipse OSGi Working Group Steering Committee Data In Motion Consulting GmbH Kahlaische Str. 4 07745 Jena Mobil: +49 157-72521634 E-Mail:j.alb...@datainmotion.de Web:www.datainmotion.de XING:https://www.xing.com/profile/Juergen_Albert5 LinkedIn:https://www.linkedin.com/in/juergen-albert-6a1796/ Rechtliches Jena HBR 513025 ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev
Re: [equinox-dev] Issue with Felix SCR and Dependency manager Annotations jars with Eclipse Equinox R4_19
Hi, you should try to annotate you SCR Components using the OSGi annotations: - org.osgi.service.component.annotations.Component - org.osgi.service.component.annotations.Activate - org.osgi.service.component.annotations.Deactivate and so on. But remember that these annotations are build time annotations, So you need tools like bndtools or the PDE (PDE only support DS until 1.3) that generate the metadata (componenten - xml files) for these annotations. Felic SCR is the implementation for OSGi Declarative Services: It is the implementation for OSGi Declarative Services: https://docs.osgi.org/specification/osgi.cmpn/7.0.0/service.component.html https://developer.ibm.com/articles/osgi-demystified-part-5-using-declarative-services/ I hope this helps. Regards, Mark Am 09.12.21 um 11:01 schrieb Kuldeep Singh Budania: Hi All, I am working on an OSGI project where I am upgrading jetty and OSGI versions from R-4.9 to R4_19_maintenance and Jetty version is getting upgraded from 9.4.11 to 9.4.44 I was using org.eclipse.equinox.ds(1.4.400) as a bundle earlier which was using org.apache.felix internally. Since org.eclipse.equinox.ds dependency has been removed from R4_19_maintenance, I have added dependency of org.apache.felix.scr(2.1.24) but the issue is org.apache.felix.scr.annotation services are not getting activated. *(Activate* *method is not being called)* Also, the same is happening with org.apache.felix.scr.dependencymanager.annotations (3.2.0) and the services are not getting started *(Start method is not being called)* Can you please help me in knowing if it is the version of org.apache.felix.scr.annotation that is causing the issue, if yes, which version it supports or what could be the possible issues that might be causing this. I appreciate your quick response and thanks in advance. Thanks, - Kuldeep Singh Budania ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev -- Mark Hoffmann M.A. Dipl.-Betriebswirt (FH) Geschäftsführer Tel:+49 3641 384 910 0 Mobil: +49 175 701 2201 E-Mail: m.hoffm...@data-in-motion.biz Web: www.datainmotion.de Data In Motion Consulting GmbH Kahlaische Straße 4 07745 Jena Geschäftsführer Mark Hoffmann Jürgen Albert Jena HRB 513025 Steuernummer 162/107/05779 USt-Id DE310002614 ___ equinox-dev mailing list equinox-dev@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev