Tag[][]: node

Tue, 21 Aug 2012 04:51:40 GMT
OHO! I fix it!
Tags:node mongodb
It's been a few months, but I finally figured out how I've been misusing node and the mongodb JS plugin.

Essentially it's my PHP background to blame, where every new request to the server is exactly that - a new request - and everything has to be reinitialized anew.

Instead, node is a true server - it runs, maintains state, and waits for new input, be it a page request or ... something else. As such, it is not necessary to reinitialize the database, the connections, and most importantly the data collection that mongo maintains. Instead you run new finds/saves against a collection that's already loaded - much faster, seems to me.

Initially the mongo allowed these repeated loads and I'm sure the performance suffered; but at some point, the plugin author decided to stop the madness and simply started throwing errors when repeated (and redundant) connections to an already open DB were requested. I didn't really have the headspace to grok this until now, and I freely admit it's much more elegant to well, behave as node expects. Hopefully that means more updates, on the bloggy at least. DCSB will still have to wait. :)
Fri, 22 Jul 2011 06:13:08 GMT
Wrapping up nodebloggy
I added linking by post title and the XML page. I was hoping to get a little work done on Dweller pathfinding tonight, but I'll be just as glad to have this closer to completion. I added timestamp (hey, everyone drives by GMT anyway, right?) and a little parsing of header to URL for pretty URLs - which is something I never had on d.net. I'm pretty pleased with myself, in all. :)

It'd be nice to get some image processing and a gallery and all that in here, but ... another time. Dweller beckons!
Fri, 15 Jul 2011 21:31:29 GMT
Almost there!
Tags:makingOf node
You can see the making of here: [do-internets.posterous.com] really pleased and amazed at how fast this is coming along. I think the "if it doesn't work, abandon technology and try something else" approach has a lot to recommend for it! Also, quite glad I didn't stick with that Ruby thing; I was trying to do too much right away, there.

Next up, some Dweller stuff since this is pretty usable already. I can add an about page at some point, a footer, some actual colors - or not. Well, that's all if I can tear myself away from Dredmor anyway ...