I think I finally got it, and it seems it's the burden issue once
again, unless I'm missing something - which is likely, btw.
I have my controller like so:
class Controller
{
public Controller(INonDisposableDependency
nonDisposableDependency) { ... }
public Controller(IDisposableDependency disposableDependency)
{ ... }
}
I'm running on the trunk. At each request I resolve a controller from
the container and don't explicitly do anything else on the container
itself.
Using the PerWebRequest lifestyle on the controller and independent
from the lifestyle of the dependency, if I register a non disposable
dependency into the container (the first constructor is called), at
the end of the request both controller and dependency are released and
collected when the GC runs.
If I register a disposable dependency, instead (second constructor
called), I see the number of instances of both controller and
dependency growing up. The controller has roots in the microkernel,
Burden property, and the dependency in both the Controller and the
microkernel as well.
All these considerations are made with the help of a profiler.
On Sep 8, 3:21 pm, Tuna Toksoz <
tehl...@gmail.com> wrote:
> I am not yet sure as i didn't have any time since i last looked at it, but
> it is related to component burden of several months ago.It solved one
> similar problem with components not being released, might help.
>
> Let me know if it works, if it does, i will ask for a favor from any of you.
>
> Tuna Toksöz
> Eternal sunshine of the open source mind.
>
>
http://devlicio.us/blogs/tuna_toksozhttp://tunatoksoz.comhttp://twitter.com/tehlike
>
> On Tue, Sep 8, 2009 at 9:18 AM, SimoneB <
simone.bus...@gmail.com> wrote:
>
> > Tuna, what's the purpose of doing that?
>
> > On Sep 8, 3:05 pm, Tuna Toksoz <
tehl...@gmail.com> wrote:
> > > Can you both please try
> > > container.ReleasePolicy = new Releasers.AllComponentsReleasePolicy();
>
> > > Tuna Toksöz
> > > Eternal sunshine of the open source mind.
>
> >
http://devlicio.us/blogs/tuna_toksozhttp://tunatoksoz.comhttp://twitt...