On Wed, Sep 26, 2012 at 8:41 PM, Anthony Kong <anthony.hw.k...@gmail.com> wrote: > Hi, Chris, > > Thanks for your reply. I really do not have any requirement. It is more a > curiosity question (not work related). I'd like to find out how python can be > used to 'glue' all these moving parts together. Performance and security are > definitely not a concern as it is just a toy idea/project.
Okay! Toy project. Here goes then! (BTW, you don't need to send to both python-list and comp.lang.python - they mirror each other.) 1) It's straight-forward to extend Python using C, so you could fairly readily make thin wrappers around the C APIs of whatever components you want to glue together. 2) V8 may be a smidge more fiddly, though; it uses a C++ API that's designed to be really convenient, using automatic variables and such. You may want to consider embedding a different engine, but if you do use V8, you'll end up largely undoing all that convenience work they've done. A pity really; V8's the first language engine I've ever seen that makes it so easy on the embedder. 3) Networking is easy to do in Python. Obviously you can do TCP sockets in pretty much any language, but Python also has handy facilities for higher level protocols like HTTP, already built-in. (So do quite a few high level languages, these days. It's nothing unique, but no less handy.) 4) Security is going to be a pain. But you said you don't care. Just promise me you won't unleash this thing on the world :) 5) This is going to be a huge job. You're going to get bored of it long before it's finished. But it'll still be educative for as long as you stick it. Have you ever done anything with networking? If not, I'd recommend you start there - not because it's the hardest (it isn't), but because it's the most fun. At least, *I* think it is. But I'm biased majorly. :D ChrisA -- http://mail.python.org/mailman/listinfo/python-list