sockets - Chatserver. what happens to read an write buffer when ..? -
a tcp chatserver uses polling method concurrent service. client sending huge amounts of data constantly. chatserver tries send data client client b , c. but, client b , c not reading read buffer. happens read , write buffer chatserver, client a, client b , client c. there 2 cases 1. chatserver has blocking sockets. 2. chatserver has non blocking sockets.
if you're talking tcp, receiver's socket receive buffer fills up, sender's socket send buffer fills up, sender either blocked (in blocking mode) or returned -1 errno == eagain/ewouldblock
in non-blocking mode.
if you're talking udp datagrams dropped.
Comments
Post a Comment