Thanks everyone for so much Feedback!
@Tim: There has been an exception in my init method

Am 18.02.2017 09:51 schrieb "Carsten Ziegeler" <cziege...@apache.org>:

> David Jencks wrote
> > In addition, to get full information out of felix ds, you need to set
> the framework or config admin property ds.loglevel to “debug” or 4.  While
> little else of http://felix.apache.org/documentation/subprojects/
> apache-felix-service-component-runtime.html appears remotely up to date,
> the “Configuration” section explains this accurately.
> >
> And once we've implemented the upcoming R7 implementation you will see
> this state reflected in the DTOs together with the output of the exception.
>
> Carsten
>
> > thanks
> > david jencks
> >
> >> On Feb 17, 2017, at 3:07 PM, Neil Bartlett <njbartl...@gmail.com>
> wrote:
> >>
> >> Normally it’s enough to have a Log Service bundle installed, such as
> org.apache.felix.log. Then you can view messages with the “log” command in
> the Gogo shell.
> >>
> >>
> >>> On 17 Feb 2017, at 22:54, Thomas Driessen <thomas.dries...@ds-lab.org>
> wrote:
> >>>
> >>> It has indeed been an Exception in the initializer.
> >>> Thank you so much!
> >>>
> >>> Can you point me to some resources on how to setup the logging for DS,
> so that in the future I might see such Exceptions?
> >>>
> >>> Kind regards,
> >>> Thomas
> >>>
> >>> ------ Originalnachricht ------
> >>> Von: "David Jencks" <david.a.jen...@gmail.com>
> >>> An: users@felix.apache.org
> >>> Gesendet: 17.02.2017 22:42:18
> >>> Betreff: Re: [osgi-dev] Components are not started,although marked
> with immediate=true
> >>>
> >>>> One way this could happen is if the activate methods on the
> testThread components threw exceptions.  You might try making the
> activate/deactivate methods empty to check.  If you’ve set up logging for
> DS (including the  framework or config property ds.loglevel=debug) the logs
> will show in excruciating detail what is happening.
> >>>>
> >>>> hope this helps, if it’s not exceptions please supply debug logs and
> i will take a look.
> >>>>
> >>>> david jencks
> >>>>
> >>>>> On Feb 17, 2017, at 12:36 PM, Thomas Driessen <
> thomas.driessen...@gmail.com> wrote:
> >>>>>
> >>>>> After asking in the osgi-dev list in was adviced to try ist at the
> Felix
> >>>>> Mailinglist.
> >>>>>
> >>>>> Dies anyone know why Services that are marked as immediate are not
> started
> >>>>> although marked as satisfied by felix-scr? ( See E-Mails below dir
> the Code)
> >>>>>
> >>>>> Kind regards,
> >>>>> Thomas
> >>>>> ---------- Weitergeleitete Nachricht ----------
> >>>>> Von: "BJ Hargrave" <hargr...@us.ibm.com>
> >>>>> Datum: 17.02.2017 21:09
> >>>>> Betreff: Re: [osgi-dev] Components are not started,although marked
> with
> >>>>> immediate=true
> >>>>> An: <thomas.driessen...@gmail.com>, <osgi-...@mail.osgi.org>
> >>>>> Cc:
> >>>>>
> >>>>> Seems like they should all be active. You may need to check with the
> >>>>>> felix-dev list about Felix SCR's handling of this.
> >>>>>> --
> >>>>>>
> >>>>>> BJ Hargrave
> >>>>>> Senior Technical Staff Member, IBM // office: +1 386 848 1781
> >>>>>> <(386)%20848-1781>
> >>>>>> OSGi Fellow and CTO of the OSGi Alliance // mobile: +1 386 848 3788
> >>>>>> <(386)%20848-3788>
> >>>>>> hargr...@us.ibm.com
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>> ----- Original message -----
> >>>>>> From: "Thomas Driessen" <thomas.driessen...@gmail.com>
> >>>>>> Sent by: osgi-dev-boun...@mail.osgi.org
> >>>>>> To: osgi-...@mail.osgi.org
> >>>>>> Cc:
> >>>>>> Subject: [osgi-dev] Components are not started, although marked with
> >>>>>> immediate=true
> >>>>>> Date: Fri, Feb 17, 2017 2:46 PM
> >>>>>>
> >>>>>> Hi,
> >>>>>>
> >>>>>> I have a problem with immediate services and hoped that you guys
> maybe can
> >>>>>> help.
> >>>>>>
> >>>>>> I'm currently trying to implement several services within one
> bundle (see
> >>>>>> below for code).
> >>>>>> I have set all of them to be immediate (by immediate=true), but
> still,
> >>>>>> when I start the OSGi container with my bundle in it, only Con1,
> >>>>>> InDataPort1 and OutDataPort1 are active. The rest is satisfied but
> not
> >>>>>> active according to felix.scr console output:
> >>>>>>
> >>>>>> g! list
> >>>>>> BundleId Component Name Default State
> >>>>>>  Component Id State      PIDs (Factory PID)
> >>>>>> [  10]   test.Con1  enabled
> >>>>>>  [   0] [active      ]
> >>>>>> [  10]   test.InDataPort1  enabled
> >>>>>>  [   1] [active      ]
> >>>>>> [  10]   test.OutDataPort1  enabled
> >>>>>>  [   2] [active      ]
> >>>>>> [  10]   test.Process1  enabled
> >>>>>>  [   3] [satisfied   ]
> >>>>>> [  10]   test.Thread1_1  enabled
> >>>>>>  [   4] [satisfied   ]
> >>>>>> [  10]   test.Thread1_2  enabled
> >>>>>>  [   5] [satisfied   ]
> >>>>>>
> >>>>>> Am I doing something wrong?
> >>>>>> I assumed that all services should be started as soon as they are
> >>>>>> satisfied.
> >>>>>>
> >>>>>> Any advice is highly appreciated.
> >>>>>>
> >>>>>> Kind regards,
> >>>>>> Thomas
> >>>>>>
> >>>>>>
> >>>>>> @Component(immediate = true, service = IProcess.class, property =
> >>>>>> "de.uniaugsburg.smds.aadl2osgi.component.uid=test.Process1")
> >>>>>> public class Process1 implements IProcess {
> >>>>>>
> >>>>>> @Reference(target = "(uid=test.Thread1_1)")
> >>>>>> private volatile IPeriodicThread thread1;
> >>>>>>
> >>>>>> @Reference(target = "(uid=test.Thread1_2)")
> >>>>>> private volatile IPeriodicThread thread2;
> >>>>>> }
> >>>>>>
> >>>>>>
> >>>>>> @Component(service = IPeriodicThread.class, property =
> >>>>>> "de.uniaugsburg.smds.aadl2osgi.component.uid=test.Thread1_1",
> immediate =
> >>>>>> true)
> >>>>>> public class Thread1_1 implements IPeriodicThread {
> >>>>>>
> >>>>>> @Reference(target = "(uid=test.OutDataPort1)")
> >>>>>> private volatile IOutDataPort outport;
> >>>>>>
> >>>>>> @Activate
> >>>>>> public void initialize_FW() {
> >>>>>>  init();
> >>>>>> }
> >>>>>>
> >>>>>> @Deactivate
> >>>>>> public void finalize_FW() {
> >>>>>>  deinit();
> >>>>>> }
> >>>>>> }
> >>>>>>
> >>>>>>
> >>>>>> @Component(service = IPeriodicThread.class, property =
> >>>>>> "de.uniaugsburg.smds.aadl2osgi.component.uid=test.Thread1_2",
> immediate =
> >>>>>> true)
> >>>>>> public class Thread1_2 implements IPeriodicThread {
> >>>>>>
> >>>>>> @Reference(target = "(uid=test.InDataPort1)")
> >>>>>> private volatile IOutDataPort outport;
> >>>>>>
> >>>>>> @Activate
> >>>>>> public void initialize_FW() {
> >>>>>>  init();
> >>>>>> }
> >>>>>>
> >>>>>> @Deactivate
> >>>>>> public void finalize_FW() {
> >>>>>>  deinit();
> >>>>>> }
> >>>>>> }
> >>>>>>
> >>>>>>
> >>>>>> @Component(service = IOutDataPort.class, property =
> >>>>>> "uid=test.OutDataPort1", immediate = true)
> >>>>>> public class OutDataPort1 implements IOutDataPort {
> >>>>>>
> >>>>>> @Reference(target = "(target=test.OutDataPort1)", cardinality =
> >>>>>> ReferenceCardinality.OPTIONAL, policyOption =
> ReferencePolicyOption.GREEDY)
> >>>>>> private volatile IPortConnection incomingPortConnections;
> >>>>>>
> >>>>>> private volatile Set outgoingPortConnections = new
> >>>>>> ConcurrentSkipListSet();
> >>>>>>
> >>>>>> @Reference(target = "(source=test.OutDataPort1)", cardinality =
> >>>>>> ReferenceCardinality.OPTIONAL, policyOption =
> ReferencePolicyOption.GREEDY)
> >>>>>> public void addOutgoingPortConnection(final IPortConnection con) {
> >>>>>>  outgoingPortConnections.add(con);
> >>>>>> }
> >>>>>>
> >>>>>> public void removeOutgoingPortConnection(final IPortConnection
> con) {
> >>>>>>  outgoingPortConnections.remove(con);
> >>>>>> }
> >>>>>> }
> >>>>>>
> >>>>>>
> >>>>>> @Component(service = IInDataPort.class, property =
> "uid=test.InDataPort1",
> >>>>>> immediate = true)
> >>>>>> @SuppressWarnings("all")
> >>>>>> public class InDataPort1 implements IInDataPort {
> >>>>>>
> >>>>>> @Reference(target = "(target=test.InDataPort1)", cardinality =
> >>>>>> ReferenceCardinality.OPTIONAL, policyOption =
> ReferencePolicyOption.GREEDY)
> >>>>>> private volatile IPortConnection incomingPortConnections;
> >>>>>>
> >>>>>> private volatile Set outgoingPortConnections = new
> >>>>>> ConcurrentSkipListSet();
> >>>>>>
> >>>>>> @Reference(target = "(source=test.InDataPort1)", cardinality =
> >>>>>> ReferenceCardinality.OPTIONAL, policyOption =
> ReferencePolicyOption.GREEDY)
> >>>>>> public void addOutgoingPortConnection(final IPortConnection con) {
> >>>>>>  outgoingPortConnections.add(con);
> >>>>>> }
> >>>>>>
> >>>>>> public void removeOutgoingPortConnection(final IPortConnection
> con) {
> >>>>>>  outgoingPortConnections.remove(con);
> >>>>>> }
> >>>>>> }
> >>>>>>
> >>>>>>
> >>>>>> @Component(service = IPortConnection.class, property = {
> >>>>>> "source=test.OutDataPort1", "target=test.InDataPort1" }, immediate
> = true)
> >>>>>> public class Con1 implements IPortConnection {
> >>>>>> @Reference(cardinality = ReferenceCardinality.OPTIONAL,
> policyOption =
> >>>>>> ReferencePolicyOption.GREEDY, target = "(uid=test.OutDataPort1)")
> >>>>>> private volatile IOutDataPort source;
> >>>>>>
> >>>>>> @Reference(cardinality = ReferenceCardinality.OPTIONAL,
> policyOption =
> >>>>>> ReferencePolicyOption.GREEDY, target = "(uid=test.InDataPort1)")
> >>>>>> private volatile IInDataPort target;
> >>>>>> }
> >>>>>> _______________________________________________
> >>>>>> OSGi Developer Mail List
> >>>>>> osgi-...@mail.osgi.org
> >>>>>> https://mail.osgi.org/mailman/listinfo/osgi-dev
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>
> >>>>
> >>>> ---------------------------------------------------------------------
> >>>> To unsubscribe, e-mail: users-unsubscr...@felix.apache.org
> >>>> For additional commands, e-mail: users-h...@felix.apache.org
> >>>>
> >>>
> >>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail: users-unsubscr...@felix.apache.org
> >>> For additional commands, e-mail: users-h...@felix.apache.org
> >>>
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscr...@felix.apache.org
> >> For additional commands, e-mail: users-h...@felix.apache.org
> >>
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscr...@felix.apache.org
> > For additional commands, e-mail: users-h...@felix.apache.org
> >
> >
>
>
>
>
> --
> Carsten Ziegeler
> Adobe Research Switzerland
> cziege...@apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@felix.apache.org
> For additional commands, e-mail: users-h...@felix.apache.org
>
>

Reply via email to