mod-fastcgi und FastCGIExternalServer

Beim Einrichten eines Webservers habe ich mir Gedanken gemacht zur Direktive ‚FastCGIExternalServer‘. Auf hunderten von Seiten wird sie referenziert und verwendet, aber nirgendwo die Funktion oder die Parameter erklärt.

Hier ist die fehlende Dokumentation nun:

 

 

FastCgiExternalServer

Syntax: FastCgiExternalServer filename -host hostname:port
[option ...]
FastCgiExternalServer filename -socket filename [option ...]
Context: server config

The FastCgiExternalServer directive defines filename as an external FastCGI application.  If filename does not begin with a slash (/) then it is assumed to be relative to the ServerRoot.  The filename does not have to exist in the local filesystem.  URIs that Apache resolves to this filename will be handled by this external FastCGI application..

External FastCGI applications are not started by the process manager, they are presumed to be started and managed „external“ to Apache and mod_fastcgi.  The FastCGI devkit provides a simple tool, cgi-fcgi,  for starting FastCGI applications independent of the server (applications can also be self-starting, see the devkit).

-appConnTimeout n (0 seconds)Unix: The number of seconds to wait for a connection to the FastCGI application to complete or 0 to indicate a blocking connect() should be used.  Blocking connect()s have an OS dependent internal timeoutIf the timeout expires, a  SERVER_ERROR results.  For non-zero values, this is the amount of time used in a select() to write to the file descriptor returned by a non-blocking connect().  Non-blocking connect()s are troublesome on many platforms.  See also -idle-timeout, it produces similar results but in a more portable manner.
Windows NT: TCP based applications work as above.  Named pipe based applications (static applications configured without the -port option and dynamic applications) use this value successfully to limit the amount of time to wait for a connection (i.e. its not „troublesome“).  By default, this is 90 seconds (FCGI_NAMED_PIPE_CONNECT_TIMEOUT in mod_fastcgi.h).-idle-timeout n (30 seconds)The number of seconds of FastCGI application inactivity allowed before the request is aborted and the event is logged (at the error LogLevel).  The inactivity timer applies only as long as a connection is pending with the FastCGI application.  If a request is queued to an application, but the application doesn’t respond (by writing and flushing) within this period, the request will be aborted.  If communication is complete with the application but incomplete with the client (the response is buffered), the timeout does not apply.-flush noneForce a write to the client as data is received from the application.  By default, mod_fastcgi buffers data in order to free the application as quickly as possible.-host hostname:port
none
The hostname or IP address and TCP port number (1-65535) the application uses for communication with the web server. The -socket and -host options are mutually exclusive.-pass-header header noneThe name of an HTTP Request Header to be passed in the request environment.  This option makes available the contents of headers which are normally not available (e.g. Authorization) to a CGI environment.-socket filename noneUnix: The filename of the Unix domain socket the application uses for communication with the web server.  The filename is relative to the FastCgiIpcDir.  The -socket and -port options are mutually exclusive.Windows NT:  The name of the named pipe the application uses for communicating with the web server. the name is relative to the FastCgiIpcDir.  The –socket and  -port options are mutually exclusive.