473,394 Members | 1,765 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Asynchronous HTTP server in standard library ?

Python standard library provides two modules for asynchronous socket
programming : asyncore and asynchat. Several web servers have been built
upon these modules (medusa being the best-known I suppose) and are famous
for their performance level

Unfortunately no example of use is provided in the standard library (whereas
the more "classic" SocketServer is illustrated by BaseHTTPServer,
SimpleHTTPServer, etc). I think it would be useful if Python came with a
simple HTTP server written with these modules, to help beginners understand
how use them

I've written one, which handles GET and POST requests. It's inspired by (and
partly copied from) the http subset of medusa, only reduced to less than 200
lines. It's called SimpleAsyncHTTPServer and published on Active State
Python Cookbook
http://aspn.activestate.com/ASPN/Coo.../Recipe/259148

Any thoughts ?
Pierre
Jul 18 '05 #1
2 3092
"Pierre Quentel" <qu************@wanadoo.fr> writes:
Python standard library provides two modules for asynchronous socket
programming : asyncore and asynchat. Several web servers have been built
upon these modules (medusa being the best-known I suppose) and are famous
for their performance level

Unfortunately no example of use is provided in the standard library (whereas
the more "classic" SocketServer is illustrated by BaseHTTPServer,
SimpleHTTPServer, etc). I think it would be useful if Python came with a
simple HTTP server written with these modules, to help beginners understand
how use them

I've written one, which handles GET and POST requests. It's inspired by (and
partly copied from) the http subset of medusa, only reduced to less than 200
lines. It's called SimpleAsyncHTTPServer and published on Active State
Python Cookbook
http://aspn.activestate.com/ASPN/Coo.../Recipe/259148

Any thoughts ?


I think you'll be welcome in the web-sig !!!
http://python.org/sigs/web-sig/

--
Wilk - http://flibuste.net
Jul 18 '05 #2
Wilk <wi******@OUTflibuste.net> writes:
"Pierre Quentel" <qu************@wanadoo.fr> writes:

[...]
Any thoughts ?


I think you'll be welcome in the web-sig !!!
http://python.org/sigs/web-sig/


Yes, certainly -- don't let it worry you that the discussion died down
for the last month or so. It'll likely start up again if/when
somebody posts something interesting (or, more accurately, when
somebody posts something controversial ;-).
John
Jul 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Mark McEahern | last post by:
I just wrote a very simple wrapper for the PayFlow Pro SDK (see below). A friend of mine did this before, but I didn't have access to his source, so I took it as a learning opportunity for me to...
3
by: Dave | last post by:
What are some recommended references for the C Standard Library portion of C++? Buying the Standard itself is impractical now that only the hardcopy version is available...
43
by: Steven T. Hatton | last post by:
Now that I have a better grasp of the scope and capabilities of the C++ Standard Library, I understand that products such as Qt actually provide much of the same functionality through their own...
7
by: Colin | last post by:
I'm writing a little console socket server but I'm having some difficulty. Can I ask your advice - where is the best place to get some help on that topic? It would be nice if some people who knew...
14
by: jojoba | last post by:
Hi, I hope this post is ok for this group. Here's my deal: I have two computers on my LAN at home. One desktop. One laptop. Both computers are wireless enabled (and wired enabled too). I...
1
by: Macca | last post by:
Hi, I am implemeting an asynchronous socket server in my app. There will be up to 30 clients sending data to the socket server. Within the socket server I will have a number of local variables...
2
by: Ben Finney | last post by:
Howdy all, I'm trying to implement some new functionality for an existing PHP web application. Rather than writing a whole lot of stuff in PHP, and looking toward a future when more of the...
4
by: Engineerik | last post by:
I am trying to create a socket server which will listen for connections from multiple clients and call subroutines in a Fortran DLL and pass the results back to the client. The asynchronous socket...
0
by: sebor | last post by:
October 29, 2007 -- The Apache C++ Standard Library project is pleased to announce that the official stdcxx 4.2.0 release is now available for download from the following location:...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.