How to Read File a remotely using TCP/ip Sockets in java

A

avdhesh.yadav

Hi all

let me first explain secnerio.

Actually i have to write a multithreaded program.
In this program i have to read files remotely using TCP sockets...
Everytime New file comes i have to create a new Socket and accept and
read the file.


and then after rading it i have to send it to a a client..

Thing is that file is Remotly located..
first i have to connect to that server ad then read file and send it
client..where we done processing ..

i m thinking two things ..
in one case i crrate a single socket and read files through this socket
and send it to cleint..
other is creat separate sockets and read files and then send it to
client..


Which option is correct and how i program this..

Thanks in advace
Avdhesh
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,190
Members
46,736
Latest member
zacharyharris

Latest Threads

Top