From: Guijarro, J. <jul...@hp...> - 2006-11-22 11:52:15
|
Hi, By default all terminations as Asynchronous. It you want your compound to wait for the termination of its children then you have to add the configuration attribute sfSynchTerminate true. Then, when terminating, compound will notify, always in reverse deployment order, its children to terminate but every sfTerminate call will be blocking. It a component is terminating and it is notified to terminate again it will ignore the call and return immediately. Julio G > -----Original Message----- > From: sma...@li... [mailto:smartfrog- > sup...@li...] On Behalf Of Sabharwal, Ritu (STSD) > Sent: 22 November 2006 11:43 > To: Andreas Unterkircher > Cc: smartfrog-support > Subject: Re: [Smartfrog-support] termination question >=20 > Hello Andreas, >=20 > Yes, but putting an explicit lock in sfTerminate method of component A > till the event task finishes, SF can wait for the termination of A. >=20 > Thanks & Regards, > Ritu. >=20 > Andreas Unterkircher wrote: >=20 > > Hi Ritu, > > termination means calling the sfTerminate method, I think. So if A has > > some lock variable that would cause sfTerminate to just wait until the > > task caused by the event is finished, this would cause SF to "wait" > > with termination of A ? > > > > Best regards, > > Andreas > > > > Ritu Sabharwal wrote: > > > >> Hi Andreas, > >> > >> In case of Compound, if any child terminates it notifies the parent > >> which in turn terminates all other children and then itself. So in > >> your case, SF will not wait for A to finish its task, it will > >> terminate it immediately as soon as B terminates. > >> > >> Thanks & Regards, > >> Ritu. > >> > >> Andreas Unterkircher wrote: > >> > >>> Hello, > >>> > >>> I have a question concerning termination. Suppose I have a compound > >>> containing 2 components: > >>> > >>> Compound { > >>> A; > >>> B; } > >>> > >>> A extends EventCompoundImpl. B terminates and in its sfTerminate > >>> method it sends an event to A which causes A to do some task that > >>> take some time. If B terminates, what happens to A ? Would SF wait > >>> until A finishes the task triggered by B's message ? Or would it > >>> just terminate A ? > >>> > >>> Thanks, > >>> Andreas > >>> > >>> ---------------------------------------------------------------------- > --- > >>> > >>> Take Surveys. Earn Cash. Influence the Future of IT > >>> Join SourceForge.net's Techsay panel and you'll get the chance to > >>> share your > >>> opinions on IT & business topics through brief surveys - and earn cash > >>> > http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3D= DEVDE V > >>> > >>> _______________________________________________ > >>> Smartfrog-support mailing list > >>> Sma...@li... > >>> https://lists.sourceforge.net/lists/listinfo/smartfrog-support > >>> > >>> > >> > >> > > > > >=20 >=20 >=20 > ------------------------------------------------------------------------ - > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3D= DEVDE V > _______________________________________________ > Smartfrog-support mailing list > Sma...@li... > https://lists.sourceforge.net/lists/listinfo/smartfrog-support |