Object pooling in .net, DOT NET Programming

How object pooling in .NET is done

COM+ reduces overhead by creating object from scratch. Thus  in COM+ when object is activated its activated from pool and when its deactivated it's pushed back to the pool. Object pooling was configured by using the "ObjectPoolingAttribute" to the class.

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

Public Class testingclass

Inherits ServicedComponent

Public Sub DoWork()

'Method contents go here.

 End Sub

 End Class

The sample Code above has the "ObjectPooling" attribute defined. Below is a sample code which uses the class.

Public Class

App Overloads Public Shared Sub Main(args() As String)

Dim xyz As New TestObjectPooling()

 xyz.doWork()

ServicedComponent.DisposeObject (xyz)

End Sub

End Class

Posted Date: 9/21/2012 7:31:59 AM | Location : United States







Related Discussions:- Object pooling in .net, Assignment Help, Ask Question on Object pooling in .net, Get Answer, Expert's Help, Object pooling in .net Discussions

Write discussion on Object pooling in .net
Your posts are moderated
Related Questions
This assignment requires you to design, develop and implement a token web application. It is intended to assess your mastery of the web application development concepts and ASP.NET

Project Description: System is used for tracking company's activities through several projects by keeping track of incomes and expenses per project. This project is fairly ea

What is the Scope of public/private/friend/protected/protected friend? Scope of public/private/friend/protected/protected friend Visual Basic/Visual C# Public/public all

How does CAS works? There are two key methods of CAS security policy- code groups and permissions. A code group contains assemblies in it in a manner that each .NET assembly is

Printing and adding Fibonacci series - C# Program Hello guys i need your advice. How can i print and add Fibonacci series in my project. Please recommend some examples.

Fixing chrome problem Problem 1- Booksearcha.asp and bookrstep2.asp on allreaders.com (bookrstep2 only accessible from bookrstep1.asp) utilize scroll down menus at times. In Chr

1  Assignment Description   This is an individual assignment. Students are referred to the Faculty's policy on plagiarism.  In this assignment you will build a prototype of a si

Question : (a) Describe what are streams in file handling and explain what should be done when accessing data in an existing file. (b) For what purpose are StreamReader an

In this task, you are required to create an Account Management application with Web Form. Your Account Management application must have the following pages: 1.  Create an accoun

How to use a checkbox in a datagrid? The steps to be done are as follows:- 1)    In the ASPX page you have to add Itemtemplate tag in datagrid. 2) I