user image

Preeti Tripathi

Job Interview Skills
English
2 years ago

Question 103. Is The Lack Of Deterministic Destruction In .net A Problem?

user image

Abhishek Mishra

2 years ago

It's certainly an issue that affects component design. If you have objects that maintain expensive or scarce resources (e.g. database locks), you need to provide some way for the client to tell the object to release the resource when it is done. Microsoft recommend that you provide a method called Dispose() for this purpose. However, this causes problems for distributed objects - in a distributed system who calls the Dispose() method? Some form of reference-counting or ownership-management mechanism is needed to handle distributed objects - unfortunately the runtime offers no help with this

Recent Doubts

Close [x]