Return-Path: Delivered-To: apmail-jakarta-avalon-phoenix-dev-archive@apache.org Received: (qmail 35948 invoked from network); 2 Apr 2002 13:00:13 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 2 Apr 2002 13:00:13 -0000 Received: (qmail 7417 invoked by uid 97); 2 Apr 2002 13:00:13 -0000 Delivered-To: qmlist-jakarta-archive-avalon-phoenix-dev@jakarta.apache.org Received: (qmail 7372 invoked by uid 97); 2 Apr 2002 13:00:12 -0000 Mailing-List: contact avalon-phoenix-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Avalon-Phoenix Developers List" Reply-To: "Avalon-Phoenix Developers List" Delivered-To: mailing list avalon-phoenix-dev@jakarta.apache.org Received: (qmail 7361 invoked from network); 2 Apr 2002 13:00:12 -0000 Message-ID: <3CA9A86F.3050001@yahoo.com> Date: Tue, 02 Apr 2002 13:47:43 +0100 From: Paul Hammant User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.9) Gecko/20020311 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Avalon-Phoenix Developers List Subject: Re: Runnable - Avalon Framework Lifecycle interface? References: <3CA97D88.6020104@yahoo.com> <200204021226.g32CQmJ18193@mail018.syd.optusnet.com.au> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Peter Donald wrote: >On Tue, 2 Apr 2002 19:44, Paul Hammant wrote: > >>Folks, >> >>Is java.lang.Runnable a lifecycle interface? Does it imply that the >>implementing component should be placed in a Thread? : >> >> if (comp instanceof Initializable) { >> ((Initializable comp).initialize() { >> } >> >> if (comp instanceof Startable) { >> ((Startable comp).start() { >> } >> >> if (comp instanceof Runnable) { >> Thread t = getThread((Runnable) comp); >> t.start(); >> } >> >>I ask because EOB has daemon beans that treat Runnable as a lifecycle >>interface. >> > >It used to be but we zapped it because there was too many ambiguous cases. ie >if run() finishes does that mean should we shutdown component or just call >run again? if run() exceptions should we kill component or restart it or what >? If we call stop and run() does not return what do we do? > Yup, now Leo has pointed to the document I agree that it is too ambigous. Leave as is ( I have some small rework to do in EOB - so far 383 downloadsof latest release). - Paul -- To unsubscribe, e-mail: For additional commands, e-mail: