App Engine Python SDK  v1.6.9 rev.445
The Python runtime is available as an experimental Preview feature.
Public Member Functions | List of all members
google.appengine.tools.devappserver2.http_proxy.HttpProxy Class Reference

Public Member Functions

def __init__
 
def handle
 

Detailed Description

Forwards HTTP requests to an application instance.

Constructor & Destructor Documentation

def google.appengine.tools.devappserver2.http_proxy.HttpProxy.__init__ (   self,
  host,
  port,
  instance_died_unexpectedly,
  instance_logs_getter,
  error_handler_file,
  prior_error = None 
)
Initializer for HttpProxy.

Args:
  host: A hostname or an IP address of where application instance is
  running.
  port: Port that application instance is listening on.
  instance_died_unexpectedly: Function returning True if instance has
  unexpectedly died.
  instance_logs_getter: Function returning logs from the instance.
  error_handler_file: Application specific error handler for default error
  code if specified (only default error code is supported by
  Dev AppServer).
  prior_error: Errors occurred before (for example during creation of an
  instance). In case prior_error is not None handle will always return
  corresponding error message without even trying to connect to the
  instance.

Member Function Documentation

def google.appengine.tools.devappserver2.http_proxy.HttpProxy.handle (   self,
  environ,
  start_response,
  url_map,
  match,
  request_id,
  request_type 
)
Serves this request by forwarding it to the runtime process.

Args:
  environ: An environ dict for the request as defined in PEP-333.
  start_response: A function with semantics defined in PEP-333.
  url_map: An appinfo.URLMap instance containing the configuration for the
  handler matching this request.
  match: A re.MatchObject containing the result of the matched URL pattern.
  request_id: A unique string id associated with the request.
  request_type: The type of the request. See instance.*_REQUEST module
  constants.

Yields:
  A sequence of strings containing the body of the HTTP response.

The documentation for this class was generated from the following file: