I checked the article about
making a python mmo server fast and it's very useful. The code is not exactly nice, but it's a very good design overall (I also thought of using pickle).
Now looking into twisted. It would certainly be much faster than a C# threaded server and may even be faster than a C# async framework (a benchmark showed that apache's java mina doesn't scale nearly as well as twisted).
I personally found that article and the code kind of lacking. Sometimes the "make something that works then expand" thing works very well, but for a server I'd definitely try to think ahead more so you don't wind up with a clunky unwieldy beast that's hard to modularize or abstract. Plus the thought of running a server which has blocking IO calls in a single thread just makes me cringe.
Plus I was rather hoping he'd write about how he coded the server during those four hours, rather than just saying he did it, giving some code, and saying he went by a certain principle. Either way I don't think I'd develop a server in CPython, I've done some reading and - though I might have been misinformed - it seems as though the GIL would slow down any threading done in CPython, which disqualifies it as a suitable choice for me. IronPython might be an idea, but it doesn't run well on Mono and I'm unsure of the quality of the language in general.
Is Twisted really that powerful? I must admit I've never looked into it and was just going for a threaded C# server approach, but if it's that good I'll definitely have to look into it. More information would be highly appreciated.
Youhei said:
Have you decided on the name yet? Silly question, but I was curious.
Not such a silly question. I have one, but it's more a work name so I'll probably wind up changing it a bunch of times before the end. Once I find something I like to settle on I'll create a new thread or rename this one.
I'd also like to say I'm glad that people are showing interest in this. It's very motivating.