> Is there a way to get a list of configurations for a single factory > PID if the properties have not been set for the configuration?
Not that I am aware of. > If > not, is there a reason why you cannot do so? Because there is no real different between the lack of a Configuration for a PID and a Configuration for a PID that has no properties. Neither will be delivered to the ManagedService and neither are visible in listConfiguration. In fact, a ConfigurationAdmin implementation does not even really need to persists a Configuration with no properties. > > ConfigurationAdmin.listConfigurations will return an array of > Configuration objects but only those objects which have non-null > properties. Therefore, if you use > ConfigurationAdmin.createFactoryConfiguration to create > configurations, you have to make sure you keep track of the returned > configurations or at least the PID. This works okay if there is a > single consumer of the API, but not if you have multiple consumers > of the API. For instance, if you have one consumer that creates the > configuration and another that wants to actually set the properties > of the configuration, the latter consumer has no way of knowing > about the already created configurations. There is no need for this division, since creating an empty configuration is essentially a no-op. > > This is in regards to 4.3 version of the spec, but if anything is > changing in a newer version I would like to know as well. -- BJ Hargrave Senior Technical Staff Member, IBM OSGi Fellow and CTO of the OSGi Alliance [email protected] office: +1 386 848 1781 mobile: +1 386 848 3788
_______________________________________________ OSGi Developer Mail List [email protected] https://mail.osgi.org/mailman/listinfo/osgi-dev
