[
https://issues.jboss.org/browse/AS7-2434?page=com.atlassian.jira.plugin.s...
]
Thomas Diesler edited comment on AS7-2434 at 2/6/12 6:38 AM:
-------------------------------------------------------------
To reproduce copy copy
[
pax-web-service|https://issues.jboss.org/secure/attachment/12348289/pax-w...]
into
${jboss.home}/bundles/org/ops4j/pax/web/main
and use this config
{code}
<subsystem xmlns="urn:jboss:domain:osgi:1.2"
activation="eager">
<properties>
<property
name="org.osgi.framework.startlevel.beginning">2</property>
</properties>
<capabilities>
<capability name="javax.servlet.api"/>
<capability name="org.apache.felix.log"
startlevel="1"/>
<capability name="org.ops4j.pax.web"
startlevel="2"/>
</capabilities>
</subsystem>
{code}
Note, the servlet API comes from modules and is version 3.0
The LogService has a dependency on osgi.enterprise, which optionally imports javax.servlet
- it resolves against v3.0. Later pax.web has a dependency on HttpService and imports
javax.servlet [2.0,3.0)
{code}
Caused by: org.jboss.osgi.resolver.XResolverException: Constraint violation for package
'javax.servlet' when resolving module Module[org.ops4j.pax.web.service:0.5.1]
between existing import Module[org.ops4j.pax.web.service:0.5.1].javax.servlet BLAMED ON
[[Module[org.ops4j.pax.web.service:0.5.1]] package;
(&(package=javax.servlet)(version>=2.3.0)(!(version>=2.6.0)))] and uses
constraint Module[javax.servlet.api:0.0.0].javax.servlet BLAMED ON
[[Module[org.ops4j.pax.web.service:0.5.1]] package;
(&(package=org.osgi.service.http)(version>=1.0.0)(!(version>=2.0.0))),
[Module[osgi.enterprise:4.2.0.201003190513]] package; (package=javax.servlet)]
at org.jboss.osgi.resolver.felix.FelixResolver.resolveInternal(FelixResolver.java:117)
[jbosgi-resolver-felix-1.0.10.jar:1.0.10]
at org.jboss.osgi.resolver.spi.AbstractResolver.resolve(AbstractResolver.java:148)
[jbosgi-resolver-spi-1.0.10.jar:1.0.10]
at org.jboss.osgi.framework.internal.ResolverPlugin.resolve(ResolverPlugin.java:155)
[jbosgi-framework-core-1.1.1.jar:1.1.1]
... 10 more
{code}
was (Author: thomas.diesler):
To reproduce copy copy pax-web-service into
${jboss.home}/bundles/org/ops4j/pax/web/main
and use this config
{code}
<subsystem xmlns="urn:jboss:domain:osgi:1.2"
activation="eager">
<properties>
<property
name="org.osgi.framework.startlevel.beginning">2</property>
</properties>
<capabilities>
<capability name="javax.servlet.api"/>
<capability name="org.apache.felix.log"
startlevel="1"/>
<capability name="org.ops4j.pax.web"
startlevel="2"/>
</capabilities>
</subsystem>
{code}
Note, the servlet API comes from modules and is version 3.0
The LogService has a dependency on osgi.enterprise, which optionally imports javax.servlet
- it resolves against v3.0. Later pax.web has a dependency on HttpService and imports
javax.servlet [2.0,3.0)
{code}
Caused by: org.jboss.osgi.resolver.XResolverException: Constraint violation for package
'javax.servlet' when resolving module Module[org.ops4j.pax.web.service:0.5.1]
between existing import Module[org.ops4j.pax.web.service:0.5.1].javax.servlet BLAMED ON
[[Module[org.ops4j.pax.web.service:0.5.1]] package;
(&(package=javax.servlet)(version>=2.3.0)(!(version>=2.6.0)))] and uses
constraint Module[javax.servlet.api:0.0.0].javax.servlet BLAMED ON
[[Module[org.ops4j.pax.web.service:0.5.1]] package;
(&(package=org.osgi.service.http)(version>=1.0.0)(!(version>=2.0.0))),
[Module[osgi.enterprise:4.2.0.201003190513]] package; (package=javax.servlet)]
at org.jboss.osgi.resolver.felix.FelixResolver.resolveInternal(FelixResolver.java:117)
[jbosgi-resolver-felix-1.0.10.jar:1.0.10]
at org.jboss.osgi.resolver.spi.AbstractResolver.resolve(AbstractResolver.java:148)
[jbosgi-resolver-spi-1.0.10.jar:1.0.10]
at org.jboss.osgi.framework.internal.ResolverPlugin.resolve(ResolverPlugin.java:155)
[jbosgi-framework-core-1.1.1.jar:1.1.1]
... 10 more
{code}
Incremental bundle resolution approach may lead to unresolvable user
bundles
----------------------------------------------------------------------------
Key: AS7-2434
URL:
https://issues.jboss.org/browse/AS7-2434
Project: Application Server 7
Issue Type: Bug
Components: OSGi
Reporter: Thomas Diesler
Assignee: Thomas Diesler
Fix For: 7.1.1.Final
When starting up the framework we resolve bundles in stages:
#1 auto install bundles
#2 deployed bundles
within the set of auto install bundles we incrementally run through the start levels
within a start level we iterate over the bundles in the order in which they are defined.
A possible fix would be to first compute the set of bundles that are included (and below)
the startlevel that we ramp up to. The resolver would be asked to resolve the complete
set.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira