| | size=2>Unfortunately, as of Java 1.2, most blocking I/O statements in the JDK still ignore interrupt requests. This presents a problem when you want to have a thread stop waiting on the I/O operation and do something else—typically to clean up and die. This problem generally arises in situations where data is read from a stream intermittently. A common case is a conversation between a client and server over a socket’s streams. Typically in this scenario, a thread blocks for long periods of time on a stream waiting for another request to come across the line. | |
|
No comments:
Post a Comment