Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
iPOJO-1.0.0
-
None
Description
iPOJO Temporal dependency is able to inject arrays for aggregate dependencies, However aggregate dependencies can also be Collections, so temporal dependencies should support Collection.
As for "regular" dependencies, using Collection forces to specify the service specification in the configuration such as :
<component classname="org.apache.felix.ipojo.test.scenarios.component.CollectionCheckServiceProvider" name="TEMPORAL-EmptyColCheckServiceProviderTimeout">
<temp:requires field="fs" timeout="300" onTimeout="empty" specification="org.apache.felix.ipojo.test.scenarios.temporal.service.FooService"/>
<provides/>
</component>
The onTimeout policies for Collection should be as following:
- null : null
- nullable : a collection with one element (the nullable object)
- default-implementation : a collection with one element (the default-implementation object)
- runtime exception (timeout with no policy): an exception is thrown when the collection is injected
- empty-array: should become 'empty' and injects an empty collection