Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 63BBA200CF8 for ; Thu, 14 Sep 2017 11:47:09 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 62B381609CD; Thu, 14 Sep 2017 09:47:09 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id AB9EA1609CC for ; Thu, 14 Sep 2017 11:47:08 +0200 (CEST) Received: (qmail 64721 invoked by uid 500); 14 Sep 2017 09:47:07 -0000 Mailing-List: contact users-help@felix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@felix.apache.org Delivered-To: mailing list users@felix.apache.org Received: (qmail 64662 invoked by uid 99); 14 Sep 2017 09:47:06 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Sep 2017 09:47:06 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 1FF4B18F23A for ; Thu, 14 Sep 2017 09:47:06 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -2.401 X-Spam-Level: X-Spam-Status: No, score=-2.401 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.8, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id 3SCK6xd6CH2k for ; Thu, 14 Sep 2017 09:47:04 +0000 (UTC) Received: from mail-wr0-f194.google.com (mail-wr0-f194.google.com [209.85.128.194]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id CE0F25FC1C for ; Thu, 14 Sep 2017 09:47:03 +0000 (UTC) Received: by mail-wr0-f194.google.com with SMTP id g50so1383546wra.3 for ; Thu, 14 Sep 2017 02:47:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; bh=dPMRRXZ4hk/xORoYNMv5YfN1MRdrjp6xC8VaCTy/M4U=; b=JcpJBNenTIMMVERGn1g5LQiuL+K+nuU2D3MLF1XBgT08Wm2KkLUDW5ikCrL7umgpjU f0Ybfa7m0MqXhtBFXS3GQHYv2EZgrW15ah3p0x7xHJiCOnemYH5dtn8EVFiwvGFRy6vQ XXIrwlo/iI+jDYVmb6mpfNk9uXwoPijDyVce7YW8ZSaH2NBbHYegmMLIclBRoeAH4Kn+ X5aPiRZPgrsuPXftIp/+xuAIjKgQjc0z3UfXIpNZR2JINQfffEOWVcQ/FThfGrZabkKx jLUImBHPLxD2St3vxq1B1HKcWM5iZuiQV1UCAdp2LCo0cpMFVEUC27rDYHgtI6U4UOBN 42vQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; bh=dPMRRXZ4hk/xORoYNMv5YfN1MRdrjp6xC8VaCTy/M4U=; b=eblurgr2mu7Dvxr5WQpL57VZcVqPnbs7Swd51y8UUKd1FyV9D7RMKQC94PWaqg8f8X B3/W3V4tpEqWKEmeTkrCCHILPCq3IdcRzUQ0Z1THJAv4BOezHII0N80NMOlMmgZzngYb QVemBrzjfdV9oervYBzx0VW+e9d/GoH50HIOfReRVlKx8okjmM19/TPNzxG2EHwzDPC+ 6UpqT2Glij3Dxx8Ybu6ExNAFp9RZ7TOjaNz22tzf28DdOVPGyYs99pWX5fq4A/aUa8Kn CW66Df+lVRWaDV8i6ZCGaH+YtqT1gKzgC6edIB1CUTCETwxKJ3gnXKa5hwTfJ2soiRgN +Szg== X-Gm-Message-State: AHPjjUi/dCLhrLxPjXZVuAA8rG4oDgDcXDckVjGJ6eARZ29kIpuZCJ96 LLIm1s2VpCPYqbVYZl8= X-Google-Smtp-Source: ADKCNb6Ve/uyigGsuJAso5sHtcqwrdd1Vr8eG5F780cqUXbz7FB2ITte7qZPFgD3XKObN4ivt5uA9w== X-Received: by 10.223.184.251 with SMTP id c56mr13916407wrg.145.1505382416994; Thu, 14 Sep 2017 02:46:56 -0700 (PDT) Received: from endofunctor.home (host86-164-192-182.range86-164.btcentralplus.com. [86.164.192.182]) by smtp.gmail.com with ESMTPSA id m184sm525951wme.25.2017.09.14.02.46.55 for (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 14 Sep 2017 02:46:56 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Subject: Re: how do I stop JavaFX bundles? From: Neil Bartlett In-Reply-To: Date: Thu, 14 Sep 2017 10:48:55 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: References: To: users@felix.apache.org X-Mailer: Apple Mail (2.3124) archived-at: Thu, 14 Sep 2017 09:47:09 -0000 Calling getBundle(0).stop() does not just shut down an OSGi bundle, it = shuts down the entire OSGi framework. It=E2=80=99s not clear to me = whether that=E2=80=99s what you should be doing. As for shutting down JavaFX, you have found =E2=80=9CPlatform.exit()=E2=80= =9D but you are looking for a better way? Maybe this question should be = asked on a JavaFX forum. Regards, Neil > On 14 Sep 2017, at 03:36, Chuck Davis wrote: >=20 > After a few weeks delay for knee replacement I cobbled together a = program > yesterday that uses the FrameworkFactory service to create a Framework = and > install 3 bundles -- all of which is working splendidly as expected. >=20 > My first bundle is this that Renato directed me to in the last thread = about > this issue which takes care of the classloading issue for JavaFX: >=20 > https://github.com/edvin/javafx-osgi >=20 > My second bundle creates the Stage service that Paul talked about. >=20 > My third bundle creates a couple Scenes and depending on the button = pressed > changes the Scene on the Stage. >=20 > This basic scheme is working now. >=20 > BUT....now I have to stop things "cleanly" as "OSGi In Action" = mentions. > Unfortunately, there is no JavaFX in the book. >=20 > My main class just installs the bundles and then is finished but does = not > terminate the JVM. >=20 > I dinked around today until I came up with the combination of > Platform.exit() followed by BundleContext.getBundle(0).stop(). = Stopping > bundle 0 is apparently the accepted way to stop Felix. With this > combination both JVM instances end (my main class and the Framework) = and > the visual bits and pieces disappear. It's not too elegant and I have = to > believe there is a better way to shut down JavaFX bundles. ???? >=20 > Anybody have suggestions? >=20 > Thanks in advance. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@felix.apache.org For additional commands, e-mail: users-help@felix.apache.org