Groups | Blog | Home
all groups > dotnet component services > july 2003 >

dotnet component services : pbl with pooling


fred
7/7/2003 9:51:04 AM
I created a serviced component and added the attribute:
[ObjectPooling(true,2,4)]

I also override the CanBePooled tu return true.

But it's not working, the object is never pooled.

I have the same behaviour with th poolings settings in
the component service administration tool.

What can I do more?

thank you?

Is there any difference when using administrative tool or
attribute?
Ziga Jakhel
7/7/2003 8:55:17 PM
1) Are you using Just-In-Time activation?

1.b) If yes, do you implement the [AutoComplete] attribute or set the
SetComplete / SetAbort at the end of the method?

2) If the answer to Q1 is not, are you calling myObject.Dispose() after you
are done using the object?

If the answer to Q1 and Q2 is "no", then there is your problem...

You need to let the ServicedComponent know that it's time is up and that it
should return to the pool. Either by implementing JIT activation, or by
explicitly disposing of the object.

Regards,

Ziga Jakhel

[quoted text, click to view]

AddThis Social Bookmark Button