[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] ConfigurationAdmin - changing the location of a PID

Please open a bug against Equinox->Compendium at https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Equinox about this.

Also can you try get/creating the configuration with the initial location of A (i.e. by calling ConfigurationAdmin.getConfiguration(String pid, String location)). When you open the bug report please let us know if that method also fails for you. Thanks.


Inactive hide details for Don Laidlaw ---08/31/2009 01:53:34 PM---Hi,Don Laidlaw ---08/31/2009 01:53:34 PM---Hi,


Don Laidlaw <Don.Laidlaw@xxxxxxxxx>


Equinox development mailing list <equinox-dev@xxxxxxxxxxx>


08/31/2009 01:53 PM


[equinox-dev] ConfigurationAdmin - changing the location of a PID


I am using ConfigurationAdmin, and programmatically setting the location of a PID that I am creating. That all works OK, and the getLocation() method returns the correct location for the PID. I change the location of the pid to the location of a bundle that has a ManagedService with the service.pid set to the PID in question.

That is:
Bundle A, registers a ManagedService with service.pid=my.pid
Bundle B, creates PID my.pid and sets the Configuration location to the location of Bundle A.

The problem is that the ManagedService never has its updated(Dictionary) method called. Stepping through the code reveals that this is because the ConfigurationImpl class has in internal private variable named boundBundle which is still set to the bundle that created the PID, and the Configuration location is ignored in deciding whether to call ManagedService.updated(Configuration) methods.

Is this as designed? I hope not :) I would have expected that if I created the PID and set its location to that of another bundle, then the ManagedService class in the other bundle would immediately start to have its updated(Configuration) method called whenever the PID was changed.

Best Regards,

Don Laidlaw | Sr. Research Engineer |
Infor | office: +1 902-576-5185 | mobile: +1 902-401-6771 | don.laidlaw@xxxxxxxxx
equinox-dev mailing list

GIF image

GIF image