gecko/netwerk/protocol/http
Patrick McManus fdc1d8023e bug 769264 pipeline logging cleanups r=honzab
--HG--
extra : rebase_source : fc747b84349096b70d8b75d8aff8626826380d81
2012-07-02 18:10:04 -04:00
..
ASpdySession.cpp bug 764260 convert telemetry::SPDY_VERSION and DNS_LOOKUP_METHOD to be enumerations r=bsmith 2012-06-19 20:38:44 -04:00
ASpdySession.h bug 737470 new spdy v3 files had old mpl header r=trivial 2012-05-30 12:23:05 -04:00
HttpBaseChannel.cpp Bug 713026 - websockets bootstrap via proxy should always CONNECT. r=mcmanus 2012-06-18 22:50:20 -07:00
HttpBaseChannel.h Bug 722034 - Part 3 - Convert HttpBaseChannel::mRedirectedCachekeys to nsAutoPtr<nsTArray<nsCString> >, r=biesi 2012-05-31 15:20:05 -07:00
HttpChannelChild.cpp Bug 722845 - Part 4: Add PB information to wyciwyg channels. r=jduell 2012-05-24 16:31:54 +01:00
HttpChannelChild.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
HttpChannelParent.cpp Bug 722845 - Part 1: Add private browsing information to HTTP channels. r=jduell,mayhemer 2012-05-24 16:31:53 +01:00
HttpChannelParent.h Bug 722845 - Part 1: Add private browsing information to HTTP channels. r=jduell,mayhemer 2012-05-24 16:31:53 +01:00
HttpChannelParentListener.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
HttpChannelParentListener.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
ipdl.mk Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
Makefile.in bug 737470 patch 2 clone spdy/2 into spdy/3 r=honzab 2012-05-25 17:37:08 -04:00
nsAHttpConnection.h bug 757882 replace 250+ lines of redundant nsAHttpConnection implementations with macros r=jduell 2012-05-25 17:56:41 -04:00
nsAHttpTransaction.h Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
nsHttp.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttp.h Bug 672448 - Clamp quality factor ('q') values to 3 decimal places. r=biesi 2012-06-09 19:01:59 -04:00
nsHttpActivityDistributor.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpActivityDistributor.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpAtomList.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpAuthCache.cpp Bug 743581: Removes nsCRT::strlen(const PRUnichar*). f=sgautherie r=dougt 2012-05-30 18:43:39 +01:00
nsHttpAuthCache.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpAuthManager.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpAuthManager.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpBasicAuth.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpBasicAuth.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpChannel.cpp Bug 761228: Fix 304 response handling for custom conditional responses to prevent crash, r=jduell 2012-06-28 12:34:32 -07:00
nsHttpChannel.h Bug 764171: Fix crash in nsStorageStream by avoiding pre-buffering for items we will validate, r=honzab 2012-06-28 12:18:25 -07:00
nsHttpChannelAuthProvider.cpp Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
nsHttpChannelAuthProvider.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpChunkedDecoder.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpChunkedDecoder.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpConnection.cpp bug 769264 pipeline logging cleanups r=honzab 2012-07-02 18:10:04 -04:00
nsHttpConnection.h bug 766312 - part 1 - pipeline cancelation could be "undone" r=honzab 2012-06-28 18:06:32 -04:00
nsHttpConnectionInfo.cpp Bug 713026 - websockets bootstrap via proxy should always CONNECT. r=mcmanus 2012-06-18 22:50:20 -07:00
nsHttpConnectionInfo.h Bug 713026 - websockets bootstrap via proxy should always CONNECT. r=mcmanus 2012-06-18 22:50:20 -07:00
nsHttpConnectionMgr.cpp bug 769264 pipeline logging cleanups r=honzab 2012-07-02 18:10:04 -04:00
nsHttpConnectionMgr.h Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
nsHttpDigestAuth.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpDigestAuth.h Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
nsHttpHandler.cpp Bug 728831 - Don't expose the Firefox patch level (13.X.Y) in the UA string, only show the major version (13.X). r=bz sr=gavin 2012-06-22 13:52:47 +02:00
nsHttpHandler.h Bug 728831 - Don't expose the Firefox patch level (13.X.Y) in the UA string, only show the major version (13.X). r=bz sr=gavin 2012-06-22 13:52:47 +02:00
nsHttpHeaderArray.cpp Bug 759019 - Make nsHttpResponseHead and nsHttpRequestHead copy-constructable, assignable, and const-correct, r=biesi 2012-04-05 01:21:02 -07:00
nsHttpHeaderArray.h Bug 759019 - Make nsHttpResponseHead and nsHttpRequestHead copy-constructable, assignable, and const-correct, r=biesi 2012-04-05 01:21:02 -07:00
nsHttpNTLMAuth.cpp Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
nsHttpNTLMAuth.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpPipeline.cpp bug 763312 pipeline position 0 read time rescheduling fixes r=honzab 2012-06-29 14:24:29 -04:00
nsHttpPipeline.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpRequestHead.cpp Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsHttpRequestHead.h Bug 759019 - Make nsHttpResponseHead and nsHttpRequestHead copy-constructable, assignable, and const-correct, r=biesi 2012-04-05 01:21:02 -07:00
nsHttpResponseHead.cpp Bug 746018 - Part 6 - Start buffering cache entries in memory before we validate them, r=honzab 2012-05-31 15:20:04 -07:00
nsHttpResponseHead.h Bug 759019 - Make nsHttpResponseHead and nsHttpRequestHead copy-constructable, assignable, and const-correct, r=biesi 2012-04-05 01:21:02 -07:00
nsHttpTransaction.cpp bug 763312 pipeline position 0 read time rescheduling fixes r=honzab 2012-06-29 14:24:29 -04:00
nsHttpTransaction.h Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
nsIHttpActivityObserver.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpAuthenticableChannel.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpAuthenticator.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpAuthManager.idl Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
nsIHttpChannel.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpChannelAuthProvider.idl Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
nsIHttpChannelChild.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpChannelInternal.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpEventSink.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpHeaderVisitor.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
nsIHttpProtocolHandler.idl Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
NullHttpTransaction.cpp Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
NullHttpTransaction.h Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
PHttpChannel.ipdl Bug 722845 - Part 1: Add private browsing information to HTTP channels. r=jduell,mayhemer 2012-05-24 16:31:53 +01:00
PHttpChannelParams.h Bug 759019 - Make nsHttpResponseHead and nsHttpRequestHead copy-constructable, assignable, and const-correct, r=biesi 2012-04-05 01:21:02 -07:00
README
SpdySession2.cpp Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
SpdySession2.h Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
SpdySession3.cpp Backout d45ca69b67a3 (bug 767516), 4ff98d3e4d8d (bug 767512), 70cc47076115 (bug 767505), 4eca26d02c84 (bug 766929) for mochitest-plain-5 failures 2012-06-25 21:38:10 +01:00
SpdySession3.h Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
SpdyStream2.cpp bug 737470 patch 3 implement spdy v3 (pref off) r=honzab 2012-05-25 17:43:10 -04:00
SpdyStream2.h Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
SpdyStream3.cpp bug 737470 new spdy v3 files had old mpl header r=trivial 2012-05-30 12:23:05 -04:00
SpdyStream3.h Bug 758992 - Make the classes which use the XPCOM nsISupports implementation macros final, to avoid the warning about deleting using a pointer to a base class with virtual functions and no virtual dtor (netwerk parts); r=jduell 2012-06-05 23:18:25 -04:00
TimingStruct.h Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00

                                                        Darin Fisher
                                                        darin@netscape.com
                                                        8/8/2001

                            HTTP DESIGN NOTES


CLASS BREAKDOWN

  nsHttpHandler
    - implements nsIProtocolHandler
    - manages preferences
    - owns the authentication cache
    - holds references to frequently used services

  nsHttpChannel
    - implements nsIHttpChannel
    - talks to the cache
    - initiates http transactions
    - processes http response codes
    - intercepts progress notifications
  
  nsHttpConnection
    - implements nsIStreamListener & nsIStreamProvider
    - talks to the socket transport service
    - feeds data to its transaction object
    - routes progress notifications

  nsHttpConnectionInfo
    - identifies a connection

  nsHttpTransaction
    - implements nsIRequest
    - encapsulates a http request and response
    - parses incoming data

  nsHttpChunkedDecoder
    - owned by a transaction
    - removes chunked decoding
  
  nsHttpRequestHead
    - owns a nsHttpHeaderArray
    - knows how to fill a request buffer

  nsHttpResponseHead
    - owns a nsHttpHeaderArray
    - knows how to parse response lines
    - performs common header manipulations/calculations

  nsHttpHeaderArray
    - stores http "<header>:<value>" pairs

  nsHttpAuthCache
    - stores authentication credentials for http auth domains

  nsHttpBasicAuth
    - implements nsIHttpAuthenticator
    - generates BASIC auth credentials from user:pass


ATOMS

  nsHttp:: (header namespace)

  eg. nsHttp::Content_Length


TRANSACTION MODEL

  InitiateTransaction -> ActivateConnection -> AsyncWrite, AsyncRead

  The channel creates transactions, and passes them to the handler via
  InitiateTransaction along with a nsHttpConnectionInfo object 
  identifying the requested connection.  The handler either dispatches
  the transaction immediately or queues it up to be dispatched later,
  depending on whether or not the limit on the number of connections
  to the requested server has been reached.  Once the transaction can
  be run, the handler looks for an idle connection or creates a new
  connection, and then (re)activates the connection, assigning it the
  new transaction.

  Once activated the connection ensures that it has a socket transport,
  and then calls AsyncWrite and AsyncRead on the socket transport.  This
  begins the process of talking to the server.  To minimize buffering,
  socket transport thread-proxying is completely disabled (using the flags
  DONT_PROXY_LISTENER | DONT_PROXY_PROVIDER | DONT_PROXY_OBSERVER with
  both AsyncWrite and AsyncRead).  This means that the nsHttpConnection's
  OnStartRequest, OnDataAvailable, OnDataWritable, and OnStopRequest
  methods will execute on the socket transport thread.

  The transaction defines (non-virtual) OnDataReadable, OnDataWritable, and
  OnStopTransaction methods, which the connection calls in response to
  its OnDataAvailable, OnDataWritable, and OnStopRequest methods, respectively.
  The transaction owns a nsStreamListenerProxy created by the channel, which
  it uses to transfer data from the socket thread over to the client's thread.
  To mimize buffering, the transaction implements nsIInputStream, and passes
  itself to the stream listener proxy's OnDataAvailable.  In this way, we
  have effectively wedged the response parsing between the socket and the
  thread proxy's buffer.  When read, the transaction turns around and reads
  from the socket using the buffer passed to it.  The transaction scans the
  buffer for headers, removes them as they are detected, and copies the headers
  into its nsHttpResponseHead object.  The rest of the data remains in the
  buffer, and is proxied over to the client's thread to be handled first by the
  http channel and eventually by the client.

  There are several other major design factors, including:

    - transaction cancelation
    - progress notification
    - SSL tunneling
    - chunked decoding
    - thread safety
    - premature EOF detection and transaction restarting
    - pipelining (not yet implemented)


CACHING

<EOF>