what is the meaning of Broken pipe Exception?

前端 未结 3 1854
星月不相逢
星月不相逢 2020-12-14 16:37

what is the meaning of broken pipe exception and when it will come?

相关标签:
3条回答
  • 2020-12-14 17:19

    Pipe is basically a communication channel between two processes. So one process writes to the pipe while the other reads from it. A broken pipe exception typically means that one process is attempting to read or writ data from a pipe, where as the process on the other end of the pipe has died/been killed.

    0 讨论(0)
  • 2020-12-14 17:36

    A pipe is a data stream, typically data being read from a file or from a network socket. A broken pipe occurs when this pipe is suddenly closed from the other end. For a flie, this could be if the file is mounted on a disc or a remote network which has become disconnected. For a network socket, it could be if the network gets unplugged or the process on the other end crashes.

    In Java, there is no BrokenPipeException specifically. This type of error will be found wrapped in a different exception, such as a SocketException or IOException.

    0 讨论(0)
  • 2020-12-14 17:38

    I think you are using Java.net ?

    If you closed the connection, then you need to open a new socket before you can send more data.

    or your connections is been rejected

    0 讨论(0)
提交回复
热议问题