hammett wrote:

----- Original Message ----- From: "Stephen McConnell" <[EMAIL PROTECTED]>



The potential issue here (that we discussed way back) concerns the fact
that a component lifestyle is not assured.



Rulez! I searched for something like this in .Net but didn't find. I'm aware
that Merlin transient lifestyle handler keeps created objects in a list. Is
it the best? If someone forget to call release the instance will be there
for the entire container lifetime... I tried to solve that to not depends on
releasing. :-\



It depends on which snapshot you were looked at - it was either the old "TODO: add weak references" or the current version where the weak references are in place. In the current version the transient lifestyle handler maintains a queue of weak references that have been garbage collected. It also maintains a list of soft references to instances created. The list is required so that the handler can decommission the compoent it has established during its own disposal cycle. The queue of garbage collected objects provides the information I need to be able to compact the list of weak references.


With this change there are only two know memory problem - logkit categories and container removal from the meta model. If I'm running Merlin for months on end without restart, and if there are continual creation of log catagories, and the components are destroyed, I'm still left with logkit logging channels in memory. Basically I need to dig into logkit and change the Logger hard references to WeakReferences. For the meta-model I need to to do some thingking about possibilities for auto removal of containers that are no longer referenced.

Stephen.

hammett


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]





--


Stephen J. McConnell
mailto:[EMAIL PROTECTED]




--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to