[00:01] tk: ahah [00:02] charlesjolley has joined the channel [00:08] mikeal: _ry: that would rock [00:08] mikeal: you should send that suggestion to the list :) [00:09] mikeal: all the other suggestions got implemented by random people within a few days [00:09] _ry: there are few tasks pending :) [00:16] tlrobinson_ has joined the channel [00:16] tk: hmm so... xml2json == very basic... wonder if there is a better one (or even just an XML parser that returns objects) [00:19] tk: think its time to eat some food though so I Can take next round of meds [00:19] brianmario has joined the channel [00:20] phazm has joined the channel [00:20] phazm: is there a stable version of node.js compatible with cygwin? [00:20] auser has left the channel [00:23] kkaefer: when calling response.end(); on a http server response object, what events are fired on response? [00:23] kkaefer: neither close nor end seem to fire [00:24] creationix_ has joined the channel [00:25] devinus: _ry: that's so weird. i was totally thinking about pigz and node the other day [00:25] keeto has joined the channel [00:26] tk: or not... folks are on their way up here for dinner too so... found some snacks :) [00:30] _ry: phazm: nop [00:31] phazm: thank you _ry [00:31] _ry: but if i had a window vm i'd compile it [00:31] _ry: i'm sure it's just a line or two [00:31] _ry: to fix [00:31] phazm: I've never had success with compiling -- could be an issue with my cygwin install -- I'm just going to set up a linux VM [00:32] _ry: phazm: what are the errors [00:33] phazm: 1s, I'll try to make node [00:34] JimBastard has joined the channel [00:34] cloudhead: is there a way to do a glob from within node? something like '**/*' [00:34] cloudhead: or should I use a child process [00:35] cloudhead: I guess I could just recursively traverse with fs.readdir [00:36] CIA-75: node: 03Ryan Dahl 07master * r20372d2 10/ src/node_file.cc : Fix docs in node_file.cc - http://bit.ly/bLRlOS [00:36] CIA-75: node: 03kriskowal 07master * r8d1f118 10/ src/node_buffer.cc : Fixed/Completed buffer copy range checks. - http://bit.ly/c8QpPv [00:37] phazm: http://pastebin.com/8uxid6Nk [00:38] _ry: hm [00:38] kkaefer: is it possible to listen to *all* events of an eventemitter? [00:38] _ry: i'll get a window vm soon and do it [00:38] keeto has joined the channel [00:38] _ry: kkaefer: no... [00:38] _ry: kkaefer: but would be cool [00:39] phazm: _ry: Don't spend the time, unless you really want to -- I need to get a *nix server up anyhow [00:39] _ry: phazm: i really want to [00:39] phazm: carry on then :) [00:47] devinus: _ry: could you go into a little detail about how you would make a node pigz library? i seriously may try my hand at it [00:48] _ry: devinus: eio_custom + pulling the guts out of pigz.c [00:48] _ry: it would be a c heavy project [00:49] kkaefer: the workflow to contribute to node.js is to fork on github, make changes and then? [00:50] _ry: apparently pigz links to libz (lame) [00:50] devinus: _ry: yeah... [00:50] _ry: kkaefer: make a test, ./configure --debug && make test-all [00:50] _ry: kkaefer: then send it to me [00:51] kkaefer: e-mail? [00:51] _ry: sure [00:51] kkaefer: ok [00:51] _ry: ry@tinyclouds.org [00:51] _ry: devinus: what do you think? [00:51] _ry: it would be a great project, i think [00:52] jwm: _ry: I want to take nodejs and embed it into browsers [00:52] jwm: maybe I can I do IPC I guess [00:52] jwm: I can* [00:52] _ry: jwm: ipc is good [00:52] devinus: _ry: yep, i'm going to start looking at the code [00:53] jwm: it's a bsd derived license, perfect for embedding :) [00:56] isaacs_ has joined the channel [00:57] kriskowal: hm. waf doesn't appear to install headers. is there a general solution to figuring out where headers are when building addons? [00:59] devinus: _ry: http://compression.ca/pbzip2/ [01:00] _ry: kriskowal: ? [01:00] _ry: devinus: compression lib should be compatibile with http compression [01:00] kriskowal: no? node's headers get dumped in /usr/include or /usr/local/include? [01:00] sztanpet has joined the channel [01:00] _ry: kriskowal: i think so [01:00] devinus: _ry: yeah, i was just sharing a link [01:01] _ry: kriskowal: node/node.h [01:01] kriskowal: oh, i see. they're in a node dir [01:01] kriskowal: so the paths are different when building externally. alright [01:01] _ry: yeah - that's probably not so good [01:02] kriskowal: it's fine. i just happened to be porting something that i had originally built into the node executable [01:02] kriskowal: might make a note [01:03] devinus: _ry: where can i learn about eio_custom ? [01:04] _ry: devinus: deps/libeio/eio.h [01:04] _ry: devinus: there are a few uses in src/*.cc [01:05] _ry: devinus: basically you give it two callbacks [01:05] _ry: one to do in the thread pool [01:05] _ry: the other to call when it's done [01:05] devinus: nice [01:05] _ry: you can also checkout orlandov's node-sqlite which uses it [01:05] _ry: http://github.com/orlandov/node-sqlite [01:07] _ry: devinus: the important thing to know is that no V8 functions can be used in the thread pool [01:07] _ry: V8 only can be touched from the main thread [01:08] _ry: so inside the thread pool it's pure calculations libz stuff [01:08] _ry: outside it's just - like calling the callback [01:09] _ry: devinus: btw - if you do this and learn about eio_custom [01:09] _ry: you should take some notes about what is confusing [01:09] _ry: and write some docs about it in docs/api.markdown [01:09] _ry: so that other people will know what to do [01:10] devinus: _ry: reading node-sqlite source right now ^.^ [01:10] _ry: node-sqlite is great [01:10] devinus: _ry: and i'm def going to do it now [01:10] _ry: maybe slightly too c++-y :) [01:11] keeto_ has joined the channel [01:11] _ry: devinus: don't use EventEmitter [01:11] _ry: the c++ EventEmitter [01:11] _ry: like node-sqlite does [01:11] _ry: do it the way node_file.cc does [01:11] _ry: sigh [01:11] _ry: i need to update my docs :) [01:12] noonat: _ry: the big switched callback you mean? [01:13] noonat: or just taking callback functions in general? [01:13] _ry: noonat: just taking callback functions in general [01:13] _ry: it's better to write a simple c++ binding [01:13] _ry: then have a more class-like js wrapper [01:14] _ry: i used to do most of node in c/c++ almost nothing in js [01:14] jwm: what is devinus trying to do [01:14] _ry: he's going to port pigz to node [01:15] jwm: neat [01:15] jwm: I've never used pigz : [01:15] jwm: :) [01:15] devinus: _ry: do you want this IN node for http gzip or as a module? [01:15] jwm: I wonder if there is a pbzip :) [01:15] _ry: devinus: make it first - if it's clean maybe [01:15] kkaefer: wrote a test: http://pastie.textmate.org/private/jf36qjknriijgb2vvyjig [01:15] kkaefer: but it hangs when executing [01:15] jwm: peanutbutterzip [01:15] _ry: devinus: not sure - i don't want to link to libz [01:15] kkaefer: what am I doing wrong? [01:16] devinus: _ry: ya, that kinda sucks [01:16] _ry: what'd i'd like is a 1000 line gzip implementation [01:16] _ry: mit licenced [01:16] _ry: that we could just throw in [01:16] jwm: why did you choose the mit license [01:16] jwm: and not just plain bsd [01:16] _ry: or bsd [01:16] jwm: actually I can't even tell the difference between the two [01:17] jwm: is there one? [01:17] _ry: i don't know [01:17] devinus: _ry: isnt the zlib license much like the mit licence ? [01:17] devinus: oh im an idiot [01:17] jwm: bsdl was first [01:17] jwm: hehe [01:17] _ry: devinus: i thought it was lgpl? [01:18] _ry: no, i guess not [01:18] devinus: _ry: http://www.zlib.net/zlib_license.html [01:18] devinus: _ry: why not just include zlib in deps ? [01:18] devinus: AND pigz [01:18] devinus: :D [01:18] _ry: it's half a MB [01:18] _ry: how about include zlib in your binding :) [01:18] devinus: alrighty [01:19] jwm: hehe [01:19] jwm: you can already compress content from node [01:19] jwm: I thought [01:21] _ry: static linking [01:21] _ry: i love it [01:21] jwm: damn it ry I only have 256mb on my server [01:21] _ry: jwm: this one is going to fork out work to node's thread pool [01:21] jwm: are you crazy [01:21] jwm: static linking :P [01:22] _ry: jwm: hd space or memory? :P [01:22] jwm: ahh are there many projects using the thread pool [01:22] jwm: is this to test workers? [01:22] jwm: or am I not making any sense [01:22] jwm: _ry: memory, just a joke [01:22] jwm: my server is just for dev work though [01:22] _ry: workers = processes, whole node instances [01:22] _ry: thread pool is internal usage only [01:23] jwm: ahh, what kind of uses are the threads for? [01:23] jwm: things that block for a long time [01:23] _ry: making blocking system calls non-blocking [01:23] _ry: or large calculations [01:23] jwm: I thought you used epoll for that [01:23] _ry: can you epoll on file fds [01:24] _ry: er [01:24] _ry: can't use epoll on file fds [01:24] _ry: and read() and write() are always blocking on file fds [01:24] _ry: (well - unless the fs has cached the data) [01:24] _ry: basically all file system operations are possibly blocking always [01:25] _ry: like ... readdir(3) [01:25] dacc: anyone know where i'd find the "html" module? trying to use express -- not sure where the require is coming from exactly. [01:26] devinus: _ry: where are you now [01:26] _ry: devinus: work [01:27] _ry: not working, obviously :) [01:27] devinus: _ry: where? [01:27] _ry: sf [01:27] devinus: _ry: for who i mean :) [01:27] _ry: joyent [01:27] devinus: ah [01:28] jwm: _ry: so you think using threads is the best method for that? [01:29] devinus: _ry: isn't joyent smart platform incapable of async ? [01:30] jwm: I guess using AIO would be too OS specific [01:31] _ry: jwm: yeah aio doesn't really work [01:32] _ry: devinus: ask konobi - he's the smart platform guy [01:32] robrighter has joined the channel [01:33] devinus: _ry: i don't suppose you'll be at txjs [01:33] _ry: no [01:34] tk: devinus: new job permitting, I shall be [01:35] devinus: tk: yay [01:35] tk: course I live in TX makes it easier :P [01:35] devinus: me too [01:35] tk: ahh where abouts? [01:36] tk: austin, nm :P [01:36] devinus: _ry: didn't you issue some kind of mochiweb challenge? i use erlang/mochiweb/webmachine at work, and i wanted to do a comparison [01:36] _ry: devinus: yeah bench it vs node [01:37] _ry: devinus: do some 'hello world' [01:37] _ry: ideally with 1 core, 2 cores, 4 cores :) [01:37] devinus: _ry: you do know how much of a flame-war this is going to cause on /r/programming and HN right ? /grin [01:37] _ry: to show mochiweb getting faster [01:37] _ry: but not fast enough :) [01:38] _ry: node's speed wont increase as you increase the cores [01:38] devinus: _ry: might want to use this too: http://code.google.com/p/misultin/ [01:39] _ry: oh yeah - that'd be good [01:39] devinus: im not going to start yet since nigz has my attn atm [01:40] devinus: i'm totally fucking going with that name too [01:41] _ry: haha [01:43] jwm: hi [01:43] jwm: oops [01:45] ditesh|cassini has joined the channel [01:47] devinus: O_CREAT [01:47] devinus: haha [01:47] devinus: that always cracks me up [01:47] devinus: like: SERIOUSLY guys? [01:48] mrjjwright has joined the channel [01:48] devinus: http://www.rit.edu/alumni/ihf/inductee.php?inductee=10 [01:48] devinus: oh thats super cool [01:49] mrjjwright: creationix: is it ok to nest flows in step? [01:50] _ry: misultin is worth [01:50] _ry: worthy [01:50] dekz has joined the channel [01:52] devinus: _ry: http://gregorycollins.net/posts/2010/03/12/attoparsec-iteratee [01:52] devinus: thats eye melting right there [01:53] inimino: Iteratee is awesome [01:53] inimino: actually attoparsec is too [01:54] devinus: _ry: "I'm getting 45k requests/second on my quad-core Linux box" [01:54] devinus: inimino: i remember you came from haskell [01:55] inimino: well, I learned JavaScript before Haskell, but I am a big Haskell fan :) [01:56] _ry: i feel like there has been a regression [01:56] _ry: since v0.1.92 [01:56] _ry: need to get 'hello world' benchmarks on the build bots... [01:59] devinus: google should buy HP [02:01] devinus: that would be impossible [02:09] keeto has joined the channel [02:12] _ry: yeah misultin definitely is handling concurrency better than node [02:15] rictic has joined the channel [02:16] Ned__: what's a good websocket implementation to use?, I quite like the one that sits on top of the http server [02:16] Ned__: but it looks like it's a bit busted [02:17] devinus: _ry: hey, that's what erlang is for [02:17] bmesh has joined the channel [02:18] devinus: _ry: if the fastest erlang http library performed worse than node on a multicore system then erlang would need a serious verbal beating [02:18] tmpvar has joined the channel [02:19] tmpvar: yo [02:20] _ry: http://gist.github.com/385977 [02:20] Dethe has joined the channel [02:20] _ry: i want to beat erlang though [02:20] _ry: pretty fucking tight - or? [02:20] _ry: their syscalls [02:21] tmpvar: looks tight [02:21] _ry: node looks really sloppy [02:21] _ry: what's with all those mmaps? [02:22] tmpvar: yeah, i was going to say. those are probably *fairly* heavy [02:22] _ry: and like 4 select calls in a row? [02:22] _ry: man.. [02:23] tmpvar: -1 Err#35 -- whats that? [02:23] bmesh: hi peeps. i've got a newb issue building the project on OSX Leopard if anyone's got a minute. [02:24] tmpvar: bmesh, go for it [02:24] _ry: tmpvar: on servers you loop and accept() until it errors out [02:24] _ry: looks like the erlang one does that too [02:24] tmpvar: oh, thats right [02:24] bmesh: in the linking phase: [02:24] bmesh: [67/67] cxx_link: build/default/src/node_4.o build/default/src/node_buffer_4.o build/default/src/node_http_parser_4.o build/default/src/node_net2_4.o build/default/src/node_io_watcher_4.o build/default/src/node_child_process_4.o build/default/src/node_constants_4.o build/default/src/node_cares_4.o build/default/src/node_events_4.o build/default/src/node_file_4.o build/default/src/node_signal_watcher_4.o build/default/src/node_stat_ [02:24] tmpvar: woah dude, gist that [02:25] tmpvar: gist the error even [02:25] bmesh: ld: warning: in /opt/local/lib/libssl.dylib, file was built for i386 which is not the architecture being linked (x86_64) ld: warning: in /opt/local/lib/libcrypto.dylib, file was built for i386 which is not the architecture being linked (x86_64) ld: warning: in /opt/local/lib/libz.dylib, file was built for i386 which is not the architecture being linked (x86_64) Undefined symbols: "_X509_STORE_CTX_init", referenced from: nod [02:25] bmesh: will do [02:26] bmesh: http://gist.github.com/385984 [02:26] bmesh: sorry bout that. [02:28] tmpvar: bmesh, going on on a limb here.. did you recently upgrade to snow leopard? [02:28] _ry: bmesh: hm your openssl was is 32 bit and node is trying to build 64 bit [02:29] bmesh: yes i did [02:29] tmpvar: s/on/out [02:29] _ry: bmesh: try to reinstall openssl [02:29] bmesh: okay. [02:29] tmpvar: i'd also get the latest xcode [02:29] bmesh: i'm def using the latest. [02:29] _ry: port upgrade openssl [02:30] tmpvar: _ry, good point. looks completely ssl related [02:35] ssteinerX has joined the channel [02:36] _ry: so the mmaps are cause by the GC [02:36] tmpvar: ah [02:37] _ry: which is okay because they happen after the close() [02:37] tmpvar: and more select()'s means a tighter loop? [02:37] _ry: so really it looks like this: http://gist.github.com/385977 [02:37] _ry: this is one http request [02:38] _ry: pretty much the same [02:39] _ry: as far as i can see erlang isn't using multiple threads or processes [02:40] _ry: oh nevermind [02:43] sevenmacaw has joined the channel [02:44] _ry: you know what's different! [02:44] _ry: erlang doesn't select() before responding [02:45] _ry: oh nevermind they do... [02:46] colin_ has joined the channel [02:47] _ry: oh well, nothing obvious [02:49] dacc has joined the channel [02:50] bmesh: _ry and tmpvar: thanks peeps i got it working. [02:50] tmpvar: slick [02:50] bmesh: really appreciate the help. [02:50] derbumi has joined the channel [02:55] saikat has joined the channel [02:58] tmpvar: _ry, how long is your talk on wed? [03:01] mjijackson has joined the channel [03:03] phazm: I can't figure out how to 'check out' node with git -- I tried 'git clone git://github.com/ry/node.git' but no go [03:04] tmpvar: hrm, do you have git? [03:04] phazm: heh, indeed :) [03:04] WALoeIII has joined the channel [03:04] tmpvar: are you getting an error? [03:04] phazm: ah [03:05] phazm: I have git, but no brain, it would seem [03:05] phazm: sudo. [03:05] tmpvar: ah [03:16] javajunky has joined the channel [03:16] phazm: /web/node/node/wscript:109: error: could not configure a cxx compiler! --- I have gcc and cmake installed. Any ideas? (ubuntu 9.10) [03:16] tmpvar: you need g++ [03:17] phazm: thank you [03:17] PyroPete1 has joined the channel [03:18] tmpvar: does anyone know of a ssjs compat layer/library? [03:18] quirkey has joined the channel [03:18] cadorn has joined the channel [03:18] tmpvar: ie: norwal / nodejs compat [03:21] JimBastard: yo rektide [03:21] tmpvar: hey thar JimBastard [03:21] JimBastard: can you please put up some docs for pipelayer :-( [03:21] JimBastard: http://github.com/rektide/pipe-layer [03:22] JimBastard: sup tmpvar [03:22] tmpvar: wtf is pipe-layer? [03:22] tmpvar: http://www.urbandictionary.com/define.php?term=pipe%20layer ? [03:24] phazm: Error: node.js not compiled with openssl crypto support. [03:24] sevenmacaw has left the channel [03:24] tmpvar: install openssl [03:25] tmpvar: openssl dev maybe? [03:25] phazm: Reading state information... Done [03:25] phazm: openssl is already the newest version. [03:25] phazm: Only other openssl packages are 'blacklist' 'blacklist-extra' and 'doc' [03:28] tmpvar: phazm, try apt-get install libssl-dev [03:30] phazm: installed, same error though, when 'sudo make test' [03:32] tmpvar: hrm [03:32] tmpvar: let me try [03:32] tmpvar: you on 10.04? [03:33] tmpvar: shouldnt really matter actually [03:34] phazm: upgrading to 10.04 lts [03:35] dacc has joined the channel [03:35] tmpvar: oh [03:35] tmpvar: did you rerun ./configure after you installed libssl-dev? [03:35] phazm: ah, no [03:35] tmpvar: that should fix [03:39] rictic has joined the channel [03:39] phazm: yep, thanks tmpvar [03:39] tmpvar: np [03:43] _ry: tmpvar: 1 hour [03:43] _ry: tmpvar: you? [03:43] tmpvar: 15 minutes [03:44] _ry: 15 minutes.. that's short :) [03:44] tmpvar: the dom really isnt a huge topic lol [03:44] _ry: maybe i should make mine shorter [03:44] tmpvar: thats my base allocation, I'll probably try to stick to it as I'm a presenting newb [03:45] phazm: where is this presentation being held? [03:45] tmpvar: nah, nodejs is pretty slick, the dom doesn't deserve more than 20 mins heh [03:45] tmpvar: http://www.yuiblog.com/blog/2010/04/27/cinco-de-nodejs/ [03:46] _ry: tmpvar: short talks are better [03:47] tmpvar: yeah, I wish I could fly out there to meet the peeps / present in person [03:53] phazm: looks like it's going to be an awesome presentation :) [03:53] mrjjwright has joined the channel [04:01] phazm: are there any open source projects using node.js, redis and comet [04:07] brainproxy has joined the channel [04:12] JimBastard: phazm comet is just a word [04:13] phazm: I am referring the the functionality -- the PUSH style ajax, if you will [04:13] JimBastard: theres pretty good nodejs and redis suport. then doing longpolling is easy as shit [04:13] JimBastard: websockets? or polling? [04:13] phazm: ... I don't know :-/ [04:13] JimBastard: +1 polling [04:13] JimBastard: whats your frontend library [04:14] phazm: in what sense? I generally use jQuery for a JS library [04:14] phazm: I'll be using CodeIgniter as a PHP library [04:14] JimBastard: +2 polling [04:14] JimBastard: got yeah, it should be pretty easy to set [04:14] JimBastard: get node running with redis first [04:15] phazm: working on that now :) [04:15] phazm: just have to learn how to work with node.... and redis... and I'll be set [04:15] JimBastard: once you do that just add some event listeners or something on your http request and hold that shit until a new resp is ready [04:15] JimBastard: there are some libs too [04:15] JimBastard: you should ready the wiki on the node repo [04:16] _ry: phazm: redis support in node is pretty good [04:17] phazm: JimBastard: http://wiki.github.com/ry/node/ ? [04:18] kriskowal_ has joined the channel [04:18] _ry: phazm: http://github.com/fictorial/redis-node-client is quite good [04:20] JimBastard: aye [04:21] phazm: I'll give it a shot, thanks :) [04:21] robrighter has left the channel [04:22] joshbuddy has joined the channel [04:22] joshbuddy has joined the channel [04:22] dacc has left the channel [04:24] boaz has joined the channel [04:26] softdrink has joined the channel [04:38] boaz has joined the channel [04:40] softdrink has joined the channel [04:43] softdrink has joined the channel [04:45] softdrink has joined the channel [04:47] keeto has joined the channel [04:47] Dethe has joined the channel [04:54] phazm: fantastic, got the test to work :) [04:59] softdrink has joined the channel [05:01] tmpvar: hrm [05:02] tmpvar: so much to do, where to start [05:02] tmpvar: _ry, I have to apologize for node-avro. I've been dreading it to be completely honest. [05:07] saikat has joined the channel [05:07] jedschmidt has joined the channel [05:08] phazm: hrm, subscriber.js is bombing -- 'cannot read property 'length' of undefined' [05:09] kriskowal: _ry is there anywhere you're using a value as a String/Buffer agnostic duck-type? [05:10] kriskowal: that is, anywhere that calling .slice() is expected to work regardless of type? [05:11] amerine has joined the channel [05:21] colin_ has joined the channel [05:28] isaacs has joined the channel [05:28] colin_ has left the channel [05:30] Dethe_ has joined the channel [05:30] _ry: kriskowal: no [05:31] _ry: kriskowal: but if you're doing that patch - could you please add a deprecation warning for .slice() ? [05:31] kriskowal: okay. please disregard that patch. [05:31] kriskowal: oh, i put "slice" back in as a copy-making variant. [05:32] fizx has joined the channel [05:32] _ry: kriskowal: ? [05:32] kriskowal: just like string [05:32] _ry: in binary/4? [05:32] _ry: er [05:32] _ry: f [05:32] kriskowal: in the patch i just mailed [05:32] JimBastard has joined the channel [05:33] kriskowal: it's in binary/f too, yes [05:33] _ry: oh i didn't see that [05:34] _ry: i think binary/f should explicitly have .copy instead of .slice [05:34] _ry: what do you think/ [05:34] kriskowal: i think both are useful [05:34] kriskowal: .slice is handy for ducktyping [05:34] _ry: hmm [05:35] kriskowal: .copy doesn't return a copy anyway. [05:35] _ry: but i can't imagine a situation where you'd wnat to ducktype that [05:35] siculars has joined the channel [05:36] kriskowal: the most interesting duck-typing for buffer would be .charCodeAt. there are some algorithms for things like base64 encoding that would work unchanged between browser and server if we tacked that on. [05:41] ditesh|cassini has joined the channel [05:41] softdrink has joined the channel [05:46] kriskowal has joined the channel [05:48] sztanphet has joined the channel [05:52] JimBastard: awesome my top secret project works [05:53] JimBastard: im gonna drink a whole lot more and blog about it [05:54] creationix: have fun [05:56] JimBastard: :-D [05:57] cloudhead: mattly: you around? [05:58] rauchg has joined the channel [06:00] sztanpet has joined the channel [06:04] Dethe has joined the channel [06:08] joshbuddy has joined the channel [06:10] JimBastard: hey guys [06:10] JimBastard: http://www.nodejitsu.com/ [06:10] JimBastard: http://demos.nodejitsu.com/ [06:10] JimBastard: cloudhead ^^ [06:11] sztanphet has joined the channel [06:11] JimBastard: why does heroku get to have all the fun? :-) [06:14] JimBastard: oops i just got yelled at i wasnt suppose to post that [06:14] JimBastard: ahaha [06:14] JimBastard: >.< [06:23] rauchg: JimBastard: i'm excited to hear Joyent's node offerings :) [06:24] JimBastard: lolwut [06:24] JimBastard: link> [06:25] rauchg: haha haven't heard anything but i'm sure they'll have something right ? [06:25] rauchg: :P [06:26] rauchg: i emailed the heroku guys to get access to the beta and they never responded :'( [06:27] piranha has joined the channel [06:36] sh1m has joined the channel [06:37] siculars has joined the channel [06:40] nsm has joined the channel [06:42] phazm has joined the channel [06:50] teemow has joined the channel [06:56] cloudhead: is it a new development, to throw exceptions when an 'error' event isn't caught? [06:56] JimBastard has joined the channel [07:10] towski has joined the channel [07:16] _ry: cloudhead: yes [07:17] steadicat has joined the channel [07:17] cloudhead: _ry: I see. I guess it makes sense in some scenarios. not in mine, as event listeners are optional [07:18] cloudhead: I think I sorted it out though by listening to 'newListener' [07:18] cloudhead: only if a listener listens to error, I emit the event [07:24] tk: hmm are there any good XML parsers that dont use removed/deprecated/broken code? :/ [07:25] JimBastard: there are a few [07:25] JimBastard: check the modules page [07:26] tk: I have -- the closest one to working... doesnt work with nodes-with-a-dash, [07:27] tk: on the last one now [07:30] riottaba has joined the channel [07:31] qFox has joined the channel [07:41] charlesjolley has joined the channel [07:42] charlesjolley has joined the channel [07:44] tlrobinson_ has joined the channel [07:51] teemow has joined the channel [07:53] Nohryb has joined the channel [07:57] JimBastard: mmmm seamlessweb [07:57] cloudhead: is stdout flushed on process.exit()? [07:57] JimBastard: at least im not ordering a whole cheescake again [07:57] cloudhead: because it seems like it is not [07:59] Nohryb has joined the channel [08:00] tk: JimBastard: whats wrong with a whole cheesecake? :P [08:00] JimBastard: its not advised [08:00] markwubben has joined the channel [08:00] JimBastard: egg sammich and sweet potato fries [08:01] tk: ACTION would much rather have the cheesecake over the sammich [08:02] SamuraiJack has joined the channel [08:06] tk: hmmm and sax-js... a parser that seems to rely on callbacks for everything.... no returned parsed objects or anything [08:06] JimBastard: it returns it eventually [08:07] N` has joined the channel [08:07] tk: hmm maybe I'm missing that in the example file then *goes back and looks* [08:07] saikat has joined the channel [08:08] teemow has joined the channel [08:12] Nohryb has joined the channel [08:31] tk: interesting... http://vtd-xml.sourceforge.net/technical/0.html [08:55] botanicus has joined the channel [09:02] Ned__: does the latest http server silently catch exceptions ? [09:02] Ned__: it seems that if I have an error, it quietly just stops processing the request, but I don't see anything :-( [09:17] hassox has joined the channel [09:19] Ned__: Ahhhh, found it [09:19] Ned__: it now emits clientError [09:19] Ned__: :-) [09:21] polo has joined the channel [09:23] maritz has joined the channel [09:27] ayo has joined the channel [09:34] micheil has joined the channel [09:34] polo: Did anyone succeed using the last version of node-mongodb-native ? [09:35] polo: I can't get any version greater than V0.6.7 work ! [09:37] micheil: _ry: I believe I've got something for you. [09:40] micheil: _ry: I'll email them as well across to you, but here's one: http://gist.github.com/386190 [09:40] micheil: and here's the second: http://gist.github.com/386193 [09:41] micheil: polo: on an old checkout it worked, not sure on releases [09:41] micheil: polo: lemme test in a minute [09:42] polo: Yeah same issue with the last checkout too [09:42] polo: I just run examples/blogs.js for instance [09:43] polo: TypeError: Cannot call method 'dropDatabase' of null [09:43] polo: and I have printed the error : { ismaster: 1, msg: 'not paired', ok: 1 } [09:45] N` has joined the channel [09:48] micheil: polo: sorry, just getting back to things after a two days out of office [09:49] polo: no problem [09:49] polo: thanks for helping [09:55] micheil: try running make test_all [09:56] micheil: because all those pass for me [09:56] polo: test works [09:56] polo: but not integrate_test [09:56] micheil: hmm.. not sure then [09:57] polo: it works for you ? [09:57] micheil: this is my output: http://gist.github.com/386205 [09:57] polo: yeah seems to work [09:58] micheil: try pulling or doing: git reset --hard HEAD [09:58] micheil: and also check mongodb for anything that might be causing issues [09:58] polo: I'm using mongo v1.5.1 btw [09:58] micheil: I'm on.. [09:58] micheil: 1.4.0 [09:59] polo: I'll try with that version then [09:59] polo: but I'd like to use the new $slice operator [09:59] micheil: I'll try with 1.4.2 (it's the latest on homebrew) [10:00] micheil: bbl [10:06] pdelgallego has joined the channel [10:08] hassox has joined the channel [10:16] polo: ok it's working with 1.4.2 [10:18] polo: http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-$sliceoperator [10:18] polo: I'll have to wait for it [10:20] tjgillies has joined the channel [10:20] tjgillies: i think this is the first channel ive been in with a period in the name. didn't even know you could do that [10:24] micheil_mbp has joined the channel [10:27] yatiohi has joined the channel [10:30] spoob has joined the channel [10:31] trochala has joined the channel [10:36] polo: also, is it possible to link my git repo with another one so that when I clone mine it also dowload the other one ? [10:37] polo: in other words: what is the good way to deploy a web app with express? [10:46] micheil: polo: sort of [10:46] micheil: polo: look up git submodules [10:49] polo: micheil: ok [10:54] polo: should I make express as a submodule or my app as an express submodule ? [10:54] Nohryb has joined the channel [10:57] Nohryb_ has joined the channel [10:57] polo: (yeah I don't really know how git works! if you have a good tuto...) [10:58] micheil: express should probably be a submodule in a directory called /vendor/ [10:58] micheil: I'm pretty sure it's a bit of a conventions [10:58] rednul has joined the channel [10:59] polo: ok micheil, thanks a lot, I'll try that [10:59] sveimac has joined the channel [11:12] maushu has joined the channel [11:16] inarru has joined the channel [11:19] inarru has joined the channel [11:28] kkaefer: I have this test: http://pastie.textmate.org/private/ferchuhef4bk2jndjl3kva [11:28] kkaefer: it *should* fail, but it doesn't [11:28] kkaefer: when I execute it as standalone, it fails [11:28] kkaefer: but not as part of the test suite [11:28] kkaefer: I'm pretty sure it's executed during the test suite (when I add syntax errors to the file, the test breaks) [11:28] kkaefer: what am I doing wrong? [11:30] kkaefer: it seems like the callback is never executed when I'm in the test environment [11:31] tjgillies: git is a filesystem [11:40] ivan has joined the channel [11:47] derferman has joined the channel [11:51] rauchg has joined the channel [11:56] mau has joined the channel [12:07] wereHamster has joined the channel [12:11] spoob: Even though I appreciate Promises, that was a good decision to remove them from Node [12:29] keeto has joined the channel [12:32] derbumi has joined the channel [12:42] teemow has joined the channel [12:47] ditesh|cassini has joined the channel [12:49] kriszyp has joined the channel [12:58] oogatta has joined the channel [13:04] MattJ has joined the channel [13:13] ssteinerX has joined the channel [13:16] jansc has joined the channel [13:21] voodootikigod has joined the channel [13:22] kkaefer: hmm, watchFile works with polling... [13:23] kkaefer: any plans to move that to fsevents? [13:24] kkaefer: (or inotify) [13:25] kkaefer: ah, inotify is actually used [13:25] kkaefer: but apparently not on os x [13:35] mjijackson has joined the channel [13:38] pjb3 has joined the channel [13:43] webben has joined the channel [14:03] jedschmidt has joined the channel [14:06] rolfb has joined the channel [14:13] robrighter has joined the channel [14:15] creationix: so, is there still a stable mongo driver for node? [14:15] micheil: I think so [14:16] micheil: I got mongo-native working [14:16] robrighter has left the channel [14:16] creationix: is that the one that's not compiled? [14:16] micheil: (well, passing all tests and blog.js running) [14:16] micheil: native js that one [14:16] creationix: sweet, heroku now had mongohq [14:16] creationix: *has [14:16] micheil: heroku, has mongohq? [14:16] micheil: since when? [14:17] micheil: mongohq is a separate service, or was last week. [14:17] micheil: fill me in, please [14:18] creationix: http://blog.heroku.com/archives/2010/4/30/mongohq_add_on_public_beta/ [14:18] creationix: very new [14:18] micheil: epic. [14:18] creationix: I've got my heroku node app running with the default postgres right now [14:18] creationix: now I want to test mongo [14:18] micheil: oh. man. talking to some people in #rubyonrails and they haven't heard of node.. :( [14:19] creationix: sweet, it's all in process.env.MONGOHQ_URL, that works :) [14:20] micheil: oh man. blown his mind over the whole serverside js thing. [14:26] micheil: woot. converted. [14:26] alex-desktop has joined the channel [14:27] jedschmidt has joined the channel [14:38] rolfb: anyone implemented Operational Transform on Node.js yet? [14:38] rolfb: :P [14:38] keyvan has joined the channel [14:49] Dethe has joined the channel [15:00] chuck has joined the channel [15:01] kriszyp has joined the channel [15:05] ssteinerX has joined the channel [15:10] Guest97922 has joined the channel [15:13] mau has joined the channel [15:16] boaz has joined the channel [15:17] dekroning has joined the channel [15:26] phazm: is there a 'cURL' equivalent in node? I want to get a tiny bit of HTML data every second from a site, trying to find the best way to do it [15:27] kkaefer: phazm: http://nodejs.org/api.html#http-client-167 [15:27] phazm: ahh, thank you [15:28] kkaefer: it's a bit more low level than cURL, though [15:28] phazm: do you know offhand if it does, or could, support cookies? [15:28] kkaefer: phazm: maybe you'll find something on http://wiki.github.com/ry/node/modules [15:29] kkaefer: the core implementation doesn't support cookies [15:29] kkaefer: (i.e. you have to implement that yourself) [15:29] kkaefer: http://github.com/billywhizz/node-httpclient claims to support cookies, though [15:30] ashb: there's also restler [15:30] kkaefer: for some reason, node doesn't notify me about errors/exceptions anymore [15:30] kkaefer: the server keeps running and just drops the current connection [15:30] kkaefer: and I don't see the error message :/ [15:31] kkaefer: it definitely didn't do that before [15:31] kkaefer: any ideas? [15:31] kkaefer: http://pastie.textmate.org/private/p6e5ohn6dnf4c2ofisfdka [15:32] kkaefer: doesn't display any errors in the console whatsoever [15:32] kkaefer: even though there should be two errors [15:32] mjijackson has joined the channel [15:33] mau2 has joined the channel [15:35] mau2: kkaefer, "node http server: ReferenceError: test is not defined" [15:35] kkaefer: mau2: yeah, that's what I want to see [15:35] kkaefer: I don't see anything, though [15:35] kkaefer: the server keeps running [15:35] kkaefer: just drops the connection [15:36] kkaefer: and doesn't show any debug information whatsoever [15:36] mau2: First: Do you have a open command? [15:37] mau2: Second, spawn will not return/throw a error if open doesn't exist. [15:37] mau2: It will be sent to the std error. [15:37] kkaefer: mau2: http://i.kkaefer.com/Terminal_%E2%80%94_node_%E2%80%94_96%C3%9721-20100501-173720.png [15:37] kkaefer: open does exist [15:37] kkaefer: (it's the mac os x command) [15:37] mau2: Ah, I see. [15:38] mau2: So, open works correctly? [15:38] kkaefer: yes [15:38] mau2: Great. [15:38] kkaefer: (it also doesn't throw errors without the open) [15:38] mau2: What version are you using? Stable or from the repository? [15:38] kkaefer: repository [15:38] kkaefer: however, it worked this morning [15:39] kkaefer: and there were zero changes since then [15:39] mau2: ... [15:39] mau2: That shouldn't happen. [15:39] kkaefer: hmm, let me check [15:42] kkaefer: mau2: ok... with 557ba6bd97bad3afe0f9 from apr 29, it works [15:42] kkaefer: looks like I didn't make install this morning [15:43] mau2: ACTION facepalms. [15:43] kkaefer: mau2: thanks [15:43] mau2: I didn't do anything. [15:43] mau2: I blame.. hmm.. creationix. [15:44] kkaefer: well, then at least talking to you helped me find the reason ;) [15:44] phazmBot has joined the channel [15:44] phazm: !pbsay testing node irc bot [15:44] phazmBot: phazm: testing node irc bot [15:44] kkaefer: mau2: http://github.com/ry/node/commit/3b323027be86aa13bdd497aac7b12a8c60b2b65c [15:45] kkaefer: http://github.com/ry/node/commit/3b323027be86aa13bdd497aac7b12a8c60b2b65c#L1R555 to be specific [15:45] softdrink has joined the channel [15:48] creationix: mau2: ? [15:48] micheil: hi tim. [15:48] mau2: You fault, you somehow bugged kkaefer's node. [15:48] awenkhh has joined the channel [15:48] kkaefer: ? [15:49] creationix: awesome, I didn't know my own powers [15:50] micheil: creationix: any idea if there's been any commits past day? [15:50] phazm: kkaefer: what have you done?! I now have 30 open tabs of node modules I _must_ implement :-P [15:51] phazm: no idea how I didn't run across this list before [15:51] mau2: ... [15:52] mau2: phazm, what list. [15:52] phazm: http://wiki.github.com/ry/node/modules [15:52] mau2: ...huh, I thought you were talking about actually implementing modules, not using them. [15:53] phazm: implementing into my app... [15:54] creationix: micheil: I think so, git does have logs you know [15:54] micheil: creationix: I don't have access to them [15:54] micheil: (or, not right now) [15:54] micheil: I can only get an irc client connected [15:55] creationix: micheil: 5 commits in the last 24 hours [15:55] micheil: okay [15:58] keyvan has joined the channel [15:59] SamuraiJack has joined the channel [16:01] rauchg_ has joined the channel [16:06] rnewson has joined the channel [16:20] sveimac has joined the channel [16:23] brianmario has joined the channel [16:36] devinus has joined the channel [16:41] ewdafa has joined the channel [16:42] neytema has joined the channel [16:42] markwubben has joined the channel [16:47] JimBastard has joined the channel [16:48] sveimac has joined the channel [16:50] phazm: phazm@ubuntu:/web/node/node/node-httpclient$ node example.js [16:51] phazm: Error: Cannot find module 'http_old' [16:51] phazm: at loadModule (module:238:15) [16:51] phazm: I'll submit an issue if I need to, just want to see if anyone here knew what was going on [16:53] JimBastard: goood morning node [16:56] micheil: phazm: http_old is probably going to be made defunct, and you should upgrade to the new libraries [16:57] micheil: _ry: let me know what you think of those two patches when you're about [17:04] softdrink has joined the channel [17:11] Yuffster has joined the channel [17:15] micheil: what do you think, for a websocket server that runs on top of http.js, I should re-echo the "request" event for standard http events? [17:17] awenkhh has joined the channel [17:19] jwm: micheil: have you used the other websocket servers [17:20] micheil: hmm? [17:20] micheil: jwm: I'm rewriting mine based on the patch that will hopefully be accepted within the next/.. 64 hours? [17:20] jwm: ahh, I must of missed what you typed above [17:20] jwm: sorry [17:21] jwm: I love websockets btw [17:21] micheil: jwm: and.. uh, this isn't any ordinary websocket server that I'm working on [17:21] jwm: ohh, any url for it [17:21] micheil: I'm just trying to work out the best way to architect it.. [17:22] micheil: jwm: nup, a 100% spec compliant and draft-hixie-75 compliant server [17:23] jwm: I like the flash plugin for websockets [17:23] micheil: which, will be running on top of a http server, so, if you want, you can require my websocket library, start it up similar to the http library, and then also handle requests similar [17:23] jwm: I'm working on p2p for browsers [17:23] jwm: heh [17:23] micheil: in the sense that: ws_server.addListener("rrequest", function(req, res){}); [17:24] jwm: can you proxy websockets [17:24] micheil: which is the same api as from http: http.addListener("request", function(req, res){}) [17:24] jwm: I don't think there is a module in nginx yet for it [17:24] micheil: yes, you can proxy websockets, iirc. [17:25] micheil: I'm surprised I'm conscious atm.. took some heavy pain killers.. [17:25] jwm: I'd like to do everything over port 80 [17:26] jwm: I'd like to implement websockets for browsers [17:26] micheil: this websocket module will allow that [17:26] jwm: but cross domain hurdles have to be jumped [17:26] jwm: yeah I know that is what you are aiming to achieve [17:26] micheil: jwm: the latest websocket spec is.. uh.. very secure. [17:26] jwm: the websockets side by side with http serving [17:27] jwm: I'm looking at the spec [17:27] micheil: thee spec is actually designed for http and websockets to run side by side [17:27] jwm: do you think they'll add provisions for cross domain [17:27] ashb: irc is a horrible protocol [17:30] jwm: hmm [17:30] jwm: I wonder if I could come up with XSS solution involving websocketsa [17:30] jwm: that is secure and can get in the spec [17:31] micheil: awesome sauce. [17:32] micheil: _ry: with about 20 lines of code removal, my websocket server powers up with a pur [17:32] micheil: jwm: it's simple, you proxy. [17:32] jwm: http://www.w3.org/TR/2008/WD-html5-20080122/#peer-to-peer [17:32] jwm: check it out it did make it into the spec [17:33] micheil: I can't. long story. [17:33] cloudhead has joined the channel [17:38] micheil: jwm: what do you think? ws.createServer( { /*options*/ } ); [17:38] micheil: .listen(PORT) [17:38] jwm: well [17:38] micheil: or, .listen(PORT, HOST) [17:39] jwm: I don't like server :) [17:39] micheil: but mainly the idea of the options hash [17:39] micheil: jwm: no server? [17:39] jwm: whatt is the http line [17:39] jwm: I like listen [17:40] micheil: oh, what, it was actually this: [17:40] micheil: ws.createServer([OPTIONS]).listen(PORT, [HOST]) [17:40] micheil: sort of like http.createServer [17:41] micheil: only instead of an event listener, it's a set of options [17:41] jwm: yeah just keep with regular naming [17:41] micheil: that way I don't need all the http.Server.setTimeout style things [17:42] micheil: I think by the time I make next commit, I'll have deleted about 2000 lines of code, but also added 3000 [17:44] sveimac has joined the channel [17:46] jwm: hehe [17:46] jwm: refactoring [17:46] jwm: going on github? [17:48] cloudhead: is there a way to flush stdout before process.exit() ? [17:48] cloudhead: seems like the buffer is lost [17:49] micheil: jwm: yup. I'm reworking it for a next release around the time of node 0.2 [17:51] JimBastard: anyone want a free nodejs cloud hosting account [17:51] micheil: where abouts? [17:51] JimBastard: www.nodejitsu.com [17:51] micheil: hmm? [17:51] micheil: who runs it? [17:51] JimBastard: i got really high and built a nodejs hosting platform [17:52] JimBastard: it does load balance and reverse prox and auto deployment from github [17:52] micheil: neat [17:52] JimBastard: started up the private alpha last night [17:52] JimBastard: http://demos.nodejitsu.com/ [17:52] micheil: JimBastard: send me an email, if you could: micheil@brandedcode.com [17:54] JimBastard: sure, im gonna be polishing stuff up today, maybe hit the mailing list [17:54] mape: JimBastard: shell access? [17:54] JimBastard: i should prob put some copy up somewhere too [17:55] JimBastard: right now its a private alpha, so i have to add your account to our hive file manually, but after that its all automagic. you just provide a github url and we deploy it [17:55] JimBastard: i can add accounts and new apps in realtime without shutting down node [17:55] mape: Ah k, how does it handle dependencies and whatnot? [17:55] JimBastard: new subdomains too [17:55] JimBastard: everyone gets their own node instance [17:56] micheil: JimBastard: not bad, not bad at all [17:56] micheil: JimBastard: child processes? [17:56] JimBastard: something like that [17:56] micheil: cool [17:56] phazm: is this the top secret project you were referring to last night? [17:56] JimBastard: i cant really go too much in the nitty gritty, ill get yelled at [17:56] JimBastard: aye [17:56] mape: If I want to run an old version of a module is that doable? Do I add it as a submodule in git? [17:57] JimBastard: mape - im gonna add submodule support, but there is none right now [17:57] mape: ok [17:57] JimBastard: you just setup your pacakged app up as a git repo [17:57] micheil: JimBastard: I won't have any apps just yet, but give me a few weeks and I might, gotta get this websocket server built first, and waiting on another company to implement something.. [17:57] JimBastard: and provide the git url, and the path to your app inside that repo [17:57] micheil: so that I don't need to parse xml, but can just consume json [17:58] micheil: JimBastard: is git done via shell or a git library? [17:58] JimBastard: cool, yeah micheil it would be great for demos. as its free and alpha, i wouldnt want to run anything too serious on it yet [17:58] JimBastard: micheil: just use pipes [17:58] mape: JimBastard: Unlimited bandwidth like dreamhost? ;) [17:58] felixge has joined the channel [17:58] felixge has joined the channel [17:58] JimBastard: there is no such thing as unlimited anything, except stupidity [17:59] mape: JimBastard: How about db support? [17:59] micheil: mape: use something like mongohq [18:00] mjijackson: JimBastard: Sounds pretty sweet. Wish I had an app to deploy. ;) [18:00] mape: Hmm yeah, how is the latency when using such services? [18:01] JimBastard: non existent ? [18:01] JimBastard: its the rackspace cloud [18:01] JimBastard: and a VERY thing proxy pass wrapper [18:01] JimBastard: i would think its gonna be blazing fast [18:02] mape: Nice [18:03] steadicat has joined the channel [18:04] phazm: does anyone feel like explaining, or can you link to, a plain-english explanation of what the cloud, in this instance, is? From my understanding, it's like folding@home, but with servers, so you can use the resources of many services at one time... am I close? [18:05] mape: phazm: External hosting [18:05] mape: Is pretty much 99% of all "cloud hosting" [18:05] mape: And hopefully they have better redundancy and whatnot [18:05] phazm: external hosting, to me, is any colo -- like if I buy a shared hosting account from godaddy.,com [18:06] mape: It is a very vague thing [18:07] mape: But I guess, redundancy, ability to scale, pay as you go might be things that would fit in [18:07] JimBastard: phazm: [18:08] JimBastard: i have access to an API that lets me spawn new virtual machines up with new resources. if my server can host 1 app with 1000 connections, when connection 1001 comes in im automagically gonna spin up another instance and then load balance the requests and share sessions and data and all that good stuff [18:09] JimBastard: does that make sense? [18:09] micheil: yeah [18:09] phazm: yes [18:09] JimBastard: hence, its "cloud" [18:10] tmpvar has joined the channel [18:10] phazm: I would have thought it was more involved than just creating new vms when connections are exceeded [18:10] phazm: + load balancing [18:10] mape: phazm: Its a great buzz word :) [18:10] phazm: heh [18:10] phazm: very web 3.0 [18:10] mape: That has to count for something [18:11] JimBastard: phazm im dumbing it down, its a fairly complex process [18:12] phazm: okay. thank you JimBastard [18:15] mape: Anyone here had issues with the mongodb native module going wonky after doing the second db.open? [18:19] jedschmidt has joined the channel [18:20] micheil: mape: I haven't used it yet, but the tests all pass for me [18:21] mape: micheil: I'm using it with express, first request works fine, second hangs and never calls the callback [18:25] quirkey has joined the channel [18:29] kriskowal has joined the channel [18:31] nsm has joined the channel [18:32] JimBastard: hey quirkey ! [18:32] quirkey: JimBastard: yo yo [18:33] micheil: we can has a quirkey man. [18:34] micheil: damn my body must have a strong amount of coffee / energy in it.. took a pain killer about 2.5hrs ago, that normally would knock me out.. [18:43] rauchg has joined the channel [18:43] micheil: Buffer.slice, was that (start, end) or (start, len) [18:43] micheil: ? [18:44] devinus has joined the channel [18:44] micheil: start, end. [18:45] saikat has joined the channel [18:47] micheil: are start and end byte or character indexes? [18:49] micheil: does it make sense for a websocket connection to emit events? [18:49] technoweenie has joined the channel [18:49] technoweenie has joined the channel [18:53] micheil: _ry: is there any recommended limit to the number of events.EventEmitters one should create? [18:53] micheil: yo technoweenie. [18:53] _ry: micheil: shrug - no [18:53] _ry: running your patch right now [18:53] technoweenie: hi micheil [18:53] micheil: what about memory issues? [18:53] _ry: looks good [18:53] micheil: _ry: both patches or? [18:53] _ry: the first [18:53] micheil: okayu [18:54] markwubben has joined the channel [18:54] _ry: memory issues - not really [18:54] _ry: i mean, nothing more than any other object [18:54] micheil: so, emitters are pretty disposable [18:54] micheil: ACTION is rewrite node-websocket-server [18:54] micheil: *rewriting [18:55] micheil: using the two patches I've sent you, _ry [18:55] _ry: good :) [18:55] micheil: so, well have a this is how you do it sorta thing [18:55] micheil: it's giving for some beautiful code [18:56] technoweenie: micheil: are you miksago on github [18:56] micheil: yup [18:56] micheil: and everywhere else on the web [18:56] micheil: including here. [18:56] technoweenie: sneaky [18:56] micheil: love grouped nicknames [18:57] rauchg: micheil: how does upgrade work now ? [18:57] _ry: micheil: you should write some docs [18:57] micheil: rauchg: sort of, I'm just getting _ry to review it. [18:57] micheil: _ry: I shall, after I fully work out the power of it all [18:57] JimBastard: sup technoweenie [18:58] technoweenie: hey JimBastard [18:58] micheil: _ry: still testing things for now, but it's proving very good [18:58] CIA-75: node: 03Ryan Dahl 07master * r692f580 10/ src/node_file.cc : Implement fs.read() for buffers - http://bit.ly/cZdsGY [18:58] CIA-75: node: 03Micheil Smith 07master * rf990f24 10/ (lib/http.js test/simple/test-http-upgrade.js): Implementing the event emit for Upgrade requests, with tests. - http://bit.ly/9qvOih [18:58] CIA-75: node: 03Micheil Smith 07master * rd6110fb 10/ lib/http.js : Making requestListener for the construction of a http.Server optional, as it is for net.Server - http://bit.ly/csFFBP [18:58] _ry: micheil: thanks for the patches [18:58] rauchg: woohoo! [18:58] rauchg: thanks micheil [18:58] micheil: _ry: try out the second patch as well, it makes it really easy to inherit from http.Server, just like net.Server [18:58] micheil: rauchg: whatcha need upgrade for? [18:59] rauchg: socket.io [18:59] micheil: ah [18:59] micheil: rauchg: tip: this.addListener("upgrade", handleUpgradeRequest); [18:59] rauchg: yup, seeing it now [18:59] micheil: function handleUpgradeRequest(req, socket, upgradeHead){ [18:59] micheil: although, the last two args can be found within req [19:00] rauchg: so socket === req.connection ? [19:00] _ry: yes [19:00] rauchg: k [19:00] rauchg: _ry: what did you have for breakfast [19:00] _ry: i haven't gone yet :) [19:00] rauchg: :D [19:01] _ry: going now. bbl :) [19:01] rauchg: so, node.js patches [19:01] micheil: rauchg: not really. [19:01] micheil: rauchg: it's probably better to go through req.socket [19:02] mrjjwright has joined the channel [19:02] micheil: (keeps the terms clear on it, etc.) [19:05] devinus has joined the channel [19:07] felixge: _ry: http://github.com/ry/node/commit/692f580a07c2787ed5db730b5eae8e9e1da43f12 = <3 [19:09] tlrobinson_ has joined the channel [19:11] mau has joined the channel [19:11] micheil: sweet. the new state machine I'm loading into node-websocket-server is very powerful. [19:13] drostie has joined the channel [19:27] micheil: _ry: is there any reason to use socket.ondata vs socket.addListener(data) ? [19:29] jashkenas has joined the channel [19:31] micheil: night chaps. (& ladies, if there are any?) [19:35] teemow has joined the channel [19:36] cloudhead: I'm trying to use Script.runInThisContext, to run a test, but it's telling me 'require is not defined' -- any knows why? [19:36] spoob has joined the channel [19:38] Nohryb has joined the channel [19:39] BinaryPie has joined the channel [19:40] keyvan has joined the channel [19:40] cloudhead: same problem with process.compile [19:42] derferman has joined the channel [19:50] charlesjolley has joined the channel [19:58] saikat: this is probably a very noobish question, but given the code in this file (it's in the Socket.IO syntax): http://gist.github.com/386619 is the sequence of events listed in that file possible (I believe it is due to the concurrent nature of node/all web servers right?) [20:02] saikat: And I think the proper way to serialize these broadcast/acks (basically, making sure that client A gets its ack before client B's message is broadcast) would be to use some kind of message queue [20:03] saikat: but i'm not entirely sure what i would really use [20:03] Dethe has joined the channel [20:05] JimBastard_ has joined the channel [20:05] sztanpet has joined the channel [20:06] texodus has joined the channel [20:07] saikat: or does node actually not use multiple processes? [20:09] saikat: oh i guess it doesn't currently, so in fact, the sequence described in that gist would not be possible? [20:10] rictic has joined the channel [20:12] brainproxy: what's all the nutty craziness about node.rb -- has the world gone mad?? [20:14] tobbez: node.rb D: [20:15] mape: hehe [20:17] towski has joined the channel [20:17] keyvan has joined the channel [20:19] teemow has joined the channel [20:20] mjijackson has joined the channel [20:20] mxz has joined the channel [20:21] mxz: can the http.clientRequest follow redirects? [20:27] felixge has joined the channel [20:27] felixge has joined the channel [20:29] awenkhh has joined the channel [20:30] jedschmidt has joined the channel [20:33] sveimac has joined the channel [20:40] lifo has joined the channel [20:44] TobiasFar has joined the channel [20:51] cloudhead: anyone know how to get the object in which setTimeout etc are defined? `global` is empty for some reason.. [20:51] ak__ has joined the channel [20:53] ak__ has left the channel [20:54] ashb: cloudhead: this at global scope? [20:55] tk: cloudhead: appears to be builtin.... if I run node-repl its a already avail [20:57] cloudhead: ashb: yea [20:57] cloudhead: from a file run with the `node` command [20:57] ashb: cloudhead: i meant |this| whilst your code is in global scope [20:57] ashb: var global = this; [20:58] cloudhead: `this` is an empty object [20:58] cloudhead: where are 'require' etc looked up on? [20:58] cloudhead: ah I guess those are locals [20:59] cloudhead: but setTimeout should be somewhere.. [20:59] cloudhead: hmm [20:59] cloudhead: I need to get the binding which defines setTimeout [21:00] cloudhead: because Script.runInNewContext doesn't make it available [21:00] admc has joined the channel [21:01] JimBastard has joined the channel [21:01] tk: cloudhead: you can always pasa a reference to it, or just remake it, setTimeout.toString() shows that its just a a convenience wrapper for some other API calls [21:01] JimBastard: i gotta brb, but http://github.com/Marak/broodmother [21:01] JimBastard: cloudhead [21:01] JimBastard: :-D [21:02] cloudhead: nice [21:02] JimBastard: broodmother is an automagic node.js cloud multi-site application balancer and deployer. requests come in on unique subdomains and are routed to locally running drones. if a drone is not available for the request, broodmother will spawn a new drone to serve the request. [21:02] mape: :) [21:02] cloudhead: tk: the only way I can have both require/__dirname/__filename, and setTimeout etc [21:02] mape: JimBastard: with that one could easily point to local git repos and that should work fin? [21:02] mape: *e [21:02] cloudhead: is to set global.require, global.__dirname, and use Script.runInThisContext [21:02] cloudhead: kinda ugly but oh well [21:03] ashb: sounds like runInNewContext doesn't setup the free/global vars the same way [21:03] cloudhead: yea [21:03] cloudhead: I wish I could have access to whatever `ThisContext` is [21:03] cloudhead: then I could use NewContext, and merge it [21:03] ashb: you can. you just have to write C++ [21:04] cloudhead: heh, I mean with vanilla node [21:04] cloudhead: oh right, you're thinking an addon [21:04] cloudhead: there should be a way through JS though [21:05] cloudhead: or maybe I'll submit a patch for runInThisContext to take an optional hash too [21:06] sveimac has joined the channel [21:18] beutdeuce has joined the channel [21:24] kriszyp has joined the channel [21:31] mrjjwright_ has joined the channel [21:36] cloudhead has joined the channel [21:43] jherdman has joined the channel [21:45] CIA-75: node: 03Ryan Dahl 07master * r67fb0ec 10/ lib/http.js : Fix deprecation message - http://bit.ly/cpq3k5 [21:46] darkf has joined the channel [21:47] maushu has joined the channel [22:08] binary42 has joined the channel [22:09] gwoo has joined the channel [22:15] sveimac has joined the channel [22:17] JimBastard has joined the channel [22:17] maushu has joined the channel [22:17] beutdeuce has left the channel [22:17] mattly has joined the channel [22:17] JimBastard: sup binary42 [22:18] binary42: JimBastard: Heyo. Doing some node hacking but I think I'm going to relocate to a café. [22:18] JimBastard: im downtown by city hall doing weekend hours [22:18] JimBastard: needed to escape apartment jail [22:18] JimBastard: check it out, http://github.com/marak/broodmother [22:18] JimBastard: ive been fiddling with getting all the db support going [22:19] JimBastard: im just gonna make all databases be localhost for the users [22:19] mfeiri has joined the channel [22:19] binary42: Ah. Works. [22:20] binary42: JimBastard: Well, maybe I should find a cafe down here rather than going to my usual east village spots. [22:20] JimBastard: im gonna be here for a while, ll be heading back uptown at like 830 or so [22:21] binary42: Just shot all that street fair madness on broadway for Romania Day. [22:21] binary42: Kk. I'll probably head over towards alphabet city. [22:22] ryan[WIN]: http://hackadaycom.files.wordpress.com/2010/05/cpu-as-passive-heat-sink1.jpg?w=470&h=353 [22:23] JimBastard: i think the weed protest may day thing is today [22:23] ryan[WIN]: using an old cpu as a heatsink == <33 <3333 [22:24] kriskowal has joined the channel [22:25] rolfb has joined the channel [22:25] tmpvar_ has joined the channel [22:25] tmpvar has joined the channel [22:30] binary42: JimBastard: Yeah... but all the protestors are home stoned. [22:30] JimBastard: ahaha [22:33] tobbez has left the channel [22:33] tmpvar: what up [22:35] micheil: ouch,. my foot feels broken. [22:35] mattly has joined the channel [22:35] JimBastard: sup tmpvar [22:36] tk: heya tmpvar [22:37] tk: oof, i think I might have taken my pain killer twice on accident... shall make for an interesting afternoon [22:37] tmpvar: lol [22:38] tk: 1000mg of vicodin :/ [22:38] binary42: hahah. I've heard stories about that stuff. [22:39] tmpvar: yikes dude, thats a gram of tylenol! [22:40] mattly has joined the channel [22:41] tk: tmpvar: ya... thought I only took my acid reflux meds so took my vicodin before I Went to get food, ~40mins ago... and now i feel ..... tingly I guess is one way to put it :P [22:42] tmpvar: heh heh, enjoy :P [22:42] tk: no pain though... [22:47] _ry: someho wthe memory usage of my node process dropped to 2mb... [22:47] sztanpet has joined the channel [22:47] _ry: i don't really understand what it's doing [22:47] _ry: UID PID PPID C SZ RSS PSR STIME TTY TIME CMD [22:47] _ry: ryan 27670 4001 0 11366 2300 0 Apr30 pts/2 00:00:04 ../node/node server.js [22:48] _ry: now it dropped more [22:48] _ry: UID PID PPID C SZ RSS PSR STIME TTY TIME CMD [22:48] _ry: ryan 27670 4001 0 11366 2040 0 Apr30 pts/2 00:00:04 ../node/node server.js [22:48] _ry: er [22:49] ryan[WIN]: the garbage collector probably raged [22:55] steadicat has joined the channel [22:57] aho has joined the channel [23:06] mcarter has joined the channel [23:21] micheil: brainproxy: node.rb? [23:30] JimBastard: _ry are you complaining that node is using too little memory? [23:36] pjb3_ has joined the channel [23:38] isaacs has joined the channel [23:42] micheil: even though he's now left <3 isaacs for showing me the ideas and concepts of state machines [23:45] texodus has left the channel [23:45] isaacs has joined the channel [23:48] JimBastard: lol micheil [23:48] JimBastard: wikipedia is your friend [23:48] micheil: hmm.. [23:49] JimBastard: start at software programming patterns page and go 3 levels deep in any direction [23:49] JimBastard: see you in a few years [23:49] JimBastard: or days [23:49] JimBastard: :-p [23:49] tmpvar: lol [23:49] tmpvar: patterns, pft. [23:50] micheil: ACTION is trying to get these buffers working [23:50] JimBastard: http://en.wikipedia.org/wiki/Design_pattern_%28computer_science%29 [23:50] micheil: is there such thing as buffer.concat? [23:50] aho has joined the channel [23:50] micheil: eg, join two buffers together and return the new buffer? [23:50] JimBastard: personally, i like this page better. i find it more informative. http://en.wikipedia.org/wiki/Anti-pattern [23:52] _ry: i don't understand why this process is using so little memory [23:52] _ry: how did it get in that state? [23:52] _ry: :/ [23:52] _ry: i would love to have 2mb node processes [23:52] micheil: _ry: is everything being stored etc? [23:52] _ry: it's chat.nodejs.org [23:53] micheil: well, what I mean by that, if it's low on memory, I'd think that maybe variables are being lost [23:53] JimBastard: May 1st 2010, NodeNet became self aware and started optimizing itself in realtime [23:53] JimBastard: soon the machines will take over [23:53] JimBastard: i knew it would be your fault ry [23:53] kriskowal: brendan said we need skynet [23:54] _ry: micheil: i don't know.. [23:54] micheil: kriskowal: didn't you have some form of buffer.concat? [23:54] _ry: going to shut it down and see if it does it again [23:54] kriskowal: micheil not in binary/f [23:55] micheil: oh [23:55] micheil: how should I join two buffers together then? [23:55] kriskowal: binary/b had bytestring and bytearray concat methods. i manage to get narwhal's binary/b implementation working on top of binary/f [23:55] _ry: make a new one [23:55] kriskowal: yeah, new one then use copy [23:56] micheil: and what, buffer.copy the first into the new one, then the second [23:56] micheil: ? [23:56] kriskowal: yes [23:56] micheil: okay [23:56] micheil: sorry I'm not thinking the exact clearest I normally would.. [23:56] kriskowal: or, install narwhal-lib and node-narwhal and use require("narwhal/binary") :P [23:56] micheil: mainly due to this: http://twitter.com/miksago/status/13211877621 [23:57] kriskowal: it's not quite ready yet, but i'm getting close [23:57] kriskowal: ah, poor fellow. [23:57] micheil: well, actually, if you have a buffer, so, new Buffer(8), then you write 9 bytes to it [23:57] micheil: or 9 characters, whichever [23:57] micheil: will the first character or byte get lost? [23:59] kriskowal: no, it's not a queue [23:59] _ry: micheil: it's just like an array [23:59] _ry: just a bit more fixed [23:59] micheil: okay.. [23:59] kriskowal: the write would be partial, and you'd get the number of bytes written [23:59] kriskowal: _ry write returns bytes written right?