Top "Socketchannel" questions

Issues related to socket channel for stream-oriented connecting sockets in Java

Socket vs SocketChannel

I am trying to understand SocketChannels, and NIO in general. I know how to work with regular sockets and how …

java sockets socketchannel
Connection was forcibly closed by the remote host

I have a java.nio.channels.SocketChannel in my jSCSI implamantation that is disconnecting when I try to open a …

java sockets ioexception socketchannel
How to get data from TCP socket into a ByteBuffer

I need to get incoming data from a socket into a ByteBuffer and I do not know how to do …

java sockets tcp bytebuffer socketchannel
Java.nio Channels and TLS

How do I secure a Java SocketChannel, ServerSocketChannel or, perhaps even, a DatagramChannel with TLS? I know that there are …

java nio ssl socketchannel
Timeout for SocketChannel doesn't work

I want to use a SocketChannel and to have a timeout for its read/write methods. I've tried to set …

java socketchannel
Java SocketChannel doesn't detect disconnection?

I have a socket running, using selectors. I am trying to check to see if my socket is connected to …

java sockets socketchannel
Read timeout for an NIO SocketChannel?

What is the best way to set a timeout to close a NIO SocketChannel if there is no data is …

java nio socketchannel
HttpPost: InputDispatcher: "Channel is unrecoverably broken and will be disposed!" on Nexus 7

On Nexus 7 (4.3), and not on my older device, LG Optimus 3d (Android 2.2), when I do HttpPost, I get this E/…

java android http-post channel socketchannel
Java NIO: How to know when SocketChannel read() is complete with non-blocking I/O

I am currently using a non-blocking SocketChannel (Java 1.6) to act as a client to a Redis server. Redis accepts plain-text …

java nio nonblocking socketchannel
Java NIO. SocketChannel.read method all time return 0. Why?

I try understand how works java NIO. In particular, how works SocketChannel. I wrote code below: import java.io.*; import …

java sockets nio socketchannel