W3C home > Mailing lists > Public > ietf-http-wg-old@w3.org > September to December 1995

Re: Persistent connections: aborting requests in progress.

From: Jeffrey Mogul <mogul@pa.dec.com>
Date: Mon, 25 Sep 95 10:03:07 MDT
Message-Id: <9509251703.AA26970@acetes.pa.dec.com>
To: Paul Leach <paulle@microsoft.com>
Cc: http-wg%cuckoo.hpl.hp.com@hplb.hpl.hp.com
Paul and I alternate (excerpts only):

    ]     a. Send request
    ]     b. Receive first buffer(s) of response; enough to see that no further
    ]     negotiation (e.g., authentication) or other packet exchanges are
    ]     required for this request.
    ]     c. Send next request (perhaps based on the contents of the immediatelty
    ]     or some other previous response)
    ]
    ] we skipped step (b).
    
    One can skip step b) if one can tell in advance that it won't be 
    required, or that failure to wait when one should have can be recovered 
    from safely.  I take your "presumably" to mean that most of the time 
    everything falls out because initial requests aren't typically 
    pipelinable -- but I wouldn't want to depend on being able to omit step 
    b) in all cases.

An observation: the same potential problem arises for the "fire off N
parallel connections at once" approach, right?  That is, any form of
pipelining suffers from the possibility of a fault.  CPU designers
know this; their pipelines know how to "squash" instructions in progress,
restart them, insert bubbles, do "imprecise exceptions", etc.

I suspect that in most cases, the worst thing that can happen is that
one or more retrieval requests result in "soft" (retryable) error returns,
in which case the client knows what to do.  The only time this could be
a real problem is if certain requests must be executed in a particular
order, in which case pipelining is not advised.  (In modern RISC machines,
the solution is to insert "trap barriers" to force synchronization.)

    So, in order to make things robust, we'd either need to document some 
    restrictions that make skipping b) always safe, or know in advance when 
    it is safe to skip and handle the unsafe cases by waiting to complete 
    the negotiation, or figuring out how to recover if the server gets a 
    GET in response to a request to negotiate something -- maybe just 
    draining the pipe until the client's request-aheads are all gone and 
    the correct response to the negotiation arrives would work, and perform 
    well if it doesn't happen very often.

I think your last suggestion best fits the CPU-pipeline analogy.

-Jeff
    
    
Received on Monday, 25 September 1995 10:30:17 EDT

This archive was generated by hypermail pre-2.1.9 : Wednesday, 24 September 2003 06:31:32 EDT