|
Home > Archive > Unix Programming > April 2004 > about peer to peer programming
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
about peer to peer programming
|
|
|
| client/server model programming is like this:
server: socket() bind() listen() accept()
client: socket() connect()
I know p2p is a peer relationship, but I think if there are 2 peers connected,
there must be one server and one client between them, i.e. one of them listen()
and the other connect(), am I right ?! Or in p2p programming there is another
programming method rather than listen() connect() ?!
thanks in advance.
slash
| |
| Måns Rullgård 2004-04-30, 10:33 pm |
| slash@ms32.url.com.tw (slash) writes:
> client/server model programming is like this:
> server: socket() bind() listen() accept()
> client: socket() connect()
>
> I know p2p is a peer relationship, but I think if there are 2 peers
> connected, there must be one server and one client between them,
> i.e. one of them listen() and the other connect(), am I right ?
This is correct. The difference is that all nodes are equal, and can
act as both client and server simultaneously.
--
Måns Rullgård
mru@kth.se
|
|
|
|
|