Return-Path: Delivered-To: apmail-aries-user-archive@www.apache.org Received: (qmail 86586 invoked from network); 20 Feb 2011 07:36:38 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 20 Feb 2011 07:36:38 -0000 Received: (qmail 69289 invoked by uid 500); 20 Feb 2011 07:36:38 -0000 Delivered-To: apmail-aries-user-archive@aries.apache.org Received: (qmail 69141 invoked by uid 500); 20 Feb 2011 07:36:36 -0000 Mailing-List: contact user-help@aries.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@aries.apache.org Delivered-To: mailing list user@aries.apache.org Received: (qmail 69133 invoked by uid 99); 20 Feb 2011 07:36:35 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 20 Feb 2011 07:36:35 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: 74.125.82.48 is neither permitted nor denied by domain of kctang@big2.net) Received: from [74.125.82.48] (HELO mail-ww0-f48.google.com) (74.125.82.48) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 20 Feb 2011 07:36:27 +0000 Received: by wwd20 with SMTP id 20so5012993wwd.17 for ; Sat, 19 Feb 2011 23:36:06 -0800 (PST) MIME-Version: 1.0 Received: by 10.216.170.149 with SMTP id p21mr108941wel.81.1298187365002; Sat, 19 Feb 2011 23:36:05 -0800 (PST) Received: by 10.216.68.5 with HTTP; Sat, 19 Feb 2011 23:36:04 -0800 (PST) Date: Sun, 20 Feb 2011 15:36:04 +0800 Message-ID: Subject: blueprint works with 0.2-incubating, but not 0.3 From: KcTang To: user@aries.apache.org Content-Type: multipart/alternative; boundary=0016363ba184be2cf0049cb1cc57 X-Virus-Checked: Checked by ClamAV on apache.org --0016363ba184be2cf0049cb1cc57 Content-Type: text/plain; charset=ISO-8859-1 Hi! I'm trying to provide blueprint services in my embedded felix container. To do this, i've developed a very simple echo service bundle that has a /OSGI-INF/blueprint/config.xml that looks like: --- The embedded osgi container in my application has these bundles (before installing aries blueprint): g! lb START LEVEL 2 ID|State |Level|Name 0|Active | 0|System Bundle (3.0.8) 1|Active | 1|OPS4J Pax Logging - API (1.6.0) 2|Active | 1|OPS4J Pax Logging - Service (1.6.0) 3|Active | 1|OPS4J Pax Url - mvn: (1.2.5) 4|Active | 1|osgi.cmpn (4.2.0.200908310645) 5|Active | 2|Apache Felix Gogo Command (0.8.0) 6|Active | 2|Apache Felix Gogo Runtime (0.8.0) 7|Active | 2|Apache Felix Gogo Shell (0.8.0) 8|Active | 2|Apache Felix Bundle Repository (1.6.4) --- With 0.2-incubating, I am able to get my echo service bundle to run properly if i install these blueprint bundles first: install mvn:org.apache.aries.blueprint/org.apache.aries.blueprint/0.2-incubating install mvn:org.apache.aries/org.apache.aries.util/0.2-incubating # start blueprint's bundle id, then: install mvn:play.echo/echo-service1/1.0-SNAPSHOT # start my bundle id Observation: echo-service1 bundle is "Active". the EchoService1.start() method actually gets called when echo-service1's bundle is started. I also noticed that this is the version that Apache Karaf 2.1.3 is using (and my echo-service1 bundle works well there too). --- However, if i install my bundle after installing 0.3 bundles like this: install mvn:org.apache.aries.blueprint/org.apache.aries.blueprint/0.3 install mvn:org.apache.aries/org.apache.aries.util/0.3 install mvn:org.apache.aries.proxy/org.apache.aries.proxy.api/0.3 # start blueprint's bundle id, then: install mvn:play.echo/echo-service1/1.0-SNAPSHOT # start my bundle id Observation: echo-service1 bundle is "Active". However, both EchoService1's constructor and EchoService1.start() method is not called at all. --- Very much appreciated if someone can let me know what is wrong here and provide a solution to this. --0016363ba184be2cf0049cb1cc57 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi!

I'm trying to provide blueprint services in my embedded feli= x container.

To do this, i've developed a very simple echo servi= ce bundle that has a /OSGI-INF/blueprint/config.xml that looks like:

<?xml version=3D"1.0" encoding=3D"UTF-8"?><blueprint xmlns=3D"http://www.osgi.org/xmlns/blueprint/v1.0.0" >
=A0= =A0=A0 <bean id=3D"es1" class=3D"play.echo.service1.EchoS= ervice1" init-method=3D"start" >
=A0=A0=A0 </bean>
=A0=A0=A0 <service ref=3D"es1" inte= rface=3D"play.echo.service1.EchoService1Interface"=A0 />
&l= t;/blueprint>

---
The embedded osgi container in my applicatio= n has these bundles (before installing aries blueprint):

g! lb
START LEVEL 2
=A0=A0 ID|State=A0=A0=A0=A0=A0 |Level|Name=A0=A0=A0 0|Active=A0=A0=A0=A0 |=A0=A0=A0 0|System Bundle (3.0.8)
=A0= =A0=A0 1|Active=A0=A0=A0=A0 |=A0=A0=A0 1|OPS4J Pax Logging - API (1.6.0)=A0=A0=A0 2|Active=A0=A0=A0=A0 |=A0=A0=A0 1|OPS4J Pax Logging - Service (1= .6.0)
=A0=A0=A0 3|Active=A0=A0=A0=A0 |=A0=A0=A0 1|OPS4J Pax Url - mvn: (1.2.5)=A0=A0=A0 4|Active=A0=A0=A0=A0 |=A0=A0=A0 1|osgi.cmpn (4.2.0.200908310645)=
=A0=A0=A0 5|Active=A0=A0=A0=A0 |=A0=A0=A0 2|Apache Felix Gogo Command (= 0.8.0)
=A0=A0=A0 6|Active=A0=A0=A0=A0 |=A0=A0=A0 2|Apache Felix Gogo Run= time (0.8.0)
=A0=A0=A0 7|Active=A0=A0=A0=A0 |=A0=A0=A0 2|Apache Felix Gogo Shell (0.8.0)=
=A0=A0=A0 8|Active=A0=A0=A0=A0 |=A0=A0=A0 2|Apache Felix Bundle Reposit= ory (1.6.4)

---

With 0.2-incubating, I am able to get my echo= service bundle to run properly if i install these blueprint bundles first:=

install mvn:org.apache.aries.blueprint/org.apache.aries.blueprint/0.2-i= ncubating
install mvn:org.apache.aries/org.apache.aries.util/0.2-incubat= ing
# start blueprint's bundle id, then:
install mvn:play.echo/ec= ho-service1/1.0-SNAPSHOT
# start my bundle id

Observation: echo-service1 bundle is "Acti= ve". the EchoService1.start() method actually gets called when echo-se= rvice1's bundle is started.

I also noticed that this is the vers= ion that Apache Karaf 2.1.3 is using (and my echo-service1 bundle works wel= l there too).

---
However, if i install my bundle after installing 0.3 bundles lik= e this:

install mvn:org.apache.aries.blueprint/org.apache.aries.blue= print/0.3
install mvn:org.apache.aries/org.apache.aries.util/0.3
install mvn:org.apache.aries.proxy/org.apache.aries.proxy.api/0.3
# star= t blueprint's bundle id, then:
install mvn:play.echo/echo-service1/1= .0-SNAPSHOT
# start my bundle id

Observation: echo-service1 bundl= e is "Active". However, both EchoService1's constructor and E= choService1.start() method is not called at all.

---

Very much appreciated if someone can let me know what is wro= ng here and provide a solution to this.


--0016363ba184be2cf0049cb1cc57--