Why do we need to Dispose things, when we're in a Managed Runtime? When should be be disposing? How to correctly dispose of things? All these and many more question discussed and answered in this video. We look at a number of complicated scenarios in this video by way of code examples and go about fixing the issues to make all work as it is supposed to.
Source Code for the Completed VS Solution can be found here:
github.com/matlus/IDisposable...
Chapter Markers
00:00 Intro
01:45 What is Managed Code
03:16 Managed Services
04:41 Unmanaged Services
10:02 Introducing the Code for this video
15:06 Cascade Disposables
15:54 The Dispose Pattern
20:02 Why GC.SupressFinalize
21:51 Reason for Why we have IDisposable
27:31 ADO.NET - Connections, Transactions, Commands
30:30 DbConnection - Close vs Dispose
33:19 IDisposable & Close vs Dispose
34:33 Logger Provider also uses Disposable Things
43:26 Background Services and IDisposable/IAsyncDisposable
21 июл 2024