aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alasdair Nottingham <...@apache.org>
Subject Re: blueprint.api exports org.osgi.service.blueprint yet blueprint.core can't resolve
Date Fri, 03 Jun 2011 14:20:49 GMT
Hi, you are right that the package contains no code. It is a synthetic
package the blueprint spec requires containers to export and blueprint
bundles are encouraged to import. The maven-bundle-plugin adds this
import for blueprint bundles automatically.

I have always been a little conflicted by this package because I think
the intent of the spec was that the package should be exported by the
container implementation, in this case blueprint-core. However if we
move the export from the api bundle to the impl bundle you wouldn't be
able to update the container bundle without refreshing all the
blueprint bundles at the same time, which seems like a pretty large
change to a system.

On 3 June 2011 14:46, Jeremy Hughes <hughesj@apache.org> wrote:
> On 2 June 2011 19:15, Alasdair Nottingham <not@apache.org> wrote:
>> The API bundle exports org.osgi.service.blueprint at version 0.0.0 it should probably
be 1.0.0.
>
> There are no classes in org.osgi.service.blueprint so it shouldn't be
> exported at all.
>
>>
>> Alasdair Nottingham
>>
>> On 2 Jun 2011, at 19:08, Jacek Laskowski <jacek@japila.pl> wrote:
>>
>>> Hi,
>>>
>>> Is there something wrong with the blueprint api bundle? I don't seem
>>> to run api and core, but the bundle module works fine.
>>>
>>> osgi> bundle 2
>>> org.apache.aries.blueprint.api_0.3.2.SNAPSHOT [2]
>>>  Id=2, Status=ACTIVE      Data
>>> Root=/Users/jacek/equinox-aries.configuration/org.eclipse.osgi/bundles/2/data
>>>  No registered services.
>>>  No services in use.
>>>  Exported packages
>>>    org.osgi.service.blueprint; version="0.0.0"[exported]
>>>    org.osgi.service.blueprint.reflect; version="1.0.1"[exported]
>>>    org.osgi.service.blueprint.container; version="1.0.1"[exported]
>>>  Imported packages
>>>    org.osgi.framework; version="1.6.0"<org.eclipse.osgi_3.7.0.v20110524
[0]>
>>>  No fragment bundles
>>>  Named class space
>>>    org.apache.aries.blueprint.api; bundle-version="0.3.2.SNAPSHOT"[provided]
>>>  No required bundles
>>>
>>> osgi> diag 3
>>> mvn:org.apache.aries.blueprint/org.apache.aries.blueprint.core/0.3.2-SNAPSHOT
>>> [3]
>>>  Direct constraints which are unresolved:
>>>    Missing optionally imported package
>>> org.apache.aries.blueprint.annotation.service_[0.3.0,1.0.0).
>>>    Missing optionally imported package
>>> org.apache.aries.quiesce.manager_[0.2.0,1.0.0).
>>>    Missing optionally imported package
>>> org.apache.aries.quiesce.participant_[0.2.0,1.0.0).
>>>    Missing imported package org.osgi.service.blueprint_[1.0.0,2.0.0).
>>>
>>> osgi> start 3
>>> org.osgi.framework.BundleException: The bundle
>>> "org.apache.aries.blueprint.core_0.3.2.SNAPSHOT [3]" could not be
>>> resolved. Reason: Missing Constraint: Import-Package:
>>> org.osgi.service.blueprint; version="[1.0.0,2.0.0)"
>>>    at org.eclipse.osgi.framework.internal.core.AbstractBundle.getResolverError(AbstractBundle.java:1327)
>>>    at org.eclipse.osgi.framework.internal.core.AbstractBundle.getResolutionFailureException(AbstractBundle.java:1311)
>>>    at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:323)
>>>    at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:299)
>>>    at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:291)
>>>    at org.eclipse.osgi.framework.internal.core.FrameworkCommandProvider._start(FrameworkCommandProvider.java:333)
>>>    at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
>>>    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>    at java.lang.reflect.Method.invoke(Method.java:597)
>>>    at org.eclipse.osgi.framework.internal.core.FrameworkCommandInterpreter.execute(FrameworkCommandInterpreter.java:209)
>>>    at org.eclipse.osgi.framework.internal.core.FrameworkConsole.docommand(FrameworkConsole.java:155)
>>>    at org.eclipse.osgi.framework.internal.core.FrameworkConsole.runConsole(FrameworkConsole.java:140)
>>>    at org.eclipse.osgi.framework.internal.core.FrameworkConsole.run(FrameworkConsole.java:104)
>>>    at java.lang.Thread.run(Thread.java:680)
>>>
>>> osgi> install mvn:org.apache.aries.blueprint/org.apache.aries.blueprint/0.3.2-SNAPSHOT
>>> Bundle id is 12
>>>
>>> osgi> ss
>>>
>>> Framework is launched.
>>>
>>> id    State       Bundle
>>> 0    ACTIVE      org.eclipse.osgi_3.7.0.v20110524
>>> 1    ACTIVE      org.ops4j.pax.url.mvn_1.3.2
>>> 4    ACTIVE      org.apache.aries.proxy.api_0.4.0.SNAPSHOT
>>> 5    ACTIVE      org.apache.aries.proxy.impl_0.4.0.SNAPSHOT
>>> 6    ACTIVE      org.apache.aries.util_0.4.0.SNAPSHOT
>>> 7    ACTIVE      org.eclipse.equinox.cm_1.0.300.v20110502
>>> 8    ACTIVE      org.ops4j.pax.logging.pax-logging-api_1.6.2
>>> 9    ACTIVE      org.ops4j.pax.logging.pax-logging-service_1.6.2
>>> 10    ACTIVE      org.eclipse.osgi.services_3.3.0.v20110513
>>> 11    ACTIVE      org.apache.aries.blueprint.sample_0.3.2.SNAPSHOT
>>> 12    ACTIVE      org.apache.aries.blueprint_0.3.2.SNAPSHOT
>>>
>>> Jacek
>>>
>>> --
>>> Jacek Laskowski
>>> Java EE, functional languages and IBM WebSphere - http://blog.japila.pl
>>> Warszawa JUG conference = Confitura (formerly Javarsovia) :: http://confitura.pl
>>
>



-- 
Alasdair Nottingham
not@apache.org

Mime
View raw message