> On Nov 13, 2018, at 11:38 PM, Alan Carroll <solidwallofc...@oath.com.INVALID> 
> wrote:
> 
> It is generally required, actually. What else will clean it up? It's safer
> with a mutex because then there's no race. But if you know for other
> reasons the scope of access is limited it can be safe. Usually this is
> done with either a transaction based Continuation destroyed in TXN_CLOSE,
> or a one shot that gets an events, performs an action, then destroys itself.


Or, perhaps a more common pattern in our remap plugins is that the 
configuration object holds the continuation, so you can reuse it for many 
transactions, and then you destroy it when the configuration is deleted.

Cheers,

— Leif

> 
> On Mon, Nov 12, 2018 at 7:38 PM Walt Karas <wka...@oath.com.invalid> wrote:
> 
>> Is it safe to call TSContDestroy() from within the continuation's
>> function?  Does it matter whether or not the continuation has a mutex?
>> 
> 
> 
> -- 
> *Beware the fisherman who's casting out his line in to a dried up riverbed.*
> *Oh don't try to tell him 'cause he won't believe. Throw some bread to the
> ducks instead.*
> *It's easier that way. *- Genesis : Duke : VI 25-28

Reply via email to