Balanced File Distribution from server to client
Posted
by Abhinav
on Stack Overflow
See other posts from Stack Overflow
or by Abhinav
Published on 2010-05-06T18:34:06Z
Indexed on
2010/05/06
18:38 UTC
Read the original article
Hit count: 331
file-transfer
To design a client-server code in LINUX where server will send the file equally to its entire client connected(all not at a time). Suppose 15 files are there, client1 makes a connection, server starts sending files to it. After 4 files a new connection comes the first client gets halted (not terminated) and client2 start getting the file. After 2 files another connection comes. Server starts sending file to client3. after sending 3[2(client2)+1] files, server resumes client2.then client2 & client3 goes on till file count reaches 4.then client1 wakeup & remaining 3 files are transferred to each 3 clients.
File's name are pre written in a file from where server reads it(not a big deal)
© Stack Overflow or respective owner