Showing posts with label ObjectPooling. Show all posts
Showing posts with label ObjectPooling. Show all posts

Wednesday, 30 November 2011

How do you do object pooling in .NET ?

COM+ reduces overhead by creating object from scratch. So in COM+ when object is activated its activated from pool and when its deactivated it’s pushed back to the pool. Object pooling is configures by using the “ObjectPoolingAttribute” to the class.

Note:- When a class is marked with objectpooling attribute it can not be inherited.


ObjectPooling(MinPoolSize := 2, MaxPoolSize := 5, CreationTimeout := 20000)> _
Public Class testingclass