blob: 2a408c8be29feb3c5bddd7da20b36b764a4eb5e0 [file] [log] [blame]
David Jencksa9cbe1b2012-06-15 21:37:30 +00001<?xml version="1.0" encoding="UTF-8"?>
2<!--
3 Licensed to the Apache Software Foundation (ASF) under one
4 or more contributor license agreements. See the NOTICE file
5 distributed with this work for additional information
6 regarding copyright ownership. The ASF licenses this file
7 to you under the Apache License, Version 2.0 (the
8 "License"); you may not use this file except in compliance
9 with the License. You may obtain a copy of the License at
10
11 http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing,
14 software distributed under the License is distributed on an
15 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 KIND, either express or implied. See the License for the
17 specific language governing permissions and limitations
18 under the License.
19-->
20<components xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0">
21
22 <!-- A, B both 1.1 dynamic. Neither should register or activate -->
23 <scr:component name="1.A.1.1.dynamic"
24 enabled="true"
25 configuration-policy="ignore">
26 <implementation class="org.apache.felix.scr.integration.components.circular.A" />
27 <service>
28 <provide interface="org.apache.felix.scr.integration.components.circular.A" />
29 </service>
30 <reference
31 name="b"
32 interface="org.apache.felix.scr.integration.components.circular.B"
33 cardinality="1..1"
34 policy="dynamic"
35 bind="setB"
36 unbind="unsetB"
37 target="(service.pid=1.B.1.1.dynamic)"
38 />
39 <property name="service.pid" value="1.A.1.1.dynamic" />
40 </scr:component>
41 <scr:component name="1.B.1.1.dynamic"
42 enabled="true"
43 configuration-policy="ignore">
44 <implementation class="org.apache.felix.scr.integration.components.circular.B" />
45 <service>
46 <provide interface="org.apache.felix.scr.integration.components.circular.B" />
47 </service>
48 <reference
49 name="a"
50 interface="org.apache.felix.scr.integration.components.circular.A"
51 cardinality="1..1"
52 policy="dynamic"
53 bind="setA"
54 unbind="unsetA"
55 target="(service.pid=1.A.1.1.dynamic)"
56 />
57 <property name="service.pid" value="1.B.1.1.dynamic" />
58 </scr:component>
59
60 <!-- A 1.1 dynamic. B 0..n dynamic both immediate. Both should start (A first) and B should have no reference to A -->
61 <scr:component name="2.A.1.1.dynamic"
62 enabled="true"
63 immediate="true"
64 configuration-policy="ignore">
65 <implementation class="org.apache.felix.scr.integration.components.circular.A" />
66 <service>
67 <provide interface="org.apache.felix.scr.integration.components.circular.A" />
68 </service>
69 <reference
70 name="b"
71 interface="org.apache.felix.scr.integration.components.circular.B"
72 cardinality="1..1"
73 policy="dynamic"
74 bind="setB"
75 unbind="unsetB"
76 target="(service.pid=2.B.0.n.dynamic)"
77 />
78 <property name="service.pid" value="2.A.1.1.dynamic" />
79 </scr:component>
80 <scr:component name="2.B.0.n.dynamic"
81 enabled="true"
82 immediate="true"
83 configuration-policy="ignore">
84 <implementation class="org.apache.felix.scr.integration.components.circular.B" />
85 <service>
86 <provide interface="org.apache.felix.scr.integration.components.circular.B" />
87 </service>
88 <reference
89 name="a"
90 interface="org.apache.felix.scr.integration.components.circular.A"
91 cardinality="0..n"
92 policy="dynamic"
93 bind="setA"
94 unbind="unsetA"
95 target="(service.pid=2.A.1.1.dynamic)"
96 />
97 <property name="service.pid" value="2.B.0.n.dynamic" />
98 </scr:component>
99
100 <!-- A 1.1 dynamic. B 0..n dynamic both immediate. Both should start (B first) and B should have a reference to A -->
101 <scr:component name="3.B.0.n.dynamic"
102 enabled="true"
103 immediate="true"
104 configuration-policy="ignore">
105 <implementation class="org.apache.felix.scr.integration.components.circular.B" />
106 <service>
107 <provide interface="org.apache.felix.scr.integration.components.circular.B" />
108 </service>
109 <reference
110 name="a"
111 interface="org.apache.felix.scr.integration.components.circular.A"
112 cardinality="0..n"
113 policy="dynamic"
114 bind="setA"
115 unbind="unsetA"
116 target="(service.pid=3.A.1.1.dynamic)"
117 />
118 <property name="service.pid" value="3.B.0.n.dynamic" />
119 </scr:component>
120 <scr:component name="3.A.1.1.dynamic"
121 enabled="true"
122 immediate="true"
123 configuration-policy="ignore">
124 <implementation class="org.apache.felix.scr.integration.components.circular.A" />
125 <service>
126 <provide interface="org.apache.felix.scr.integration.components.circular.A" />
127 </service>
128 <reference
129 name="b"
130 interface="org.apache.felix.scr.integration.components.circular.B"
131 cardinality="1..1"
132 policy="dynamic"
133 bind="setB"
134 unbind="unsetB"
135 target="(service.pid=3.B.0.n.dynamic)"
136 />
137 <property name="service.pid" value="3.A.1.1.dynamic" />
138 </scr:component>
139
140 <!-- A 1.1 dynamic. B 0..n dynamic both delayed. Both should start and B should have no reference to A -->
141 <scr:component name="4.A.1.1.dynamic"
142 enabled="true"
143 immediate="false"
144 configuration-policy="ignore">
145 <implementation class="org.apache.felix.scr.integration.components.circular.A" />
146 <service>
147 <provide interface="org.apache.felix.scr.integration.components.circular.A" />
148 </service>
149 <reference
150 name="b"
151 interface="org.apache.felix.scr.integration.components.circular.B"
152 cardinality="1..1"
153 policy="dynamic"
154 bind="setB"
155 unbind="unsetB"
156 target="(service.pid=4.B.0.n.dynamic)"
157 />
158 <property name="service.pid" value="4.A.1.1.dynamic" />
159 </scr:component>
160 <scr:component name="4.B.0.n.dynamic"
161 enabled="true"
162 immediate="false"
163 configuration-policy="ignore">
164 <implementation class="org.apache.felix.scr.integration.components.circular.B" />
165 <service>
166 <provide interface="org.apache.felix.scr.integration.components.circular.B" />
167 </service>
168 <reference
169 name="a"
170 interface="org.apache.felix.scr.integration.components.circular.A"
171 cardinality="0..n"
172 policy="dynamic"
173 bind="setA"
174 unbind="unsetA"
175 target="(service.pid=4.A.1.1.dynamic)"
176 />
177 <property name="service.pid" value="4.B.0.n.dynamic" />
178 </scr:component>
179
180
181</components>