Package ganeti :: Package http :: Module server
[hide private]
[frames] | no frames]

Module server

source code

HTTP server module.

Classes [hide private]
  _HttpServerRequest
Data structure for HTTP request on server side.
  _HttpServerToClientMessageWriter
Writes an HTTP response to client.
  _HttpClientToServerMessageReader
Reads an HTTP request sent by client.
  HttpServerRequestExecutor
Implements server side of HTTP.
  HttpServer
Generic HTTP server class
Functions [hide private]
 
_DateTimeHeader(gmnow=None)
Return the current date and time formatted for a message header.
source code
Variables [hide private]
  WEEKDAYNAME = ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"]
  MONTHNAME = [None, "Jan", "Feb", "Mar", "Apr", "May", "Jun", "...
  DEFAULT_ERROR_CONTENT_TYPE = "text/html"
  DEFAULT_ERROR_MESSAGE = "...

Imports: BaseHTTPServer, cgi, logging, os, socket, time, signal, asyncore, http, utils, netutils


Function Details [hide private]

_DateTimeHeader(gmnow=None)

source code 

Return the current date and time formatted for a message header.

The time MUST be in the GMT timezone.


Variables Details [hide private]

MONTHNAME

Value:
[None, "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", \
"Oct", "Nov", "Dec"]

DEFAULT_ERROR_MESSAGE

Value:
"""\
<html>
<head>
<title>Error response</title>
</head>
<body>
<h1>Error response</h1>
<p>Error code %(code)d.
...