SQLProvider
SQLProvider copied to clipboard
Cannot access a disposed object 'System.Net.Sockets.NetworkStream'
I'm getting the following error regularly:
The type provider 'FSharp.Data.Sql.SqlTypeProvider' reported an error:
Cannot access a disposed object.
Object name:
'System.Net.Sockets.NetworkStream'
when using with Common.DatabaseProviderTypes.MSSQLSERVER
.
I should note that I'm accessing a remote MSSQL instance here, so there might be some network connectivity issues. But this reaction is less than ideal. Maybe handling connectivity issues and reconnecting is a good idea?
I've been using a remote MSSQL from Azure like a year now without this kind of problem. So we'll need more info about this...
Huh. Interesting. I neglected to mention that I'm running F# on Linux via mono. I'll try to see if changing that makes a difference and get back to you.
So the network connection was lost? You can do simple manual reconnection like this: https://github.com/fsprojects/SQLProvider/issues/397#issuecomment-296618798