0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

13 Commits

Author SHA1 Message Date
Ryan
73fb24f48d Relatively large update to TCP API. No more "protocol".
Instead servers are passed a function which gets called on connection (like
in the original design) which has one argument, the connecting socket. The
user sets up callbacks on that. It's pretty much how I had it originally.

Encoding is now set via v8 getter/setter and can be changed dynamically.

The timeout for all sockets is fixed at 60 seconds for now. Need to fix
that.
2009-05-14 23:47:21 +02:00
Ryan
31ba3cde17 Rename TCP classes to sit in node hierarchy. 2009-05-14 20:34:14 +02:00
Ryan
30450388d6 update oi_socket - modify node code to match 2009-05-05 12:52:18 +02:00
Ryan
09c2ae5c3e Slight change in tcp connection constructor
For server-side sockets, no longer pass the server object to the
js constructor. This is set later with SetAcceptor.

I think the change is a bit strage and convoluted but it allows one give
protocol /classes/ to the c++ constructors instead of protocol instances.
This is nice because derived classes (like HTTP) don't need to copy the
protocol instanciation code.
2009-05-04 12:08:13 +02:00
Ryan
5a071ad72f Begin refactor of http.cc. Remove libebb add http_parser.
And most of http.cc was deleted.
2009-05-03 14:09:16 +02:00
Ryan
bb6057d9ad rename Connection.disconnect -> Connection.close 2009-05-03 01:11:39 +02:00
Ryan
1713386580 add Connection::SendEOF. modify test accordingly. 2009-05-03 01:01:42 +02:00
Ryan
15d24d8002 Major refactor of network code
Here I massively change both the external and internal API of the TCP
sockets and servers.

This change introduces the concept of a protocol object like is found in
Twisted Python. I believe this allows for a much cleaner description of how
a socket behaves. What was once a single object "client" or "connection" is
now represented by two objects: a "connection" and a "protocol".

Well - I don't want to ramble too much because neither API is yet public or
documented.  Look the diff of test/test-pingpong.js to see how things have
changed.
2009-05-02 16:34:24 +02:00
Ryan
0f5170339c remove process.{cc,h} process.exit() now exit()
the process object might return in the future but for now it is going away.
2009-04-29 11:09:32 +02:00
Ryan
cf1c58063e Create a node namespace
Part of general reorganization.
2009-04-28 23:09:56 +02:00
Ryan
f17ecf20be change localhost to 127.0.0.1 because macs suck 2009-04-23 19:04:01 +02:00
Ryan
8514e0627a improved ping pong test. 2009-04-23 01:14:11 +02:00
Ryan
e6d96e8e66 rename echoserver -> pingpong 2009-04-22 16:05:14 +02:00