Many library classes feature meaningless finalizers that do nothing at runtime but grow the finalization queue and thus slow down GC and application performance.
This is especially concerning for frequently-used classes like SshCommand and Channel.
The library classes don't need finalizers as they aren't dealing with allocation and deallocation of unmanaged resource handles.
The nuances of a correct IDisposable implementation are neatly summarized here:
https://github.com/sidristij/dotnetbook/blob/master/book/en/LifetimeManagement/2-Disposable.md
Many library classes feature meaningless finalizers that do nothing at runtime but grow the finalization queue and thus slow down GC and application performance.
This is especially concerning for frequently-used classes like SshCommand and Channel.
The library classes don't need finalizers as they aren't dealing with allocation and deallocation of unmanaged resource handles.
The nuances of a correct IDisposable implementation are neatly summarized here:
https://github.com/sidristij/dotnetbook/blob/master/book/en/LifetimeManagement/2-Disposable.md