Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
None
-
None
-
OSGi CT for DS: testReferenceTargetProperty
Description
Test setup has three components:
(1) E registered as BS and TC without service properties
(2) T1 disabled by default; to be registered as TC with property p=x
(3) T2 enabled by default with ref to TC and target (p=x)
Component T2 has the target defined as part of the component definition properties as in:
<reference name="ref" ... />
<property name="ref.target" value="(p=x)" />
This is expected to not activate T2 because the reference cannot be satisfied until T1 is enabled and registered as a TC service with the property.
Currently T2 is activated because the ref.target property is ignored and thus the component is registered without a target property and thus happily binds to component E.
The AbstractComponentManager.verifyDependencyManagers method has a commented call to update the target filters. Probably because the callers of this method do the update themselves before verifying. Except the Unsatisfied.activate method, which only verifies without setting the targets.