The ordering is the same regardless of whether the reference is static or dynamic.
I have clarified the text in for this in the DS 1.4 spec.

BJ Hargrave
Senior Technical Staff Member, IBM // office: +1 386 848 1781
OSGi Fellow and CTO of the OSGi Alliance // mobile: +1 386 848 3788
----- Original message -----
From: Konrad Windszus <>
Sent by:
Subject: [osgi-dev] Order of injected services into a Collection/List field
Date: Fri, Mar 3, 2017 2:42 AM
DS 1.3 added field injection and now supports Collections/Lists. Unfortunately it is only specified (in OSGi R6 Comp, ยง112.3.8.1) how those are ordered in case of dynamic references. What about having a static reference with multiple cardinality?
I fail to see the according spec about the ordering of these.
Is this an oversight on my side, or is this just missing from the spec?
Can I assume that those are ordered as well according to ServiceReference.compareTo(...)?
OSGi Developer Mail List

OSGi Developer Mail List

Reply via email to