Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How does Garbage collector(GC) works in .net

Answer Posted / pradip kumar

Basically GC.Collect will work only if the memeory space is
less then required space.

You can force it to run by System.GC.Collect();

How it works :
Through 'Genaration Number' . CLR assigned this number for
each object so that GC can identify which one to be removed.
It can be 0,1,2 based upoon the
old/new/referenced/dereferenced criteria.
To check the space before and after GC.Collect() method use
GC.GetTotalMemory(true) method.


Regards,
Pradip kr Sen
Hyderabad

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do I use response redirect?

934


What is the difference between pathparam and queryparam?

990


What is webresource axd?

831


Can you explain how ASP.NET application life cycle and page life cycle events fire?

972


Can we have a web application running without web.config file?

941


What is the difference between session.abandon() vs clear()?

932


How many types of validators are there in asp net?

907


How do u deploy your asp.net application?

1007


How we can force all the validation controls to run?

928


What is server redirect?

948


How to turn off cookies for a page?

948


Explain the difference between codebehind="mycode.aspx.cs" and src="mycode.aspx.cs"?

941


Why should i prefer JSP over asp.net or any other web development language..??

1937


Explain the basic functionality of garbage collector?

930


If you have an application with multiple security levels though secure login and my ASP.NET web appplication is spanned across three web-servers by using round-robbin load balancing. Explain which is the best approach to maintain login-in state for the users?

1048