testing/xpcshell/node-http2/lib/index.js

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

     1 // [node-http2][homepage] is an [HTTP/2 (draft 10)][http2] implementation for [node.js][node].
     2 //
     3 // The core of the protocol is implemented by the [http2-protocol] module. This module provides
     4 // two important features on top of http2-protocol:
     5 //
     6 // * Implementation of different negotiation schemes that can be used to start a HTTP2 connection.
     7 //   These include TLS ALPN, Upgrade and Plain TCP.
     8 //
     9 // * Providing an API very similar to the standard node.js [HTTPS module API][node-https]
    10 //   (which is in turn very similar to the [HTTP module API][node-http]).
    11 //
    12 // [homepage]:            https://github.com/molnarg/node-http2
    13 // [http2-protocol]:      https://github.com/molnarg/node-http2-protocol
    14 // [http2]:               http://tools.ietf.org/html/draft-ietf-httpbis-http2-10
    15 // [node]:                http://nodejs.org/
    16 // [node-https]:          http://nodejs.org/api/https.html
    17 // [node-http]:           http://nodejs.org/api/http.html
    19 module.exports   = require('./http');
    21 /*
    22                   HTTP API
    24                |            ^
    25                |            |
    26  +-------------|------------|------------------------------------------------------+
    27  |             |            |        Server/Agent                                  |
    28  |             v            |                                                      |
    29  |        +----------+ +----------+                                                |
    30  |        | Outgoing | | Incoming |                                                |
    31  |        | req/res. | | req/res. |                                                |
    32  |        +----------+ +----------+                                                |
    33  |             |            ^                                                      |
    34  |             |            |                                                      |
    35  |   +---------|------------|-------------------------------------+   +-----       |
    36  |   |         |            |   Endpoint                          |   |            |
    37  |   |         |            |                                     |   |            |
    38  |   |         v            |                                     |   |            |
    39  |   |    +-----------------------+  +--------------------        |   |            |
    40  |   |    |        Stream         |  |         Stream      ...    |   |            |
    41  |   |    +-----------------------+  +--------------------        |   |            |
    42  |   |                                                            |   |            |
    43  |   +------------------------------------------------------------+   +-----       |
    44  |                             |        |                                          |
    45  |                             |        |                                          |
    46  |                             v        |                                          |
    47  |   +------------------------------------------------------------+   +-----       |
    48  |   |                         TCP stream                         |   |      ...   |
    49  |   +------------------------------------------------------------+   +-----       |
    50  |                                                                                 |
    51  +---------------------------------------------------------------------------------+
    53 */

mercurial