Exception - The socket has been shut down

Discussions about the preview versions of Virtual Radar Server.
Forum rules
Please bear in mind if you do install a preview version that it is unfinished code, there may be bugs, bits missing, things that don't work etc.

Posts in this forum will not show up in forum search results. Old threads will be pruned occasionally.
Post Reply
Datamix
Posts: 42
Joined: Thu Aug 10, 2017 7:36 pm

Exception - The socket has been shut down

Post by Datamix » Sun Apr 15, 2018 6:13 pm

I am using VRS: 31-MAR-2018 and I frequently got this exception: What is actually happening here?

Code: Select all

[2018-04-15 15:59:42.349 UTC] [t284] Exception caught during handling of request http://192.168.0.16:8080/VirtualRadar/images/File-HB-ZRE 4B43C2/Size-iPadDetail/Wdth-350/Hght-238/Picture.png: System.IO.IOException: Unable to write data to the transport connection: The socket has been shut down. ---> System.Net.Sockets.SocketException: The socket has been shut down
at System.Net.Sockets.Socket.Send (System.Byte[] buffer, System.Int32 offset, System.Int32 size, System.Net.Sockets.SocketFlags socketFlags) [0x00016] in <67546f875ae44445b5aba5311d41f9dc>:0
at System.Net.Sockets.NetworkStream.Write (System.Byte[] buffer, System.Int32 offset, System.Int32 size) [0x0009b] in <67546f875ae44445b5aba5311d41f9dc>:0
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Write (System.Byte[] buffer, System.Int32 offset, System.Int32 size) [0x000e2] in <67546f875ae44445b5aba5311d41f9dc>:0
at System.Net.ResponseStream.InternalWrite (System.Byte[] buffer, System.Int32 offset, System.Int32 count) [0x0001b] in <67546f875ae44445b5aba5311d41f9dc>:0
at System.Net.ResponseStream.Write (System.Byte[] buffer, System.Int32 offset, System.Int32 count) [0x000cf] in <67546f875ae44445b5aba5311d41f9dc>:0
at Microsoft.Owin.Host.HttpListener.RequestProcessing.ExceptionFilterStream.Write (System.Byte[] buffer, System.Int32 offset, System.Int32 count) [0x00024] in <d87779ef62ca4c3698568e9d3e48e24e>:0
at System.IO.Stream.InternalCopyTo (System.IO.Stream destination, System.Int32 bufferSize) [0x00009] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.IO.Stream.CopyTo (System.IO.Stream destination) [0x00084] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at (wrapper remoting-invoke-with-check) System.IO.Stream.CopyTo(System.IO.Stream)
at VirtualRadar.Owin.Middleware.ResponseStreamWrapper+<>c__DisplayClass2_0+<<WrapResponseStream>b__0>d.MoveNext () [0x00146] in <cdceea189af34bb8877a686dc5233004>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () [0x00000] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at VirtualRadar.Owin.Middleware.CorsHandler+<>c__DisplayClass6_0+<<HandleRequest>b__0>d.MoveNext () [0x00080] in <cdceea189af34bb8877a686dc5233004>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () [0x00000] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at VirtualRadar.Owin.Middleware.RedirectionFilter+<>c__DisplayClass2_0+<<FilterRequest>b__0>d.MoveNext () [0x00080] in <cdceea189af34bb8877a686dc5233004>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () [0x00000] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at VirtualRadar.Owin.Middleware.BasicAuthenticationFilter+<>c__DisplayClass6_0+<<FilterRequest>b__0>d.MoveNext () [0x00080] in <cdceea189af34bb8877a686dc5233004>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () [0x00000] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at VirtualRadar.Owin.Middleware.AccessFilter+<>c__DisplayClass2_0+<<FilterRequest>b__0>d.MoveNext () [0x00080] in <cdceea189af34bb8877a686dc5233004>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () [0x00000] in <5360c2b4f84a4c7fa3972ce4a86e27fb>:0
at VirtualRadar.Owin.Middleware.ExceptionHandler+<>c__DisplayClass0_0+<<HandleRequest>b__0>d.MoveNext () [0x00073] in <cdceea189af34bb8877a686dc5233004>:0 
vrs: 12-MAY-2018

agw
Posts: 1970
Joined: Fri Feb 17, 2012 3:20 am

Re: Exception - The socket has been shut down

Post by agw » Sat Apr 28, 2018 3:33 pm

It's saying that the network connection was closed while the request was being processed. This usually means that someone closed the site, it's a benign error. I usually throw these messages away in the release version but because the web handling has been rewritten I'm currently showing socket errors in the preview version, just in case something important pops up. As far as I'm aware there's not much to be gained from continuing to show them, they'll be getting thrown away in an upcoming preview version.

Datamix
Posts: 42
Joined: Thu Aug 10, 2017 7:36 pm

Re: Exception - The socket has been shut down

Post by Datamix » Sun Apr 29, 2018 5:02 pm

agw wrote:
Sat Apr 28, 2018 3:33 pm
It's saying that the network connection was closed while the request was being processed. This usually means that someone closed the site, it's a benign error. I usually throw these messages away in the release version but because the web handling has been rewritten I'm currently showing socket errors in the preview version, just in case something important pops up. As far as I'm aware there's not much to be gained from continuing to show them, they'll be getting thrown away in an upcoming preview version.
All clear - thank you for clarifying.
vrs: 12-MAY-2018

Post Reply