Currently, SessionDataSet implements the IDisposable interface. However, in its Dispose() method, the asynchronous Close() method is invoked synchronously.
Actual implementation:
protectedvirtualvoidDispose(booldisposing){if(this.disposedValue)return;if(disposing){try{//synchronous callthis.Close().Wait();}catch{}}this.disposedValue=true;}Proposed implementation:
protectedvirtualTaskDisposeAsync(booldisposing){if(this.disposedValue)return;if(disposing){try{//asynchronous callawaitthis.Close();}catch{}}this.disposedValue=true;}
Currently, SessionDataSet implements the IDisposable interface. However, in its Dispose() method, the asynchronous Close() method is invoked synchronously.
Actual implementation:
Proposed implementation: