Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

textboards

Name: Anonymous 2007-06-05 17:49 ID:4Zp/Oh3P

I want to make my own textboard in C fastcgi using files instead of a sql database.
Does it sound like a good fast idea?

I just want it to be blazingly fast.

What do you think /prog/?

Name: Anonymous 2007-06-08 3:46 ID:ia8lUjoV

don't bother with files, just limit yourself to one fastcgi process, and keep all the data in memory. maybe have a dump/import so you can shutdown and restart without losing data.

apache's fastcgi stuff should buffer input / output such that you're not waiting around for clients, which means that a simple while(true) { handle_request(); } should perform just as well as multiple processes/threads. unless you have multiple cores, i guess, in which case threads+locking would be the way to go.

you win for lack of filesystem overhead, i would advise you to design your data structures such that paging out to swap will work reasonably well.

inspired by the mailinator implementation - http://mailinator.blogspot.com/2007/01/architecture-of-mailinator.html - even though it's made of threaded jsp fail

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List