>From our experience, the complexity of multiple providers often arises
by accident when tools like BND are used to merge lots of packages
into single bundles. This can be a good feature in that it minimises
the dependencies for the user to start a given bundle, but it the
downside is it leads to very complex problems for the resolver to
solve.

We've also found a lot of complex uses graphs in the bundles hosted in
the spring repository as often you will find multiple bundles export
javax.servlet.http (for example) - not sure if this is by accident or
a requirement of the particular bundles.

>From the point of view of resolution algorithms, I've put special
logic into the sigil resolver to "prefer" bundles that have the fewest
imports even if two bundles claim to export the same package - this
often short cuts a lot of unnecessary graph walking where there are
more than one possible provider of a given package.

A spectacular example of this is the
"com.springsource.org.aspectj.tools" bundle:

http://www.springsource.com/repository/app/bundle/version/detail?name=com.springsource.org.aspectj.tools&version=1.5.4&searchType=bundlesBySymbolicName&searchQuery=org.aspectj.tools

that exports "org.osgi.framework". Before I put in this logic I would
often find the sigil resolver trying to download an 8.4MB bundle to
satisfy a resolution that the framework already provides (which would
also cascade into lots of other dependencies to satisy aspectj) :s

Anyway, my 2 cents...

Regards,

Dave

On Wed, Jun 10, 2009 at 4:25 PM, Richard S. Hall<[email protected]> wrote:
> On 6/10/09 11:07 AM, Guillaume Nodet wrote:
>>
>> Just for my undersanding, if you don't have any package exported in
>> multiple versions, how can the search space become huge ?  I would
>> have thought that either the bundle can match the requirement or can
>> not, there's not much of choice here.  Any idea ?
>>
>
> I agree with you. If you don't have multiple candidates exporting the same
> package, then you shouldn't run into this issue because the single candidate
> with either succeed or fail in one go.
>
> -> richard
>
>> On Wed, Jun 10, 2009 at 16:32, Richard S. Hall<[email protected]>
>>  wrote:
>>
>>>
>>> On 6/10/09 6:24 AM, Stuart McCulloch wrote:
>>>
>>>>
>>>> 2009/6/10 Aaron Zeckoski<[email protected]>
>>>>
>>>>
>>>>
>>>>>
>>>>> I checked the services that are started as well since I have not seen
>>>>> any change in about 30 minutes now. It looks like no new bundles or
>>>>> services have started since the initial framework startup.
>>>>>
>>>>>
>>>>
>>>> if you take thread-dumps ( using Ctrl-Brk on Windows, Ctrl-\ on Linux,
>>>> or
>>>> by
>>>> using jstack<pid>    ) then you should see the start level thread in the
>>>> framework going through methods in the resolver
>>>>
>>>>
>>>>
>>>>
>>>>>
>>>>> Is this going to be something that happens slowly or will it be more
>>>>> like
>>>>> a
>>>>> dam bursting? (see the bottom of the message for the output)
>>>>>
>>>>>
>>>>>
>>>>
>>>> probably more like a dam, as it's trying to find a complete solution
>>>> that
>>>> works for the current set of bundles
>>>>
>>>>
>>>>
>>>>
>>>>>
>>>>> Apologies for the total ignorance of this code but can you point me to
>>>>> where the code that does this calculation is located in felix?
>>>>>
>>>>>
>>>>
>>>> well, if you look through the thread dump you should see a thread stack
>>>> with
>>>> lots of methods from the following class
>>>>
>>>>
>>>>
>>>>
>>>> framework/src/main/java/org/apache/felix/framework/searchpolicy/Resolver.java
>>>>
>>>> specifically look for "calculateUsesConstraints"
>>>>
>>>> It seems odd that anything like this should be taking so long to finish.
>>>>
>>>>
>>>>>
>>>>> I might put in some breakpoints and see what is happening in a little
>>>>> more detail. Over 30 minutes on a machine that is only running firefox
>>>>> as the other application with the CPU constantly around 100% is an
>>>>> awful lot of computing.
>>>>>
>>>>>
>>>>>
>>>>
>>>> as I mentioned before this is suspected to be an NP-complete problem, so
>>>> depending on how many bundles and packages are involved it could involve
>>>> a
>>>> large search space... Felix also uses a custom resolver rather than a
>>>> SAT-based one like in Equinox, so this makes it harder to put an upper
>>>> bound
>>>> on the search time
>>>>
>>>>
>>>
>>> To my knowledge, Equinox does not use a SAT-based resolver...that is used
>>> by
>>> p2. Further, p2 does not yet support "uses" constraints. As far as I
>>> know,
>>> Equinox has two strategies for dealing with "uses" constraints: a timeout
>>> (as you mentioned) and just turning them off completely. Neither is a
>>> great
>>> option, but understandable.
>>>
>>> ->  richard
>>>
>>>
>>>
>>>>
>>>>
>>>>>
>>>>> Aside from the helpful analysis in
>>>>> https://issues.apache.org/jira/browse/FELIX-961
>>>>> is there any more reading material that might help me here?
>>>>>
>>>>>
>>>>>
>>>>
>>>> try searching the mail archives for the Felix dev list, as Richard did
>>>> discusss getting someone to rewrite the resolver
>>>>
>>>>
>>>>
>>>>
>>>>>
>>>>> Thanks for all the pointers so far!
>>>>> -AZ
>>>>>
>>>>>
>>>>> ->    version
>>>>> 1.8.0
>>>>> ->    services
>>>>>
>>>>> System Bundle (0) provides:
>>>>> ---------------------------
>>>>> org.osgi.service.startlevel.StartLevel
>>>>> org.osgi.service.packageadmin.PackageAdmin
>>>>>
>>>>> OPS4J Pax Logging - Service (36) provides:
>>>>> ------------------------------------------
>>>>> org.osgi.service.log.LogReaderService
>>>>> org.osgi.service.log.LogService,
>>>>> org.knopflerfish.service.log.LogService,
>>>>> org.ops4j.pax.logging.PaxLoggingService,
>>>>> org.osgi.service.cm.ManagedService
>>>>>
>>>>> spring-osgi-extender (53) provides:
>>>>> -----------------------------------
>>>>> org.springframework.beans.factory.xml.NamespaceHandlerResolver
>>>>> org.xml.sax.EntityResolver
>>>>>
>>>>> Apache Felix Shell Service (95) provides:
>>>>> -----------------------------------------
>>>>> org.apache.felix.shell.ShellService,
>>>>> org.ungoverned.osgi.service.shell.ShellService
>>>>>
>>>>> OPS4J Pax Web - Service (100) provides:
>>>>> ---------------------------------------
>>>>> org.osgi.service.cm.ManagedService
>>>>> org.osgi.service.http.HttpService,
>>>>> org.ops4j.pax.web.service.WebContainer
>>>>> ->    ps -u
>>>>> START LEVEL 6
>>>>>   ID   State         Level  Update location
>>>>> [   0] [Starting   ] [    0] System Bundle
>>>>> [   1] [Installed  ] [    5]
>>>>> file:bundles/org.apache.sling.jcr.api_2.0.3.incubator-SNAPSHOT.jar
>>>>> [   2] [Installed  ] [    5]
>>>>>
>>>>>
>>>>>
>>>>> file:bundles/org.apache.sling.jcr.jackrabbit.api_2.0.3.incubator-SNAPSHOT.jar
>>>>> [   3] [Installed  ] [    5]
>>>>> file:bundles/com.springsource.org.apache.commons.lang_2.4.0.jar
>>>>> [   4] [Installed  ] [    5]
>>>>> file:bundles/com.springsource.org.apache.commons.codec_1.3.0.jar
>>>>> [   5] [Installed  ] [    5]
>>>>> file:bundles/com.springsource.org.apache.commons.beanutils_1.8.0.jar
>>>>> [   6] [Installed  ] [    5]
>>>>> file:bundles/org.apache.jackrabbit.jackrabbit-jcr-commons_1.5.0.jar
>>>>> [   7] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.commons.collections_3.2.1.jar
>>>>> [   8] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.felix.scr_1.0.8.jar
>>>>> [   9] [Installed  ] [    5]
>>>>> file:bundles/org.apache.felix.bundlerepository_1.0.3.jar
>>>>> [  10] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.felix.eventadmin_1.0.0.jar
>>>>> [  11] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.felix.fileinstall_1.0.0.jar
>>>>> [  12] [Installed  ] [    5]
>>>>> file:bundles/org.apache.felix.configadmin_1.0.10.jar
>>>>> [  13] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.felix.metatype_1.0.0.jar
>>>>> [  14] [Installed  ] [    5]
>>>>> file:bundles/org.apache.felix.webconsole_1.2.10.jar
>>>>> [  15] [Installed  ] [    5]
>>>>> file:bundles/org.mortbay.jetty.server_6.1.14.jar
>>>>> [  16] [Installed  ] [    5]
>>>>> file:bundles/org.mortbay.jetty.util_6.1.14.jar
>>>>> [  17] [Resolved   ] [    5]
>>>>> file:bundles/org.mortbay.jetty.servlet-api-2.5_2.5.jar
>>>>> [  18] [Installed  ] [    5]
>>>>> file:bundles/org.apache.cxf.bundle-minimal_2.2.1.jar
>>>>> [  19] [Installed  ] [    5]
>>>>> file:bundles/org.apache.cxf.cxf-bundle-jaxrs_2.2.jar
>>>>> [  20] [Installed  ] [    5]
>>>>> file:bundles/cxf-dosgi-ri-discovery-local_1.1.0.SNAPSHOT.jar
>>>>> [  21] [Installed  ] [    5]
>>>>> file:bundles/cxf-dosgi-ri-dsw-cxf_1.1.0.SNAPSHOT.jar
>>>>> [  22] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.cxf.transport.osgi_4.0.0.jar
>>>>> [  23] [Resolved   ] [    5]
>>>>> file:bundles/org.springframework.core_2.5.6.A.jar
>>>>> [  24] [Resolved   ] [    5]
>>>>> file:bundles/org.springframework.beans_2.5.6.A.jar
>>>>> [  25] [Resolved   ] [    5]
>>>>> file:bundles/org.springframework.context_2.5.6.A.jar
>>>>> [  26] [Active     ] [    1]
>>>>>
>>>>>
>>>>>
>>>>> file:bundles/org.apache.geronimo.specs.geronimo-ws-metadata_2.0_spec_1.1.2.jar
>>>>> [  27] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.specs.jaxb-api-2.1_1.3.0.jar
>>>>> [  28] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.specs.jaxp-api-1.4_1.3.0.jar
>>>>> [  29] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.specs.jaxws-api-2.1_1.3.0.jar
>>>>> [  30] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.servicemix.specs.javamail-api-1.4_1.3.0.jar
>>>>> [  31] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.specs.saaj-api-1.3_1.3.0.jar
>>>>> [  32] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.specs.stax-api-1.0_1.3.0.jar
>>>>> [  33] [Resolved   ] [    5]
>>>>> file:bundles/org.ops4j.pax.web.service_0.5.2.jar
>>>>> [  34] [Installed  ] [    5]
>>>>> file:bundles/org.ops4j.pax.web.extender.whiteboard_0.5.1.jar
>>>>> [  35] [Active     ] [    1]
>>>>> file:bundles/org.ops4j.pax.logging.pax-logging-api_1.3.0.jar
>>>>> [  36] [Active     ] [    1]
>>>>> file:bundles/org.ops4j.pax.logging.pax-logging-service_1.3.0.jar
>>>>> [  37] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.asm_2.2.3.1.jar
>>>>> [  38] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.jaxb-impl_2.1.6.1.jar
>>>>> [  39] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.wsdl4j_1.6.1.1.jar
>>>>> [  40] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.bundles.jettison_1.0.1.1.jar
>>>>> [  41] [Installed  ] [    5]
>>>>> file:bundles/org.apache.servicemix.bundles.xmlschema_1.4.3.1.jar
>>>>> [  42] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.xmlsec_1.3.0.1.jar
>>>>> [  43] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.xmlresolver_1.2.0.1.jar
>>>>> [  44] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.neethi_2.0.4.1.jar
>>>>> [  45] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.wss4j_1.5.4.1.jar
>>>>> [  46] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.woodstox_3.2.7.1.jar
>>>>> [  47] [Active     ] [    1]
>>>>> file:bundles/com.springsource.org.jdom_1.0.0.jar
>>>>> [  48] [Active     ] [    2]
>>>>> file:bundles/com.springsource.org.aopalliance_1.0.0.jar
>>>>> [  49] [Installed  ] [    5]
>>>>> file:bundles/com.springsource.org.apache.oro_2.0.8.jar
>>>>> [  50] [Resolved   ] [    5]
>>>>> file:bundles/org.springframework.aop_2.5.6.A.jar
>>>>> [  51] [Active     ] [    2]
>>>>> file:bundles/org.springframework.osgi.io_1.2.0.jar
>>>>> [  52] [Active     ] [    2]
>>>>> file:bundles/org.springframework.osgi.core_1.2.0.jar
>>>>> [  53] [Active     ] [    2]
>>>>> file:bundles/org.springframework.osgi.extender_1.2.0.jar
>>>>> [  54] [Installed  ] [    5]
>>>>> file:bundles/opencast-authentication-api_0.1.0.SNAPSHOT.jar
>>>>> [  55] [Installed  ] [    5]
>>>>> file:bundles/opencast-rest-services_0.1.0.SNAPSHOT.jar
>>>>> [  56] [Installed  ] [    5] file:bundles/org.apache.commons.io_1.4.jar
>>>>> [  57] [Installed  ] [    5]
>>>>> file:bundles/opencast-repository_0.1.0.SNAPSHOT.jar
>>>>> [  58] [Installed  ] [    5]
>>>>> file:bundles/org.apache.commons.fileupload_1.2.1.jar
>>>>> [  59] [Installed  ] [    5] file:bundles/slf4j.api_1.5.2.jar
>>>>> [  60] [Installed  ] [    5] file:bundles/slf4j.log4j12_1.5.2.jar
>>>>> [  61] [Installed  ] [    5] file:bundles/derby_10.4.2000000.689064.jar
>>>>> [  62] [Installed  ] [    5] file:bundles/org.osgi.service.obr_1.jar
>>>>> [  63] [Installed  ] [    5]
>>>>> file:bundles/opencast-util_0.1.0.SNAPSHOT.jar
>>>>> [  64] [Installed  ] [    5] file:bundles/slf4j.api_1.5.6.jar
>>>>> [  65] [Installed  ] [    5]
>>>>> file:bundles/opencast-media_0.1.0.SNAPSHOT.jar
>>>>> [  66] [Installed  ] [    5]
>>>>> file:bundles/org.apache.commons.lang_2.4.jar
>>>>> [  67] [Installed  ] [    5] file:bundles/joda-time_1.6.jar
>>>>> [  68] [Installed  ] [    5]
>>>>> file:bundles/opencast-authentication-cas_0.1.0.SNAPSHOT.jar
>>>>> [  69] [Installed  ] [    5]
>>>>> file:bundles/opencast-encoder-api_0.1.0.SNAPSHOT.jar
>>>>> [  70] [Installed  ] [    5]
>>>>> file:bundles/opencast-encoder-impl_0.1.0.SNAPSHOT.jar
>>>>> [  71] [Installed  ] [    5]
>>>>> file:bundles/opencast-workflow-api_0.1.0.SNAPSHOT.jar
>>>>> [  72] [Installed  ] [    5]
>>>>> file:bundles/opencast-workflow-impl_0.1.0.SNAPSHOT.jar
>>>>> [  73] [Installed  ] [    5]
>>>>> file:bundles/opencast-sample-service-api_0.1.0.SNAPSHOT.jar
>>>>> [  74] [Installed  ] [    5]
>>>>> file:bundles/opencast-sample-service-impl_0.1.0.SNAPSHOT.jar
>>>>> [  75] [Installed  ] [    5]
>>>>> file:bundles/opencast-remote-sample-service-client_0.1.0.SNAPSHOT.jar
>>>>> [  76] [Resolved   ] [    5]
>>>>> file:bundles/org.apache.felix.prefs_1.0.2.jar
>>>>> [  77] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.bundles.xmlschema_1.4.2.1.jar
>>>>> [  78] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.specs.saaj-api-1.3_1.1.1.jar
>>>>> [  79] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.specs.stax-api-1.0_1.1.1.jar
>>>>> [  80] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.specs.jaxb-api-2.1_1.1.1.jar
>>>>> [  81] [Installed  ] [    3]
>>>>> file:bundles/org.apache.servicemix.specs.jaxws-api-2.1_1.1.1.jar
>>>>> [  82] [Installed  ] [    3]
>>>>> file:bundles/cxf-dosgi-ri-discovery-local_1.0.jar
>>>>> [  83] [Installed  ] [    3] file:bundles/cxf-dosgi-ri-dsw-cxf_1.0.jar
>>>>> [  84] [Active     ] [    2]
>>>>> file:bundles/org.springframework.aop_2.5.6.jar
>>>>> [  85] [Active     ] [    2]
>>>>> file:bundles/org.springframework.beans_2.5.6.jar
>>>>> [  86] [Active     ] [    2]
>>>>> file:bundles/org.springframework.context_2.5.6.jar
>>>>> [  87] [Active     ] [    2]
>>>>> file:bundles/org.springframework.context.support_2.5.6.jar
>>>>> [  88] [Active     ] [    2]
>>>>> file:bundles/org.springframework.core_2.5.6.jar
>>>>> [  89] [Active     ] [    2]
>>>>> file:bundles/com.springsource.org.objectweb.asm_2.2.3.jar
>>>>> [  90] [Active     ] [    2]
>>>>> file:bundles/com.springsource.edu.emory.mathcs.backport_3.1.0.jar
>>>>> [  91] [Active     ] [    2]
>>>>> file:bundles/com.springsource.net.sf.cglib_2.1.3.jar
>>>>> [  92] [Active     ] [    2]
>>>>> file:bundles/org.springframework.osgi.extensions.annotations_1.2.0.jar
>>>>> [  93] [Installed  ] [    2]
>>>>> file:bundles/org.apache.cxf.bundle-minimal_2.2.2.jar
>>>>> [  94] [Active     ] [    1]
>>>>> file:bundles/osgi.compendium_4.1.0.build-200702212030.jar
>>>>> [  95] [Active     ] [    1]
>>>>> file:bundles/org.apache.felix.shell_1.2.0.jar
>>>>> [  96] [Active     ] [    1]
>>>>> file:bundles/org.apache.felix.shell.tui_1.2.0.jar
>>>>> [  97] [Active     ] [    1]
>>>>>
>>>>>
>>>>>
>>>>> file:bundles/org.apache.geronimo.specs.geronimo-annotation_1.0_spec_1.1.1.jar
>>>>> [  98] [Active     ] [    1]
>>>>>
>>>>>
>>>>>
>>>>> file:bundles/org.apache.geronimo.specs.geronimo-activation_1.1_spec_1.0.2.jar
>>>>> [  99] [Active     ] [    1]
>>>>>
>>>>> file:bundles/org.apache.geronimo.specs.geronimo-javamail_1.4_spec_1.2.jar
>>>>> [ 100] [Active     ] [    1]
>>>>> file:bundles/org.ops4j.pax.web.pax-web-service_0.6.0.jar
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Jun 10, 2009 at 11:03 AM, Stuart McCulloch<[email protected]>
>>>>> wrote:
>>>>>
>>>>>
>>>>>>
>>>>>> 2009/6/10 Aaron Zeckoski<[email protected]>
>>>>>>
>>>>>>
>>>>>>
>>>>>>>
>>>>>>> I let it sit there for 15 mins without a change previously and then
>>>>>>> shut it down. I restarted it and it is pushing my CPU to about 100%
>>>>>>> on
>>>>>>> a pretty modern macbook pro so I am letting it run now (about 10 mins
>>>>>>> so far). The issue you linked to does seem to describe what is
>>>>>>> happening. I guess I should eventually start seeing packages go from
>>>>>>> installed to running if I leave it long enough?
>>>>>>>
>>>>>>> So then, the solution here is either:
>>>>>>> 1) remove some packages (I can maybe remove a few here but most of
>>>>>>> these are in use)
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> changing the order that certain bundles are installed can sometimes
>>>>>> help,
>>>>>> but
>>>>>> this is of course a fragile workaround and definitely not a permanent
>>>>>> solution!
>>>>>>
>>>>>> 2) stop using felix and use equinox or other
>>>>>>       you might still see a delay with Equinox, but when the timeout
>>>>>> kicks in
>>>>>>
>>>>>>
>>>>>
>>>>> it
>>>>>
>>>>>
>>>>>>
>>>>>> will finish
>>>>>>
>>>>>> of course this means you could end up in a situation with inconsistent
>>>>>>
>>>>>>
>>>>>
>>>>> class
>>>>>
>>>>>
>>>>>>
>>>>>> spaces,
>>>>>> because the "uses" calculation was aborted before it could find a
>>>>>>
>>>>>>
>>>>>
>>>>> complete
>>>>>
>>>>>
>>>>>>
>>>>>> solution
>>>>>>
>>>>>> while in almost all cases this won't cause any problems, it does mean
>>>>>> you
>>>>>> might get
>>>>>> class cast exceptions due to inconsistent wiring which could have been
>>>>>> resolved if
>>>>>> the resolver had been given more time (but we don't know for sure
>>>>>> because
>>>>>>
>>>>>>
>>>>>
>>>>> of
>>>>>
>>>>>
>>>>>>
>>>>>> the
>>>>>> halting problem!)
>>>>>>
>>>>>> adding a timeout to Felix is another option, but I'll need to discuss
>>>>>>
>>>>>>
>>>>>
>>>>> this
>>>>>
>>>>>
>>>>>>
>>>>>> with Richard
>>>>>>
>>>>>> Does that sound about right?
>>>>>>
>>>>>>
>>>>>>>
>>>>>>> -AZ
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Jun 10, 2009 at 9:31 AM, Stuart McCulloch<[email protected]>
>>>>>>> wrote:
>>>>>>>
>>>>>>>
>>>>>>>>
>>>>>>>> 2009/6/10 Aaron Zeckoski<[email protected]>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>>
>>>>>>>>> I am getting a falure while starting up felix 1.8.0. Granted that I
>>>>>>>>> have a ton of bundles starting here so it is likely to be complex
>>>>>>>>> but
>>>>>>>>> I didn't think that a failure in a bundle would stop the system.
>>>>>>>>> The
>>>>>>>>> result is that the system bundle sits in the "starting" phase and
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> many
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> of the bundles stay at installed and nothing appears in the logs.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> I don't believe this is actually a hang, the system bundle is in
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> "starting"
>>>>>>>
>>>>>>>
>>>>>>>>
>>>>>>>> state
>>>>>>>> and if you take a series of thread dumps you'll probably find it's
>>>>>>>>
>>>>>>>>
>>>>>
>>>>> busy
>>>>>
>>>>>
>>>>>>>
>>>>>>> in
>>>>>>>
>>>>>>>
>>>>>>>>
>>>>>>>> the
>>>>>>>> resolver processing "uses" clauses (the CPU usage will also be
>>>>>>>> high):
>>>>>>>>
>>>>>>>>  https://issues.apache.org/jira/browse/FELIX-961
>>>>>>>>
>>>>>>>> if you give it time it should eventually complete, but this may take
>>>>>>>> a
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> while
>>>>>>>
>>>>>>>
>>>>>>>>
>>>>>>>> there's no real solution to the general case (it's suspected to be
>>>>>>>> NP-complete)
>>>>>>>> other than adding a time limit and abandoning the search when this
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> expires,
>>>>>>>
>>>>>>>
>>>>>>>>
>>>>>>>> which is what Equinox does
>>>>>>>>
>>>>>>>> so try leaving it running, and if it does finish let us know how
>>>>>>>> long
>>>>>>>>
>>>>>>>>
>>>>>
>>>>> it
>>>>>
>>>>>
>>>>>>>>
>>>>>>>> took :)
>>>>>>>>
>>>>>>>> Is there something that will give me a hint as to which bundle died
>>>>>>>> or
>>>>>>>>
>>>>>>>>
>>>>>>>>>
>>>>>>>>> caused the hang here?
>>>>>>>>> My guess is the Apache CXF Minimal Bundle Jar (2.2.3.SNAPSHOT)
>>>>>>>>> since
>>>>>>>>> it is the level 2 bundle that is not started but I am not sure how
>>>>>>>>> to
>>>>>>>>> confirm this suspicion.
>>>>>>>>> (some details below)
>>>>>>>>>
>>>>>>>>> Here is the result of a ps:
>>>>>>>>> START LEVEL 6
>>>>>>>>>   ID   State         Level  Name
>>>>>>>>> [   0] [Starting   ] [    0] System Bundle (1.8.0)
>>>>>>>>> [   1] [Installed  ] [    5] Apache Sling Repository API Bundle
>>>>>>>>> (2.0.3.incubator-SNAPSHOT)
>>>>>>>>> [   2] [Installed  ] [    5] Apache Sling Jackrabbit API Bundle
>>>>>>>>> (2.0.3.incubator-SNAPSHOT)
>>>>>>>>> [   3] [Installed  ] [    5] Apache Commons Lang (2.4.0)
>>>>>>>>> [   4] [Installed  ] [    5] Apache Commons Codec (1.3.0)
>>>>>>>>> [   5] [Installed  ] [    5] Apache Commons Bean Utilities (1.8.0)
>>>>>>>>> [   6] [Installed  ] [    5] Jackrabbit JCR Commons (1.5.0)
>>>>>>>>> [   7] [Resolved   ] [    5] Commons Collections (3.2.1)
>>>>>>>>> [   8] [Resolved   ] [    5] Apache Felix Declarative Services
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> (1.0.8)
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> [   9] [Installed  ] [    5] Apache Felix Bundle Repository (1.0.3)
>>>>>>>>> [  10] [Resolved   ] [    5] Apache Felix EventAdmin (1.0.0)
>>>>>>>>> [  11] [Resolved   ] [    5] Apache Felix File Install (1.0.0)
>>>>>>>>> [  12] [Installed  ] [    5] Apache Felix Configuration Admin
>>>>>>>>> Service
>>>>>>>>> (1.0.10)
>>>>>>>>> [  13] [Resolved   ] [    5] Apache Felix Metatype Service (1.0.0)
>>>>>>>>> [  14] [Installed  ] [    5] Apache Felix Web Management Console
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (1.2.10)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  15] [Installed  ] [    5] Jetty Server (6.1.14)
>>>>>>>>> [  16] [Installed  ] [    5] Jetty Utilities (6.1.14)
>>>>>>>>> [  17] [Resolved   ] [    5] Servlet Specification 2.5 API (2.5)
>>>>>>>>> [  18] [Installed  ] [    5] Apache CXF Minimal Bundle Jar (2.2.1)
>>>>>>>>> [  19] [Installed  ] [    5] Apache CXF JAX-RS Bundle Jar (2.2)
>>>>>>>>> [  20] [Installed  ] [    3] CXF Local Discovery Service Bundle
>>>>>>>>> (1.1.0.SNAPSHOT)
>>>>>>>>> [  21] [Installed  ] [    3] CXF Distributed Software Bundle
>>>>>>>>> (1.1.0.SNAPSHOT)
>>>>>>>>> [  22] [Installed  ] [    5] Apache ServiceMix CXF Transport for
>>>>>>>>> OSGi
>>>>>>>>> (4.0.0)
>>>>>>>>> [  23] [Resolved   ] [    5] Spring Core (2.5.6.A)
>>>>>>>>> [  24] [Resolved   ] [    5] Spring Beans (2.5.6.A)
>>>>>>>>> [  25] [Resolved   ] [    5] Spring Context (2.5.6.A)
>>>>>>>>> [  26] [Active     ] [    1] geronimo-ws-metadata_2.0_spec (1.1.2)
>>>>>>>>> [  27] [Installed  ] [    5] Apache ServiceMix Specs :: JAXB API
>>>>>>>>> 2.1
>>>>>>>>> (1.3.0)
>>>>>>>>> [  28] [Installed  ] [    5] Apache ServiceMix Specs :: JAXP API
>>>>>>>>> 1.4
>>>>>>>>> (1.3.0)
>>>>>>>>> [  29] [Installed  ] [    5] Apache ServiceMix Specs :: JAXWS API
>>>>>>>>> 2.1
>>>>>>>>> (1.3.0)
>>>>>>>>> [  30] [Resolved   ] [    5] Apache ServiceMix Specs :: JAVAMAIL
>>>>>>>>> API
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> 1.4
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> (1.3.0)
>>>>>>>>> [  31] [Installed  ] [    5] Apache ServiceMix Specs :: SAAJ API
>>>>>>>>> 1.3
>>>>>>>>> (1.3.0)
>>>>>>>>> [  32] [Installed  ] [    5] Apache ServiceMix Specs :: STAX API
>>>>>>>>> 1.0
>>>>>>>>> (1.3.0)
>>>>>>>>> [  33] [Resolved   ] [    5] OPS4J Pax Web - Service (0.5.2)
>>>>>>>>> [  34] [Installed  ] [    5] OPS4J Pax Web Extender - Whiteboard
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> (0.5.1)
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> [  35] [Active     ] [    1] OPS4J Pax Logging - API (1.3.0)
>>>>>>>>> [  36] [Active     ] [    1] OPS4J Pax Logging - Service (1.3.0)
>>>>>>>>> [  37] [Installed  ] [    3] Apache ServiceMix Bundles: asm-2.2.3
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (2.2.3.1)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  38] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>> jaxb-impl-2.1.6 (2.1.6.1)
>>>>>>>>> [  39] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>> wsdl4j-1.6.1
>>>>>>>>> (1.6.1.1)
>>>>>>>>> [  40] [Installed  ] [    5] Apache ServiceMix Bundles:
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> jettison-1.0.1
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> (1.0.1.1)
>>>>>>>>> [  41] [Installed  ] [    5] Apache ServiceMix Bundles:
>>>>>>>>> xmlschema-1.4.3 (1.4.3.1)
>>>>>>>>> [  42] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>> xmlsec-1.3.0
>>>>>>>>> (1.3.0.1)
>>>>>>>>> [  43] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>> xmlresolver-1.2 (1.2.0.1)
>>>>>>>>> [  44] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>> neethi-2.0.4
>>>>>>>>> (2.0.4.1)
>>>>>>>>> [  45] [Installed  ] [    3] Apache ServiceMix Bundles: wss4j-1.5.4
>>>>>>>>> (1.5.4.1)
>>>>>>>>> [  46] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> woodstox-3.2.7
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> (3.2.7.1)
>>>>>>>>> [  47] [Active     ] [    1] JDOM DOM Processor (1.0.0)
>>>>>>>>> [  48] [Active     ] [    2] AOP Alliance API (1.0.0)
>>>>>>>>> [  49] [Installed  ] [    5] Apache Oro Regular Expressions (2.0.8)
>>>>>>>>> [  50] [Resolved   ] [    5] Spring AOP (2.5.6.A)
>>>>>>>>> [  51] [Active     ] [    2] spring-osgi-io (1.2.0)
>>>>>>>>> [  52] [Active     ] [    2] spring-osgi-core (1.2.0)
>>>>>>>>> [  53] [Active     ] [    2] spring-osgi-extender (1.2.0)
>>>>>>>>> [  54] [Installed  ] [    5] opencast-authentication-api
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  55] [Installed  ] [    5] opencast-rest-services
>>>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>>> [  56] [Installed  ] [    5] Apache Commons IO Bundle (1.4)
>>>>>>>>> [  57] [Installed  ] [    5] opencast-repository (0.1.0.SNAPSHOT)
>>>>>>>>> [  58] [Installed  ] [    5] Apache Commons FileUpload Bundle
>>>>>>>>> (1.2.1)
>>>>>>>>> [  59] [Installed  ] [    5] slf4j-api (1.5.2)
>>>>>>>>> [  60] [Installed  ] [    5] slf4j-log4j12 (1.5.2)
>>>>>>>>> [  61] [Installed  ] [    5] Apache Derby 10.4
>>>>>>>>> (10.4.2000000.689064)
>>>>>>>>> [  62] [Installed  ] [    5] OSGi OBR Service API (1)
>>>>>>>>> [  63] [Installed  ] [    5] opencast-util (0.1.0.SNAPSHOT)
>>>>>>>>> [  64] [Installed  ] [    5] slf4j-api (1.5.6)
>>>>>>>>> [  65] [Installed  ] [    5] opencast-media (0.1.0.SNAPSHOT)
>>>>>>>>> [  66] [Installed  ] [    5] Commons Lang (2.4)
>>>>>>>>> [  67] [Installed  ] [    5] Joda-Time (1.6)
>>>>>>>>> [  68] [Installed  ] [    5] opencast-authentication-cas
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  69] [Installed  ] [    5] opencast-encoder-api (0.1.0.SNAPSHOT)
>>>>>>>>> [  70] [Installed  ] [    5] opencast-encoder-impl (0.1.0.SNAPSHOT)
>>>>>>>>> [  71] [Installed  ] [    5] opencast-workflow-api (0.1.0.SNAPSHOT)
>>>>>>>>> [  72] [Installed  ] [    5] opencast-workflow-impl
>>>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>>> [  73] [Installed  ] [    5] opencast-sample-service-api
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  74] [Installed  ] [    5] opencast-sample-service-impl
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  75] [Installed  ] [    5] opencast-remote-sample-service-client
>>>>>>>>> (0.1.0.SNAPSHOT)
>>>>>>>>> [  76] [Resolved   ] [    5] Apache Felix Prefrences Service
>>>>>>>>> (1.0.2)
>>>>>>>>> [  77] [Installed  ] [    3] Apache ServiceMix Bundles:
>>>>>>>>> xmlschema-1.4.2 (1.4.2.1)
>>>>>>>>> [  78] [Installed  ] [    3] Apache ServiceMix Specs :: SAAJ API
>>>>>>>>> 1.3
>>>>>>>>> (1.1.1)
>>>>>>>>> [  79] [Installed  ] [    3] Apache ServiceMix Specs :: STAX API
>>>>>>>>> 1.0
>>>>>>>>> (1.1.1)
>>>>>>>>> [  80] [Installed  ] [    3] Apache ServiceMix Specs :: JAXB API
>>>>>>>>> 2.1
>>>>>>>>> (1.1.1)
>>>>>>>>> [  81] [Installed  ] [    3] Apache ServiceMix Specs :: JAXWS API
>>>>>>>>> 2.1
>>>>>>>>> (1.1.1)
>>>>>>>>> [  82] [Active     ] [    2] Spring AOP (2.5.6)
>>>>>>>>> [  83] [Active     ] [    2] Spring Beans (2.5.6)
>>>>>>>>> [  84] [Active     ] [    2] Spring Context (2.5.6)
>>>>>>>>> [  85] [Active     ] [    2] Spring Context Support (2.5.6)
>>>>>>>>> [  86] [Active     ] [    2] Spring Core (2.5.6)
>>>>>>>>> [  87] [Active     ] [    2] ObjectWeb ASM (2.2.3)
>>>>>>>>> [  88] [Active     ] [    2] Backport Util Concurrent (3.1.0)
>>>>>>>>> [  89] [Active     ] [    2] CGLIB Code Generation Library (2.1.3)
>>>>>>>>> [  90] [Active     ] [    2] spring-osgi-annotation (1.2.0)
>>>>>>>>> [  91] [Installed  ] [    2] Apache CXF Minimal Bundle Jar
>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>> (2.2.3.SNAPSHOT)
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>> [  92] [Active     ] [    1] osgi.compendium
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> (4.1.0.build-200702212030)
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> [  93] [Active     ] [    1] Apache Felix Shell Service (1.2.0)
>>>>>>>>> [  94] [Active     ] [    1] Apache Felix Shell TUI (1.2.0)
>>>>>>>>> [  95] [Active     ] [    1] geronimo-annotation_1.0_spec (1.1.1)
>>>>>>>>> [  96] [Active     ] [    1] geronimo-activation_1.1_spec (1.0.2)
>>>>>>>>> [  97] [Active     ] [    1] geronimo-javamail_1.4_spec (1.2)
>>>>>>>>> [  98] [Active     ] [    1] OPS4J Pax Web - Service (0.6.0)
>>>>>>>>>
>>>>>>>>> Here is the last bit from the logs:
>>>>>>>>> ...
>>>>>>>>> [FelixStartLevel] DEBUG
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>>
>>>>> org.springframework.osgi.extender.internal.activator.ContextLoaderListener
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> - No application context created for bundle [CGLIB Code Generation
>>>>>>>>> Library (com.springsource.net.sf.cglib)]
>>>>>>>>> [FelixDispatchQueue] DEBUG com.springsource.net.sf.cglib -
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> BundleEvent
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> STARTED
>>>>>>>>> [FelixStartLevel] DEBUG
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>>
>>>>> org.springframework.osgi.extender.internal.activator.ContextLoaderListener
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> - Scanning bundle [spring-osgi-annotation
>>>>>>>>> (org.springframework.osgi.extensions.annotations)] for
>>>>>>>>> configurations...
>>>>>>>>> [FelixStartLevel] DEBUG
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>>
>>>>> org.springframework.osgi.extender.internal.activator.ContextLoaderListener
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> - Creating an application context for bundle
>>>>>>>>> [spring-osgi-annotation
>>>>>>>>> (org.springframework.osgi.extensions.annotations)]
>>>>>>>>> [FelixStartLevel] DEBUG
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>>
>>>>> org.springframework.osgi.extender.internal.activator.ContextLoaderListener
>>>>>
>>>>>
>>>>>>>>>
>>>>>>>>> - No application context created for bundle [spring-osgi-annotation
>>>>>>>>> (org.springframework.osgi.extensions.annotations)]
>>>>>>>>> [FelixDispatchQueue] DEBUG
>>>>>>>>> org.springframework.osgi.extensions.annotations - BundleEvent
>>>>>>>>> STARTED
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Aaron Zeckoski (azeckoski (at) vt.edu)
>>>>>>>>> Senior Research Engineer - CARET - Cambridge University
>>>>>>>>> https://twitter.com/azeckoski -
>>>>>>>>> http://www.linkedin.com/in/azeckoski
>>>>>>>>> http://aaronz-sakai.blogspot.com/ -
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> http://confluence.sakaiproject.org/confluence/display/~aaronz/<http://confluence.sakaiproject.org/confluence/display/%7Eaaronz/>
>>>>>>>>>
>>>>>>>>>
>>>>>
>>>>> <http://confluence.sakaiproject.org/confluence/display/%7Eaaronz/>
>>>>>
>>>>>
>>>>>>>
>>>>>>> <http://confluence.sakaiproject.org/confluence/display/%7Eaaronz/>
>>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ---------------------------------------------------------------------
>>>>>>>>> To unsubscribe, e-mail: [email protected]
>>>>>>>>> For additional commands, e-mail: [email protected]
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Cheers, Stuart
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Aaron Zeckoski (azeckoski (at) vt.edu)
>>>>>>> Senior Research Engineer - CARET - Cambridge University
>>>>>>> https://twitter.com/azeckoski - http://www.linkedin.com/in/azeckoski
>>>>>>> http://aaronz-sakai.blogspot.com/ -
>>>>>>>
>>>>>>>
>>>>>>> http://confluence.sakaiproject.org/confluence/display/~aaronz/<http://confluence.sakaiproject.org/confluence/display/%7Eaaronz/>
>>>>>>>
>>>>>>>
>>>>>
>>>>> <http://confluence.sakaiproject.org/confluence/display/%7Eaaronz/>
>>>>>
>>>>>
>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: [email protected]
>>>>>>> For additional commands, e-mail: [email protected]
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> --
>>>>>> Cheers, Stuart
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>> --
>>>>> Aaron Zeckoski (azeckoski (at) vt.edu)
>>>>> Senior Research Engineer - CARET - Cambridge University
>>>>> https://twitter.com/azeckoski - http://www.linkedin.com/in/azeckoski
>>>>> http://aaronz-sakai.blogspot.com/ -
>>>>>
>>>>>
>>>>> http://confluence.sakaiproject.org/confluence/display/~aaronz/<http://confluence.sakaiproject.org/confluence/display/%7Eaaronz/>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: [email protected]
>>>>> For additional commands, e-mail: [email protected]
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>
>>
>>
>>
>



-- 
-------------------------------------------------------------------------------------

Paremus Limited. Registered in England. Registration No. 4181472

Registered Office: 22-24 Broad Street, Wokingham, Berks RG40 1BA

Postal Address: 107-111 Fleet Street, London, EC4A 2AB

The information transmitted is intended only for the person(s) or
entity to which it is addressed and may contain confidential and/or
privileged material. Any review, retransmission, dissemination or
other use of, or taking of any action in reliance upon, this
information by persons or entities other than the intended recipient
is prohibited.

If you received this in error, please contact the sender and delete
the material from any computer.

-------------------------------------------------------------------------------------

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to