Return-Path: X-Original-To: apmail-karaf-issues-archive@minotaur.apache.org Delivered-To: apmail-karaf-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EBDCBDC6E for ; Thu, 16 May 2013 05:33:21 +0000 (UTC) Received: (qmail 28429 invoked by uid 500); 16 May 2013 05:33:21 -0000 Delivered-To: apmail-karaf-issues-archive@karaf.apache.org Received: (qmail 28283 invoked by uid 500); 16 May 2013 05:33:19 -0000 Mailing-List: contact issues-help@karaf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@karaf.apache.org Delivered-To: mailing list issues@karaf.apache.org Received: (qmail 27939 invoked by uid 99); 16 May 2013 05:33:17 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 16 May 2013 05:33:17 +0000 Date: Thu, 16 May 2013 05:33:17 +0000 (UTC) From: =?utf-8?Q?Jean-Baptiste_Onofr=C3=A9_=28JIRA=29?= To: issues@karaf.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (KARAF-1894) Framework's active start level is set to org.osgi.framework.startlevel.beginning too early when launching Karaf with empty bundle cache MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/KARAF-1894?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:all-tabpanel ] Jean-Baptiste Onofr=C3=A9 updated KARAF-1894: ---------------------------------------- Fix Version/s: 3.0.0 2.4.0 2.3.2 2.2.12 =20 > Framework's active start level is set to org.osgi.framework.startlevel.be= ginning too early when launching Karaf with empty bundle cache > -------------------------------------------------------------------------= -------------------------------------------------------------- > > Key: KARAF-1894 > URL: https://issues.apache.org/jira/browse/KARAF-1894 > Project: Karaf > Issue Type: Bug > Affects Versions: 2.2.9, 3.0.0 > Environment: Mac 10.8.2/Oracle JDK 1.6.0_35 > Reporter: Jason Montojo > Assignee: Jean-Baptiste Onofr=C3=A9 > Fix For: 2.2.12, 2.3.2, 2.4.0, 3.0.0 > > Attachments: slbug.tar-3.0.gz, slbug.tar.gz > > > When launching Karaf 2.2.9 with an empty bundle cache, the framework's ac= tive start level is already set to org.osgi.framework.startlevel.beginning = before all the boot features have been started. The impact is that bundles= can be loaded in the wrong order, and File Install ends up scanning the de= ploy folder when it's not supposed to. > This is problematic because we're using boot features to load up our core= infrastructure and the deploy folder to host plugins. If we prepackage an= y plugins with our product with an empty bundle cache, the plugins get inst= alled and started before the core. > The attached tarball contains a set of 3 bundles that reproduce the sympt= oms. Simply untar within the apache-karaf-2.2.9 directory. > In the test tarball, there are 3 bundles that do the same thing. When st= art() is called, they print out their name and the framework's current star= t level, then wait for 1 second. > bundle1 (start-level=3D60) and bundle2 (start-level=3D80) are part of a b= oot feature. However, bundle2 is listed first in the XML. bundle3 is in t= he deploy directory. File Install is configured so that it doesn't scan un= til start level 81 (via felix.fileinstall.active.level). > I'm expecting that the bundles are loaded in this order: bundle1, bundle2= , bundle3. > If I clear the bundle cache and start Karaf, I get the following output: > [bundle2] 100 > [bundle3] 100 > [bundle1] 100 > This indicates that when bundle2's start() is called, the framework's sta= rt level is already set to org.osgi.framework.startlevel.beginning (in this= case, 100) before the boot features have started. > If I run Karaf again without clearing the bundle cache, I get the followi= ng: > [bundle1] 60 > [bundle2] 80 > [bundle3] 80 > This is better, but felix.fileinstall.active.level is set to 81, so bundl= e3 should not be starting at start level 80. This is probably a separate i= ssue. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrato= rs For more information on JIRA, see: http://www.atlassian.com/software/jira