00:02:14  <CIA-53>node: Ryan Dahl many-writes-fix * r76f6af6 / lib/net_uv.js : Simplify arg parsing in String.write - http://git.io/33I9tg
00:08:51  <CIA-53>libuv: Ben Noordhuis master * r06b83e0 / src/unix/stream.c : unix: avoid unnecessary read() syscall - http://git.io/yiyYhw
00:10:14  <piscisaureus_>On my machine I can achieve another 5% speedup by applying various js optimizations
00:11:59  * creationix|workquit (Remote host closed the connection)
00:12:32  <bnoordhuis>piscisaureus_: like what?
00:13:03  <piscisaureus_>bnoordhuis: It'll need some careful review, but I'll commit it soon
00:13:12  <piscisaureus_>so you can test it
00:13:34  <bnoordhuis>cool
00:13:52  <ryah>i think we're getting there
00:14:55  <bnoordhuis>YES!
00:15:00  <bnoordhuis>5961.55 [#/sec] <- v0.4
00:15:16  <bnoordhuis>6495.24 [#/sec] <- master with many-writes-fix + http-hack
00:15:22  <bnoordhuis>owned!
00:15:23  <CIA-53>node: Bert Belder writefix2 * raac95e7 / (lib/buffer.js lib/http.js lib/net_uv.js): mess - http://git.io/KMX9zg
00:15:25  * piscisaureus_quit (Quit: Leaving.)
00:15:59  <piscisaureus>bnoordhuis: ryah: try writefix2
00:16:14  <piscisaureus>it's some experiments that give me +5%
00:16:14  <CIA-53>node: Ryan Dahl many-writes-fix * r822ac44 / (3 files in 3 dirs): Upgrade libuv to 06b83e0 - http://git.io/3YfF-w
00:16:42  <piscisaureus>the caveat: there may be some experiments that make it slower :-/
00:16:58  <piscisaureus>and it's a mess - I have no decent editor on my mac so I'll clean it up on windows
00:19:06  <ryah>v0.4.10
00:19:06  <ryah>6196.00
00:19:06  <ryah>6357.14
00:19:06  <ryah>6121.67
00:19:06  <ryah>many-writes-fix 822ac44
00:19:08  <ryah>6246.56
00:19:11  <ryah>6218.53
00:19:13  <ryah>6272.53
00:20:23  <bnoordhuis>piscisaureus: i don't see a speed-up
00:20:41  <bnoordhuis>well, maybe 0.5%
00:20:52  <bnoordhuis>could just be noise
00:20:59  <piscisaureus>hmm
00:21:06  <piscisaureus>I'll post the numbers
00:21:35  * piscisaureus_joined
00:21:43  <ryah>actually im still seeing the extra read with your fix ben
00:21:43  <ryah>kevent(4, 4305518112, 1) = 1 0
00:21:44  <ryah>read(16, "GET /bytes/123 HTTP/1.0\r\nHost: localhost:8000\r\nUser-Agent: ApacheBench/2.3\r\nAccept: */*\r\n\r\n\0", 65536) = 91 0
00:21:47  <ryah>write(16, "HTTP/1.1 200 OK\r\nContent-Type: text/plain\r\nContent-Length: 123\r\nConnection: close\r\n\r\nCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC\0", 208) = 208 0
00:21:51  <ryah>read(16, "\0", 65536) = -1 Err#35
00:21:54  <ryah>close(16) = 0 0
00:22:45  <piscisaureus_> 6998.66 <— writefix2
00:22:49  <piscisaureus_>fuck
00:22:52  <piscisaureus_>stupid mac
00:24:34  <bnoordhuis>ryah: yeah, hmm - i see it with single requests with curl but the number of error reads has dropped to zero with ab
00:25:49  <bnoordhuis>wait, no - still lots of read errors
00:26:11  <ryah>bnoordhuis: i think that if statement is in the wrong place
00:27:03  <bnoordhuis>ffs
00:27:05  <ryah>diff --git a/deps/uv/src/unix/stream.c b/deps/uv/src/unix/stream.c
00:27:05  <ryah>index a68d7a9..7de318e 100644
00:27:05  <ryah>--- a/deps/uv/src/unix/stream.c
00:27:05  <ryah>+++ b/deps/uv/src/unix/stream.c
00:27:05  <ryah>@@ -600,11 +600,11 @@ static void uv__read(uv_stream_t* stream) {
00:27:08  <ryah> } else {
00:27:10  <ryah> stream->read2_cb((uv_pipe_t*)stream, nread, buf, UV_UNKNOWN_HANDLE);
00:27:12  <ryah> }
00:27:15  <ryah>+ }
00:27:17  <ryah>
00:27:20  <ryah>- /* Return if we didn't fill the buffer, there is no more data to read. */
00:27:24  <ryah>- if (nread < buflen) {
00:27:26  <ryah>- return;
00:27:29  <ryah>- }
00:27:31  <ryah>+ /* Return if we didn't fill the buffer, there is no more data to read. */
00:27:34  <ryah>+ if (nread < buflen) {
00:27:36  <ryah>+ return;
00:27:38  <ryah> }
00:27:41  <ryah> }
00:27:44  <ryah> }
00:27:46  <ryah>sorry - i thought that was smaller
00:28:24  <bnoordhuis>i was thinking to myself "man, lots of if statements here - gotta make sure everything lines up" :/
00:30:29  <bnoordhuis>can i squash and force-push it?
00:32:07  <ryah>https://gist.github.com/d5095396f26c75b8cd84 <-- with the read fix
00:32:09  <ryah>bnoordhuis: sure
00:32:42  <ryah>looking good
00:32:56  * ryahgoes back to child_process.fork
00:33:20  <CIA-53>libuv: Ben Noordhuis master * r5816f2d / src/unix/stream.c : unix: avoid unnecessary read() syscall - http://git.io/eaO9FA
00:34:10  * luxigoquit (Remote host closed the connection)
00:36:02  <CIA-53>node: Bert Belder writefix2 * r11120fe / lib/buffer.js : Never mind about the buffer stuff - http://git.io/S3V5pg
00:36:17  <CIA-53>node: Ryan Dahl many-writes-fix * r626a258 / (3 files in 3 dirs): uv: upgrade to 5816f2d - http://git.io/WdpR5w
00:37:39  <ryah>./node test/pummel/test-net-write-callbacks.js 4.98s user 2.27s system 100% cpu 7.228 total
00:37:46  <ryah>:/
00:38:29  <bnoordhuis>way better than it used to be
00:38:34  <bnoordhuis>and we're still not batching writes
00:39:27  <ryah>~/attic/v0.4.12/bin/node test/pummel/test-net-write-callbacks.js 1.56s user 0.77s system 99% cpu 2.343 total
00:39:44  <ryah>true
00:40:11  <ryah>what about that nexttick flush patch?
00:40:35  <piscisaureus_>7136 7172  7131<—writefix2       6869 6954 6921 <— fix-many-writes
00:40:53  <piscisaureus_>you should be able to see it too :-(
00:41:03  <ryah>piscisaureus_: okay - im trying it
00:41:36  <piscisaureus_>oh btw I did string/12
00:42:37  <piscisaureus_>okay I agree it's not 5%
00:43:19  <piscisaureus_>wishful thinking probably
00:47:17  <ryah>https://gist.github.com/a4beba7a1cc9ce57d0cc
00:48:59  <ryah>questionable improvement
01:03:21  <ryah>v0.1.13: Requests per second: 4792.77 [#/sec] (mean)
01:05:58  * ericktquit (Quit: erickt)
01:09:32  <ryah>Requests per second: 5453.20 [#/sec] (mean)
01:09:35  <ryah>^-- 0.2.6
01:09:49  <ryah>i.e.
01:09:53  <ryah>we're getting better
01:10:01  <ryah>probably just V8 is getting better
01:10:03  <ryah>but whatever :)
01:13:18  <ryah>https://gist.github.com/1269191
01:13:48  <CIA-53>node: Bert Belder many-writes-fix * r59999c1 / (lib/http.js lib/net_uv.js): Some small optimizations - http://git.io/GdHiJA
01:16:43  <piscisaureus_>It can't get slower
01:16:48  <piscisaureus_>that's the whole point :-)
01:18:59  <ryah>well we've added a lot of features since v0.1.13
01:19:22  <ryah>it probably would be best to do that progress on linux/x86
01:23:26  <ryah>guys - we've ripped out the enitre platform into a library - and we've been able to make it faster
01:23:29  <ryah>this is great
01:24:09  <ryah>and added support for alien-OS at the same time
01:24:15  <ryah>er - windows
01:25:07  * brsonquit (Quit: leaving)
01:25:46  * piscisaureus_quit (Quit: Leaving.)
01:26:53  <piscisaureus>x86 is better indeed
01:27:21  <piscisaureus>v8 has been improved much for x64
01:30:42  <piscisaureus>so string concat and http hack is still coming up right?
01:30:45  <piscisaureus>bnoordhuis: ^ ?
01:34:16  <bnoordhuis>piscisaureus: yes
01:38:49  <bnoordhuis>i'm off to bed (and you should too, piscisaureus)
01:38:52  <bnoordhuis>sleep tight all
01:39:42  <piscisaureus>yes I am going too ... soon
01:40:50  * bnoordhuisquit (Read error: Operation timed out)
01:43:29  <piscisaureus>Requests per second: 5161.79 [#/sec] (mean)
01:43:51  <piscisaureus>^-- windows
01:44:13  <piscisaureus>bad, but not that bad
01:44:28  * AvianFlu_joined
01:44:30  <piscisaureus>(running ab locally)
01:44:41  * AvianFluquit (Ping timeout: 260 seconds)
01:46:58  <igorzi>piscisaureus: i would not put any weight into running ab locally
01:47:11  <piscisaureus>I don't :-)
01:47:21  <piscisaureus>but this is what naive people do
01:47:26  <piscisaureus>should I download wcat btw>
01:47:28  <piscisaureus>?
01:49:05  <igorzi>piscisaureus: do you have a cluster?
01:49:38  <piscisaureus>igorzi: you mean that server rack here in my bedroom?
01:49:39  * AvianFlu_changed nick to AvianFlu
01:49:44  <piscisaureus>oh hmm no it's not there
01:51:27  <igorzi>piscisaureus: i don't think wcat will be any useful then.. at some point i think you mentioned that you have a test cluster from rackspace...
01:51:45  <piscisaureus>igorzi: oh - that's just 2 machines
01:52:46  * AvianFluquit (Quit: Leaving)
01:52:57  <piscisaureus>igorzi: I think I can turn those off.. Haven't logged in for ages (the msft cluster is way better) and I am also leaving rackspace
01:56:53  <igorzi>piscisaureus: oh.. does that mean that you'll spend more or less time on node? :)
01:57:12  <piscisaureus>igorzi: it's going to stay the same
01:58:10  <igorzi>piscisaureus: are you going somewhere else? or just doing school?
01:58:24  <piscisaureus>igorzi: I im going to get paid by cloud9ide
01:59:03  <piscisaureus>igorzi: and I am also going to work on another project related to my graduation
01:59:10  <igorzi>piscisaureus: nice
02:00:29  <piscisaureus>igorzi: but for how long will you stay here?
02:00:44  <piscisaureus>I want to keep you for a while :-)
02:16:59  <igorzi>piscisaureus: don't know exactly, but i think/hope it'll be a while :)
02:17:58  <piscisaureus>nice
02:18:03  <piscisaureus>I am off
02:18:33  <igorzi>night
02:22:39  * piscisaureusquit (Ping timeout: 248 seconds)
02:39:30  <CIA-53>libuv: Igor Zinkovsky master * r012fc07 / (include/uv-private/uv-win.h src/win/fs-event.c): windows: fixes #193. Ensures that uv_fs_event deals with short and long names - http://git.io/KZfozQ
03:41:59  * ericktjoined
05:47:21  * ericktquit (Quit: erickt)
05:57:48  * creationixjoined
05:58:07  <creationix>uv timers are pretty cool
05:58:32  <creationix>can someone help me figure out how to implement the repl I/O using libuv?
05:58:47  <creationix>do I need to create a pipe on FD 0?
06:04:16  <creationix>or is the tty type better?
06:17:39  <ryah>creationix: uv_tty_open(0)
06:17:45  <ryah>that's stdin
06:17:53  <ryah>set it to raw mode
06:18:02  <ryah>then start parsing ANSI escape codes
06:18:25  <creationix>you mean uv_tty_init(0)
06:18:28  <creationix>?
06:18:31  <ryah>yeah
06:18:34  <creationix>thanks
06:18:45  <ryah>creationix: looking forward to this :)
06:18:53  <ryah>creationix: i think your lua thing is going to be awesome
06:19:00  <creationix>here's where we see if my inheritance works and I can call stream methods on the tty instance
06:19:07  <creationix>ryah: It's sure fun
06:19:19  <creationix>and lua has all sorts of posibilities that js doesn't really have
06:19:26  <ryah>yeah
06:19:33  <creationix>though it's not as web compatable
06:19:39  <ryah>i like lua a lot
06:19:44  <creationix>json arrays are particularly nasty
06:19:51  <ryah>i would have loved to do node in lua
06:19:58  <ryah>the whole js thing was too appealing though
06:20:05  <creationix>well, I'll do it for you :)
06:20:10  <ryah>good :)
06:20:27  <creationix>it won't be a node clone, but libuv with lua sugar that makes sense
06:20:32  <ryah>that's actually my secret hope with libuv :)
06:20:36  <ryah>yes
06:20:45  <creationix>the fs module in mine has coroutines built in
06:20:47  <ryah>do try to have a unified stream interface though
06:20:54  <creationix>yeah, the streams are nice
06:21:02  <creationix>I'll do that once I'm done binding uv
06:21:13  <creationix>it's not too big, should only take a day or two more
06:21:22  <ryah>+ 1
06:26:54  <creationix>lol, raw mode is crazy
06:26:59  <creationix>I'm going to try without it for now using rlwrap
06:27:06  <creationix>but that's how you got tab complete in node
06:27:10  <creationix>I see now
06:33:54  * isaacsquit (Quit: isaacs)
06:41:23  <creationix>ryah: if you ever get bored, you're welcome to hang out in #luvit
06:42:12  <creationix>normally it's a couple lua people and some random node user from russia
06:50:53  <creationix>ryah: sweet, non-blocking repl!
06:51:01  <creationix>best lua repl ever
07:04:50  <indutny>creationix: joined #luvit
07:04:57  <indutny>:D
07:05:09  <creationix>I see
07:10:05  <indutny>ryah: yt?
07:13:28  <ryah>indutny: yes
07:15:03  * creationixquit (Quit: creationix)
07:20:15  * creationixjoined
07:26:45  * creationixpart
07:36:46  * creationixjoined
07:36:52  <indutny>ryah: sorry :)
07:36:56  <indutny>I was away
07:37:04  <indutny>I'll look into that issues today
07:58:17  * CoverSlidequit (Read error: Connection reset by peer)
07:58:17  * CoverSli1ejoined
07:59:05  <ryah>indutny: also
07:59:06  <ryah>=== release test-debugger-repl ===
07:59:06  <ryah>Path: simple/test-debugger-repl
07:59:06  <ryah>Error: timeout!
07:59:06  <ryah>Command: out/Release/node /Users/ryan/projects/node/test/simple/test-debugger-repl.js
07:59:16  <indutny>k
07:59:18  <indutny>I'll take a look
07:59:26  <ryah>thanks
07:59:37  <indutny>going to open pull request for libuv stuff
07:59:57  <indutny>ryah: https://github.com/joyent/libuv/pull/214/files
08:01:47  <CIA-53>node: Ryan Dahl master * r471c570 / (6 files): uv_write2 uv_read2_start binding - http://git.io/spkvPA
08:01:47  <CIA-53>node: Ryan Dahl master * rf6d8895 / (2 files): mv test-child-process-spawn-node.js test/simple/test-child-process-fork.js - http://git.io/4r3ZDQ
08:01:47  <CIA-53>node: Ryan Dahl master * r08c12de / (4 files in 3 dirs): Upgrade libuv to 886b112 - http://git.io/OMfWJQ
08:01:48  <CIA-53>node: Ryan Dahl master * r26c5905 / (lib/child_process_uv.js src/node.cc):
08:01:48  <CIA-53>node: Reimplement child_process.fork
08:01:48  <CIA-53>node: Fixes test/simple/test-child-process-fork.js - http://git.io/3drUlg
08:01:48  <CIA-53>node: Ryan Dahl master * r51f7ba4 / (14 files in 6 dirs): Merge branch 'ipc-binding' - http://git.io/aB6hsw
08:02:19  <ryah>child_process.fork is back
08:02:29  <ryah>whew - that took a while
08:02:45  * mralephjoined
08:04:18  <indutny>:)
08:04:39  <indutny>are customFds working?
08:09:06  <ryah>indutny: should be
08:09:11  <indutny>it's such a pleasure to delete functions and definitions from platform_* files
08:09:11  <indutny>:D
08:09:23  <CIA-53>node: Ryan Dahl master * rd2ab314 / node.gyp : Turn off V8's -Werror in GYP - http://git.io/sR2GBw
08:09:37  <indutny>going to open pull req for node soon
08:09:44  <indutny>are you going to be around for 5-10 minutes?
08:09:52  <ryah>indutny: sure
08:09:57  <indutny>cool
08:11:54  <indutny>I'm not sure if I'm able to remove all unused header files for sunos and freebsd
08:12:07  <indutny>but I'll remove them for windows, linux and darwin
08:24:12  <indutny>ryah: https://gist.github.com/817aeafe93c3fbb53972
08:24:13  <indutny>on windows
08:25:32  <indutny>I think it's declared somewhere after
08:25:47  <indutny>as it comes from win/winsock.h
08:28:43  * creationixquit (Ping timeout: 256 seconds)
08:28:45  <indutny>ryah: https://github.com/joyent/node/pull/1838
08:29:02  <indutny>brb
08:30:53  <CIA-53>node: Ryan Dahl master * rb413c77 / (3 files in 3 dirs):
08:30:53  <CIA-53>node: Support sending handles to other processes
08:30:53  <CIA-53>node: Needs test. - http://git.io/ivZGXg
08:33:19  <ryah>indutny: thanks
08:33:38  <indutny>you can pull this as it's already working
08:33:42  <indutny>if you think we need it
08:33:46  <indutny>but I can remove all headers
08:33:50  <indutny>and we may pull this later
08:34:39  <CIA-53>node: Fedor Indutny master * r6984553 / (9 files): use uv for memory and loadavg functions - http://git.io/YdYpfg
08:34:40  <CIA-53>node: Fedor Indutny master * r4561d9e / src/node_os.cc :
08:34:40  <CIA-53>node: Don't check sign of loadavg
08:34:40  <CIA-53>node: Fixes #1838 - http://git.io/j6oGLg
08:34:54  <ryah>indutny: we can remove all the headers once all functions are in libuv :)
08:36:05  <indutny>ok :)
08:36:09  <indutny>woot
08:36:32  <ryah> 9 files changed, 10 insertions(+), 270 deletions(-)
08:36:34  * ryahlikes that
08:36:58  <indutny>:)
08:37:06  <indutny>remove more, write less
08:39:06  <indutny>ryah: btw, updated that libuv preq
08:39:17  <indutny>https://github.com/joyent/libuv/pull/214
08:41:50  <CIA-53>libuv: Ryan Dahl master * r1c72aeb / src/unix/process.c : unix: IPC stdio stream should be duplex - http://git.io/1jvNgA
08:41:51  <CIA-53>libuv: Fedor Indutny master * r5ac0400 / include/uv.h : better docs - http://git.io/NZew2A
08:41:55  <indutny>great
08:48:42  <ryah>thanks for the better docs
08:49:06  <indutny>ohh :)
08:49:10  <indutny>you're welcome
08:49:17  <indutny>that was really simple
08:50:37  <indutny>ryah: test-debugger-repl works for me
08:55:38  <ryah>sometimes when i do
08:55:39  <ryah>./node test/simple/test-debugger-repl.js >& /tmp/asdfsd
08:55:44  <ryah>it pauses a little
09:01:06  * mralephpart
09:01:14  * mralephjoined
09:06:57  <indutny>strange
09:49:34  <indutny>fck
09:49:44  <indutny>ryah: can I ask you to help me with some C/C++ stuff?
09:49:48  <indutny>one simple question, actually
09:50:14  <indutny>I've one lib with header file where many functions has `namespace` as argument value
09:50:30  <indutny>and I need to create wrapping C++ lib for it
09:50:42  <indutny>but I can't include that header
09:50:51  <indutny>because of C++ parser errors
09:51:01  <indutny>is there anything I can do with it?
09:51:07  <indutny>or just delete it and do something else :D
10:28:22  <ryah>indutny: you need
10:28:22  <ryah>#ifdef __cplusplus
10:28:22  <ryah>extern "C" {
10:28:23  <ryah>#endif
10:28:41  <indutny>in those libs?
10:29:07  <indutny>should this be in each ".h" and ".c" file?
10:32:36  * piscisaureus_joined
10:32:59  <ryah>indutny: .h
10:33:13  <piscisaureus_>mornin
10:33:14  <indutny>doesn't seem to work...
10:33:19  <indutny>morning
10:33:28  <ryah>indutny: what's the error?
10:33:43  <indutny>ryah: 'error: expected ‘,’ or ‘...’ before ‘namespace’'
10:33:58  <ryah>and the context
10:34:23  <indutny> dom_exception (*dom_node_lookup_prefix)(dom_node_internal *node,
10:34:23  <indutny> dom_string *namespace,
10:34:23  <indutny> dom_string **result);
10:34:31  <indutny>*namespace line
10:34:31  <indutny>:D
10:34:40  <piscisaureus_>if it's just a header file, then `#define namespace foobar` does it :-)
10:34:53  <indutny>nope
10:34:56  <indutny>it's in C too
10:34:59  <indutny>but....
10:35:01  <indutny>it's brilliant :D
10:35:08  <indutny>let me try
10:35:22  <piscisaureus_>no, you just need to do that when you include the header in c++
10:35:27  <indutny>#define namespace gfckyrself :D
10:35:48  <ryah>indutny: oh, i see :)
10:35:51  <piscisaureus_>it could break though if you have struct members called `namespace`
10:35:51  <indutny>that's really what I wish that lib developers
10:36:07  <ryah># define namespace ns
10:36:13  <ryah>#include <something.h>
10:36:20  <ryah>#undef namespace
10:36:22  <indutny>yeah
10:36:25  <indutny>thank you!
10:36:40  <ryah>CPP FTW
10:36:49  * piscisaureus_quit (Client Quit)
10:36:52  <indutny>yeeeaahh
10:36:55  <indutny>it wooorks
10:36:57  <indutny>omg
10:37:00  <indutny>it's impossible
10:37:02  <indutny>:D
10:37:05  <indutny>thank you
10:37:53  * piscisaureusjoined
10:39:45  <piscisaureus>ryah: did you get the ipc wrap to work?
10:39:50  <piscisaureus>I want to try it on windows
11:04:13  <ryah>piscisaureus: yes
11:04:26  <CIA-53>node: Ryan Dahl master * r899358e / (6 files in 4 dirs): Add test-child-process-fork2 and fixes to make it work - http://git.io/lwV_rw
11:04:30  <ryah>piscisaureus: try it with this--^
11:04:50  <ryah>you should get:
11:04:50  <ryah>% ./node test/simple/test-child-process-fork2.js
11:04:50  <ryah>PARENT send child server handle
11:04:51  <ryah>CHILD got message: { hello: 'world' }
11:04:52  <ryah>PARENT got message: { gotHandle: true }
11:04:58  <ryah>%
11:05:47  <ryah>still needs a test where it listens and accepts connections
11:05:55  <ryah>but i think i should go to sleep.
11:17:23  <piscisaureus>ryah: yes you should :-)
11:17:32  <piscisaureus>Don't go down the same way as I did
11:27:12  * bnoordhuisjoined
11:40:16  <piscisaureus>woor
11:40:20  <piscisaureus>woot! it works
11:45:44  <bnoordhuis>piscisaureus: what works? your woman?
11:48:00  <piscisaureus>bnoordhuis: :-/
11:48:50  <bnoordhuis>it's always fun when bnoordhuis is around
11:49:05  <bnoordhuis>what are you working on, piscisaureus?
11:49:11  <piscisaureus>bnoordhuis: nothing
11:49:21  <piscisaureus>bnoordhuis: I was just testing fd passing in node on windows
11:50:14  * Marakjoined
12:22:50  <piscisaureus>Awesome
12:24:08  <piscisaureus>I can actually distribute load across different nodes on windows
12:24:12  <piscisaureus>:-)
12:24:25  <piscisaureus>There is a few bugs though -
12:24:45  <piscisaureus>the child receives a raw Wrap object instead of a Socket
12:25:15  <piscisaureus>and there is currently no way to prevent Server.Listen from attempting to bind() the received socket - so you'll get EINVAL
12:25:23  <piscisaureus>apart from that It Just Works
12:25:44  <piscisaureus>ryah: ^
12:41:25  * piscisaureusquit (Quit: ~ Trillian Astra - www.trillian.im ~)
12:41:59  * piscisaureus_joined
13:02:46  * piscisaureus_quit (Quit: Leaving.)
13:04:20  * piscisaureusjoined
13:54:06  <CIA-53>libuv: Bert Belder master * r81c09cb / src/win/error.c : win: add error mappings for ECONNRESET - http://git.io/oA5U1g
14:01:45  <piscisaureus>hey bnoordhuis
14:01:49  <piscisaureus>wanna send a photo?
14:02:13  <bnoordhuis>piscisaureus: for the bio?
14:02:26  <piscisaureus>bnoordhuis: yeah
14:02:41  <piscisaureus>bnoordhuis: it's about time.
14:02:48  <piscisaureus>bnoordhuis: the conference is next week :-)
14:03:23  <bnoordhuis>i'll have to delegate this to my secretary
14:03:30  <bnoordhuis>(i.e. my girlfriend)
14:03:32  <piscisaureus>bnoordhuis: do it quickly
14:03:35  <piscisaureus>you have 30 minutes
14:03:55  <piscisaureus>I want this Node.JA (sic) hackers to go away
14:04:02  <piscisaureus>so we have to come up with something
14:04:09  <piscisaureus>before the weekend
14:05:27  <bnoordhuis>my secretary is on the case
14:24:28  * CoverSli1echanged nick to CoverSlide
14:38:31  * mralephquit (Read error: Connection reset by peer)
14:58:22  <piscisaureus>bnoordhuis: how is it going with your secretary
15:04:14  * ericktjoined
15:23:13  * mralephjoined
15:35:31  * isaacsjoined
15:38:31  * ericktquit (Quit: erickt)
15:51:26  * ericktjoined
15:56:12  <piscisaureus>igorzi: yt?
16:03:24  <erickt>Good morning everyone. I'm considering turning uv_udp into a uv_stream_t, since I can use a udp socket with send assuming I use connect
16:04:13  <erickt>Plus I can then let getaddrinfo generically handle the configuration for me
16:05:09  * ericktquit (Quit: Page closed)
16:06:29  * creationixjoined
16:06:43  * ericktjoined
16:07:35  * creationixquit (Client Quit)
16:16:47  <indutny>morning everyone
16:16:57  <indutny>can I ask for WAF advice?
16:17:10  <indutny>I've built static library
16:17:12  <indutny>"lib.a"
16:17:27  <indutny>how can I link it with WAF?
16:17:45  <indutny>actually, how can I extend linker's options?
16:17:54  <piscisaureus>look for LINK_FLAGS or something
16:18:06  <piscisaureus>for windows we're adding ws2_32.lib etc
16:18:25  <piscisaureus>so if you search for ws2_32 in the wscript file you'll figure it out
16:20:48  <indutny>ah
16:20:49  <indutny>great
16:20:51  <indutny>thank you
16:23:25  <erickt>Is libuv switching to waf instead of gyp?
16:23:35  <indutny>nope
16:23:39  <indutny>erickt: that's for my own purposes
16:23:48  <indutny>just spamming channel :D
16:23:49  <indutny>sorry
16:27:14  * creationixjoined
16:27:30  <piscisaureus>erickt: we would never do that
16:27:39  <piscisaureus>we are happy to move away from node
16:35:36  * ericktquit (Ping timeout: 252 seconds)
16:39:35  <piscisaureus>er, to move away from waf for node
16:44:54  <creationix>piscisaureus: lol
16:45:08  <creationix>I didn't see the conversation before, but that was concerning
16:52:03  <indutny>oh
16:52:06  <indutny>Makefiles
16:52:15  <indutny>why so serious?
16:54:15  <creationix>hmm, read2 and write2 are for fd passing to child processes?
16:54:30  <piscisaureus>yes
16:55:03  <creationix>nice, I'll have to figure that out later
16:55:07  <creationix>does it work no windows?
16:55:12  <creationix>*on
16:55:25  <piscisaureus>yes
16:55:31  <creationix>cool
16:56:33  <piscisaureus>creationix: you can only pass listening server handles though
16:56:44  <creationix>ok
16:56:48  <piscisaureus>creationix: anything else is not supported atm
16:57:03  <piscisaureus>creationix: we could add that though - but we didn't really see the need so far
16:57:19  <creationix>I'm wrapping spawn in luvit now, just trying to understand what I'm wrapping
16:57:30  <piscisaureus>:-)
16:57:33  <piscisaureus>agreed
17:00:42  <creationix>once I'm done wrapping the surface area of uv, someone needs to look at my code and tell me where I'm doing things stupid
17:00:57  <creationix>I'm quite new to writing C and C++
17:01:09  <creationix>valgrind has been my friend
17:02:23  <CIA-53>node: Bert Belder * r8fbfa70 / deps/uv/src/win/error.c : win: add error mappings for ECONNRESET - http://git.io/_wCvfQ
17:02:23  <CIA-53>node: Bert Belder * r2752b75 / lib/net_uv.js : Black hole tcp reads after destroy() - http://git.io/MBvrTg
17:02:33  <indutny>why I'm getting undefined symbol errors
17:02:38  <indutny>I'm sure that it was linked
17:03:32  <igorzi>piscisaureus: hey
17:03:59  <CIA-53>node: Bert Belder * rfcad5e3 / lib/net_uv.js : Black hole tcp reads after destroy() - http://git.io/29pTFg
17:04:16  <piscisaureus>igorzi: so having 32 pending accepts isn't great for multiprocess sockets
17:04:45  <piscisaureus>igorzi: because the second process will not accept anything before the first 32 accepts are used
17:04:46  <igorzi>piscisaureus: hmm, why?
17:06:01  <igorzi>piscisaureus: hmm
17:06:44  <igorzi>maybe that should be 32 / number_of_procs?
17:06:53  <piscisaureus>igorzi: that's not the problem
17:06:58  <piscisaureus>igorzi: it's an ordering issue
17:08:00  <igorzi>piscisaureus: is that really an issue though? if we have 8 processes - we'll have 4 accepts in each process.. does it really matter that the1st 4 accepts will go to the 1st process?
17:09:00  <piscisaureus>igorzi: I did multiprocess accept with node
17:09:13  <piscisaureus>ab -c 100 and it'll nicely distribute all incoming stuff
17:09:31  <piscisaureus>but with ab -c 10 1 process takes everything
17:09:47  <piscisaureus>this is with artificially blocking the event loop
17:09:56  <piscisaureus>(for 100ms on every request)
17:14:32  <igorzi>piscisaureus: i don't know.. i still think we need multiple pending accepts.. maybe just make it dynamic so that it can be adjusted with multi-proc scenarios
17:15:10  <piscisaureus>igorzi: I think it's okay but we have to make the order somewhat random
17:15:29  <piscisaureus>so that the order of queued accepts doesn't become aaaabbbbccccddddaaaabbbbccccdddd
17:15:54  <piscisaureus>igorzi: maybe start off with one, but after the accept returns post back 2
17:16:12  <piscisaureus>until. the total number of accepts is 32
17:16:48  <creationix>Is there a way to be notified when loadavg changes?
17:16:51  * bnoordhuisquit (Ping timeout: 258 seconds)
17:16:54  <creationix>it seems roughly every 4000ms
17:16:56  <piscisaureus>no
17:17:12  <piscisaureus>it's probably os-dependent
17:17:22  <creationix>ok, setInterval it is
17:17:26  <piscisaureus>:-)
17:19:45  <igorzi>piscisaureus: yeah, that'll probably work.. start with 1, and keep increasing when connections are accepted for all pending accepts
17:20:58  <piscisaureus>yeah
17:21:01  <igorzi>piscisaureus: but, then does it need to scale down? (if there's a spike for example)
17:21:13  <piscisaureus>hmm
17:21:25  <piscisaureus>I can't really imagine how that happens
17:21:53  <piscisaureus>maybe it would if one process takes a very long request but the other gets fast ones.
17:22:14  <piscisaureus>hmm
17:24:26  <rmustacc>creationix: It's not even probably os-dependent, it is. Each OS has a different way, especially because they somtimes have logarithmic decay
17:24:58  <creationix>right, which is why I was hoping someone had already solved this
17:25:09  <creationix>I guess polling and looking for changes isn't the worst thing in the world
17:25:24  <creationix>just a little latency
17:25:27  <piscisaureus>igorzi: I kind of think that just 1 simultaneous accept is just fine in case of a shared socket
17:26:15  <piscisaureus>igorzi: in real-world situations you probably spend much more time per request and accept less connections per second
17:26:41  <igorzi>piscisaureus: so, http_simple is not a real-world situation?
17:26:51  <piscisaureus>so it's better to improve load balancing than to improve apache bench performance
17:27:00  <piscisaureus>igorzi: well, not in all respects
17:27:09  * creationixpart
17:27:22  <piscisaureus>igorzi: http_simple is the same response every time, and unusually small too
17:27:38  <igorzi>piscisaureus: a lot of decisions are made based on results of http_simple
17:27:52  <piscisaureus>heh
17:27:53  <piscisaureus>yes
17:28:00  <piscisaureus>that's a real-world situation
17:28:07  <igorzi>piscisaureus: http_simple ran almost 25% faster with 32 pending accepts
17:28:25  <piscisaureus>hmm
17:28:26  <piscisaureus>that's a lot
17:28:31  <igorzi>yeah
17:30:56  <igorzi>piscisaureus: maybe we can include some type of auto-tuning mechanism? basically start with 1 pending accept, and then auto-tune it based on how quickly the list of pending accepts fills up.
17:31:24  <piscisaureus>igorzi: well... sounds complicated :-)
17:31:50  <piscisaureus>igorzi: if you have a really awesome idea then +1 but otherwise I'm not sure
17:32:03  <igorzi>when the number of concurrent connections spikes, this'll go up to 32.. then when we notice that most of the 32 pending connections are just waiting.. we can scale it back..
17:33:12  <piscisaureus>igorzi: but I don't know exacly how we can determine if they're waiting
17:33:21  <piscisaureus>igorzi: you mean with HasOverlappedIoCompleted?
17:35:11  * AvianFlujoined
17:37:42  <igorzi>piscisaureus: hmm.. maybe we can base that off how many accept completion packets are returned from GQCSEx?
17:37:53  <piscisaureus>Let me think
17:38:03  <indutny>piscisaureus: can you help me?
17:38:09  <piscisaureus>it depends
17:38:12  <indutny>:)
17:38:20  <indutny>I've .node file
17:38:33  <indutny>that has dom_hubbub_parser_create string inside
17:38:38  <indutny>grep -R "dom_hubbub_parser_create" * reports that
17:38:48  <indutny>aaah
17:38:50  <indutny>nevermind
17:38:58  <indutny>it reports it because I'm trying to run this command
17:38:59  <indutny>k
17:41:57  <piscisaureus>igorzi: I think if we can randomize the process sufficiently we're going to be fine
17:42:58  <piscisaureus>is the call scheduled for 15 minutes btw or 1hr15m ?
17:43:48  * ericktjoined
17:44:13  <igorzi>piscisaureus: right now it's scheduled to be in 15 min
17:45:17  * AvianFluquit (Quit: Leaving)
17:45:29  <piscisaureus>ok cool, I can be there
17:45:37  * AvianFlujoined
17:46:47  <igorzi>piscisaureus: what do you mean by randomize the process?
17:47:19  <piscisaureus>igorzi: make sure that the queue of pending accepts is not too similar to aaaaaaaaaaaaaaaaabbbbbbbbbbbbbbbbb
17:47:23  * brsonjoined
17:47:31  <igorzi>piscisaureus: right, but how? :)
17:47:32  <piscisaureus>where a is an accept queued by process 1 and b is queued by process 2
17:47:53  <piscisaureus>yes, I'm thinking about that
17:47:54  <ryah>http://blog.nodejs.org/2011/09/30/node-v0-5-8/#comment-1149
17:48:00  <igorzi>(without sacrificing performance)
17:49:43  <igorzi>he probably doesn't have sp2
17:53:00  * creationixjoined
17:53:22  <creationix>is there a uv way to get environment variables, or is that normal portable C like argv?
17:54:28  <ryah>http://lists.cs.uiuc.edu/pipermail/llvmdev/2011-October/043719.html depresing
17:54:43  <ryah>creationix: extern char** envioron;
17:55:06  <creationix>ryah: I'm in normal C, not C++
17:55:08  <ryah>environ
17:55:10  <creationix>still the same?
17:55:19  <ryah>yes
17:55:23  <creationix>ok, so it's just a global, that works
17:56:48  <piscisaureus>hmm randomizing is maybe not the solution
17:56:53  <piscisaureus>igorzi: let's discuss at the call
17:57:18  <igorzi>piscisaureus: ok.. can you pls dial my number again? (this is the last time)
17:57:25  <piscisaureus>sure, fine
17:57:43  * AvianFlu_joined
17:58:16  <creationix>hmm, is getenv portable?
17:58:30  * AvianFluquit (Disconnected by services)
17:59:59  <piscisaureus>ryah: call now?
18:00:04  <piscisaureus>I will dial
18:00:12  <ryah>yeah
18:00:58  <piscisaureus>igorzi: call?
18:01:19  * AvianFlu_changed nick to AvianFlu
18:03:05  <igorzi>piscisaureus: eyp
18:03:07  <igorzi>yep
18:14:40  <indutny>piscisaureus: what is ".a" extension for?
18:14:43  <indutny>static library?
18:17:39  <indutny>can I use statically linked libraries in node extensions?
18:18:10  <rmustacc>indutny: It needs to be linked into the .so
18:18:35  <indutny>rmustacc: wouldn't it be shared library in that case?
18:19:54  <piscisaureus>igorzi: yeah benchmarks are everything :-/
18:20:16  <piscisaureus>meh benchmarks
18:20:29  * creationixpart
18:21:18  <rmustacc>indutny: Yes, but the way node extensions work is that you dlopen a shared object.
18:21:28  <indutny>rmustacc: yep, I understand
18:21:28  <rmustacc>So whatever shard object node-waf is generating needs to have your .a linked in.
18:21:55  <indutny>rmustacc: obj.env.append_value("LINKFLAGS", path + "/libdom.a")
18:22:00  <indutny>that's what I'm doing
18:22:05  <indutny>and it works partially
18:22:30  <indutny>but that lib is linked with another static lib :D
18:22:42  <indutny>and when it tries to execute method from it - it fails
18:22:48  <indutny>'undefined symbol'
18:23:03  <rmustacc>Well, then however your constructing the .a seems incorrect.
18:23:16  <rmustacc>A .a is really just a collection of object files, nothing really more.
18:23:18  <indutny>rmustacc: if I'll show you a repo - can you help me?
18:23:21  <indutny>rmustacc: yeah
18:23:34  <indutny>rmustacc: but can I create .a from .o and .a
18:23:41  <indutny>or not
18:24:00  <rmustacc>I don't recall off hand, I'd double check the ar man page.
18:24:09  <rmustacc>It sounds like the answer is no though.
18:24:21  <indutny>strange
18:24:26  <indutny>hm....
18:24:35  <indutny>so I need to create my own .a from all those .os?
18:24:37  <indutny>.o
18:25:02  <rmustacc>Or use a different invocation to ar.
18:25:43  <rmustacc>I've never really done much with static libraries.
18:26:13  <rmustacc>By design we much always use dynamic libraries, so you can guarantee interfaces.
18:26:44  <rmustacc>But it seems that it should be possible.
18:26:44  <indutny>wow
18:26:47  <indutny>it works
18:27:13  <indutny>yahooooo!!!!
18:27:16  <indutny>thank you
18:27:40  <indutny>I just created one .a from all .o files
18:39:07  * brsonquit (Ping timeout: 276 seconds)
18:42:40  <ryah>bbiab
18:59:44  <ryah>what are the current failing tests on windows?
19:06:39  <piscisaureus>the c-ares test hangs :-(
19:06:48  <piscisaureus>did we change anything about that?
19:07:26  * mralephquit (Quit: Leaving.)
19:07:59  <ryah>i just notice that too..
19:07:59  <piscisaureus>I have to go
19:08:11  <piscisaureus>also many tests crash
19:08:16  <ryah>later
19:08:31  <piscisaureus>it could be that we don't support redirected stdout yet on windows
19:08:55  <ryah>k
19:09:28  <piscisaureus>I will try to fix it later ...
19:09:31  <piscisaureus>gtg now
19:09:49  <piscisaureus>zu hause
19:10:51  * piscisaureusquit (Quit: ~ Trillian Astra - www.trillian.im ~)
19:22:07  * mralephjoined
19:33:28  * mralephquit (Quit: Leaving.)
19:34:44  <CIA-53>node: talltyler * r10f97f9 / lib/fs.js :
19:34:44  <CIA-53>node: Fixing #1774 about issues when running node with --harmony_block_scoping v8 option
19:34:44  <CIA-53>node: Fixes #1837. - http://git.io/JzeWWQ
20:20:36  * piscisaureusjoined
20:23:02  <piscisaureus>ryah: redirected stdout seems to be the problem when running tests. I am going to fix this in libuv now.
20:23:12  <piscisaureus>we can run the tests after that
20:23:38  <piscisaureus>Maybe we can dog-food the libuv test-runner as well :-)
20:31:09  <ryah>it'd be nice if we don't have recursive bugs in the test-runner
20:31:19  <ryah>also it's nice that it doesn't currently depend on libuv
20:31:30  <ryah>it hink it's usable for other projects
20:31:52  <piscisaureus>ok
20:32:02  <piscisaureus>well I wasn't in a hurry anyway
20:32:04  <ryah>japj: is having some issues with a pipe exception on windows
20:32:15  <ryah>https://github.com/joyent/node/issues/1840
20:32:28  <ryah>this might be a bug for igorzi
20:33:23  <piscisaureus>btw - don't wait for me if you want to do a release today
20:33:35  <ryah>ok
20:33:47  <ryah>piscisaureus: can we merge the speed improvement branch?
20:33:55  <piscisaureus>ryah: yes, that's fine
20:34:12  <piscisaureus>ryah: it works fine on windows
20:35:01  <ryah>ok
20:35:38  <piscisaureus>aah
20:36:01  <piscisaureus>I see what causes japj's problem
20:39:52  <piscisaureus>that's actually pretty bad
20:41:19  <CIA-53>node: Bert Belder * red65b7b / lib/net_uv.js : Simplify writeReq handling in net_uv - http://git.io/DP4acg
20:41:20  <CIA-53>node: Ryan Dahl * r29ec850 / lib/net_uv.js : Simplify arg parsing in String.write - http://git.io/4LTPhg
20:41:21  <CIA-53>node: Bert Belder * r153629c / (lib/http.js lib/net_uv.js): Some small optimizations - http://git.io/lAa5LQ
20:41:23  <CIA-53>node: Ben Noordhuis * r1bb820a / lib/net_uv.js :
20:41:23  <CIA-53>node: net: remove unconditional getpeername() call
20:41:23  <CIA-53>node: Speeds up http_simple benchmark by about 1.0% - http://git.io/0eVIjA
20:41:46  * piscisaureusbbl
20:46:39  * piscisaureusquit (Ping timeout: 248 seconds)
20:51:11  * AvianFluquit (Ping timeout: 260 seconds)
20:53:41  * AvianFlujoined
20:59:43  <CIA-53>node: Ryan Dahl * r26c08a3 / (4 files in 3 dirs): Do load balancing test in test-child-process-fork2. - http://git.io/gtvIKQ
21:01:15  <ryah>lunch. bbiab
21:33:05  * brsonjoined
21:54:02  <igorzi>ryah: fixing https://github.com/joyent/node/issues/1840.. should be done shortly
21:54:06  * AvianFluquit (Ping timeout: 255 seconds)
21:54:24  * AvianFlujoined
21:55:09  * brsonquit (Ping timeout: 260 seconds)
22:00:16  * isaacsquit (Quit: isaacs)
22:00:24  * piscisaureusjoined
22:05:27  <piscisaureus>ryah: igorzi: hey
22:05:35  <CIA-53>libuv: Igor Zinkovsky * r9f6024a / (4 files in 2 dirs): windows: fixes crash in pipe.c - http://git.io/TMzEtQ
22:05:36  <igorzi>he
22:05:37  <igorzi>hey
22:05:47  <piscisaureus>did you guys agree that uv_pipe_t.ipc is public?
22:06:03  <piscisaureus>it seems that node relies on it but uv-win doesn't touch it
22:06:33  <igorzi>piscisaureus: yeah, i just fixed it.. i didn't realize that it hung off public uv_pipe_t
22:06:49  <piscisaureus>ah ok
22:07:01  <piscisaureus>that's japj's bug that ryan mentioned earlier
22:07:15  <igorzi>yep, i just tracked it down too
22:07:40  <piscisaureus>ok cool
22:09:58  <igorzi>i also updated test-ipc to check for uv_pipe_t.ipc
22:10:13  <piscisaureus>cool
22:10:21  <piscisaureus>I'm upgrading libuv in node
22:21:07  <CIA-53>node: Ryan Dahl * ra23d8ad / (9 files in 5 dirs):
22:21:07  <CIA-53>node: Upgrade libuv to 9f6024a
22:21:07  <CIA-53>node: Fixes #1840 - http://git.io/T6fbXg
22:21:18  <piscisaureus>AMND
22:21:20  <ryah>piscisaureus: oops - sorry
22:21:27  * isaacsjoined
22:21:28  <piscisaureus>anyway
22:21:45  <piscisaureus>[04:28|% 100|+ 234|- 33]: Done
22:21:51  <piscisaureus>^-- windows
22:22:25  <piscisaureus>I am going to put it on google docs again
22:22:53  <ryah>piscisaureus: thanks
22:23:02  <ryah>we're down to 6 on unix
22:24:07  <ryah>i think i will attempt to port cluster to the new child_process.fork api this weekend
22:24:19  <piscisaureus>should not be too hard
22:25:15  * isaacsquit (Client Quit)
22:25:38  <ryah>fleet week in SF is annoying
22:25:45  <ryah>they fly figher jets of the city all day
22:25:52  * piscisaureusgoogles fleet week
22:26:02  <ryah>often above the sound barrier - it sets off all the car alarms
22:34:02  <igorzi>piscisaureus: so, we decided to benchmark the multi-proc server using the test cluster (with and without pending accepts), right?
22:34:11  <piscisaureus>igorzi: yeah
22:34:20  <piscisaureus>I want to make an informed decision
22:35:41  <igorzi>piscisaureus: i can run that..
22:35:56  <igorzi>piscisaureus: can you send me the js code?
22:36:17  <piscisaureus>eh, well
22:36:19  <piscisaureus>no
22:36:27  <piscisaureus>I lost it due to dropbox going haywire
22:36:40  <piscisaureus>but it's very easy to create so I can do that
22:36:51  <igorzi>piscisaureus: ok
22:37:22  <piscisaureus>igorzi: its just simple/test-child-process-fork2.js and test/fixtures/fork2.js
22:37:40  <igorzi>piscisaureus: ok, thanks
22:38:12  <piscisaureus>igorzi: I added created an extra tcp server and sent that
22:38:30  <piscisaureus>igorzi: but I had to hack up node somewhat, maybe you should wait for ryah fixing it
22:38:52  <piscisaureus>(basically net.js tries to bind a shared socket again, which fails)
22:40:13  <ryah>that should be fixed now
22:40:43  <ryah>test-child-process-fork2.js has a load balancing example
22:41:30  <igorzi>yep, got it
22:46:01  <piscisaureus>igorzi: ryah: errors sheet is updated
22:48:18  <erickt>Would anyone be interested in a patch that removes "-mmacosx-version-min=10.4" from the common.gypi? It's causing the gyp build on osx to break
22:49:48  <erickt>the problem is that the kqueues support for watching file events requires 10.6, but we'll never use it because we're compiling for 10.4 compatibility
22:52:03  * AvianFlu_joined
22:54:00  * AvianFluquit (Disconnected by services)
22:54:03  * AvianFlu_changed nick to AvianFlu
22:54:16  <igorzi>piscisaureus: can you pls send the pointer to the errors sheet again?
23:01:30  <igorzi>piscisaureus: ryah: i'm probably missing something simple, but is there a way to create http server given a net server (in the child process)?
23:03:29  <piscisaureus>igorzi: what I did is:
23:03:29  <piscisaureus>var server = net.createServer(function() { ... });
23:03:29  <piscisaureus>server._handle = whatever_was_received;
23:03:29  <piscisaureus>server.listen(80);
23:03:37  <piscisaureus>igorzi: but ryah may have changed it a little
23:04:05  <piscisaureus>Imho we should not give the user a raw handle but a suitable stream type instead
23:11:37  * brsonjoined
23:25:08  <ryah>igorzi: i haven't thought of how to make an http server yet
23:25:12  <ryah>igorzi: but i'll do that now..
23:26:56  <piscisaureus>hmm. I now realize that my answer was totally inadequate
23:27:02  <piscisaureus>sorry
23:28:05  <piscisaureus>ryah: igorzi: maybe it is not a bad idea to give the raw wrap to the user after all
23:28:37  <piscisaureus>and the user should just do (new Server).listen(wrap);
23:28:49  <ryah>yeah..
23:28:52  <piscisaureus>although it may be painful to explain what a wrap is
23:28:56  <ryah>piscisaureus: i think that's a good idea
23:29:02  <ryah>piscisaureus: we can just call it a handle
23:29:27  <piscisaureus>ryah: the only gotcha for users is that you send a stream and then receive a handle
23:30:00  <ryah>this will all be wrapped up with a better API anyway
23:30:22  <ryah>trying to guess if the recved handle is an http server or tcp server is painful...
23:30:29  <piscisaureus>yeah
23:31:30  <ryah>piscisaureus: did you post the link to the error spreadsheet?
23:31:35  <piscisaureus>I would be tempted to expose a stream.getHandle() function but I don't want users messing with that
23:31:39  <piscisaureus>ryah: docs.google.com
23:31:52  <ryah>oh thanks
23:32:33  <igorzi>piscisaureus: but your code (that you pasted above) should also work with http server, shouldn't it?
23:32:52  <piscisaureus>ryah: you'd need a 2-layered approach
23:33:34  <piscisaureus>Something like
23:33:34  <piscisaureus>server = http.createServer(...)
23:33:34  <piscisaureus>server.socket = server.connection = received_stream
23:33:34  <piscisaureus>server.listen(80);
23:33:39  <piscisaureus>er
23:33:46  <piscisaureus>igorzi, not ryah ^
23:34:26  <igorzi>currently, it's a handle that gets received, right? so server._handle should work for now?
23:34:47  <piscisaureus>I don't know, ryah changed that
23:35:10  <piscisaureus>igorzi: in the end `http_server.socket._handle` needs to be set
23:35:25  <ryah>igorzi: let me change the api around a bit
23:36:03  <igorzi>k, i'll wait
23:42:28  <igorzi>ryah: piscisaureus: ctrl+c doesn't stop node anymore
23:42:31  <igorzi>is it known?
23:42:44  <piscisaureus>hmm
23:45:36  <CIA-53>node: Ryan Dahl * r12486a6 / (4 files in 3 dirs):
23:45:36  <CIA-53>node: Change API for sending handles
23:45:36  <CIA-53>node: Does not support sending net.Server objects only raw TCPWrap objects. - http://git.io/iKti2w
23:45:37  <ryah>igorzi: --^
23:46:13  <ryah>igorzi: child.send(msg, httpserver._handle)
23:46:48  <ryah>igorzi: process.on('message', function(msg, handle) { var s = new http.Server(); s.listen(handle); }
23:49:59  <ryah>https://github.com/joyent/node/issues/1813 <- ctrl+c
23:52:07  <piscisaureus>igorzi: ctrl+break twice will also kill it
23:52:16  <piscisaureus>igorzi: but yeah, this should be fixed
23:57:29  <piscisaureus>igorzi: here's the culprit: https://github.com/joyent/node/blob/master/src/node.cc#L2407