@@ -202,7 +202,7 @@ A basic HTTP request/response cycle looks like this:
202202 * and a :class: `EndOfMessage ` event.
203203
204204And once that's finished, both sides either close the connection, or
205- they go back to the top and re-use it for another request/response
205+ they go back to the top and reuse it for another request/response
206206cycle.
207207
208208To coordinate this interaction, the h11 :class: `Connection ` object
@@ -281,7 +281,7 @@ what's needed to handle the basic request/response cycle:
281281
282282* Server sending a :class: `Response ` directly from :data: `IDLE `: This
283283 is used for error responses, when the client's request never arrived
284- (e.g. 408 Request Timed Out) or was unparseable gibberish (400 Bad
284+ (e.g. 408 Request Timed Out) or was unparsable gibberish (400 Bad
285285 Request) and thus didn't register with our state machine as a real
286286 :class: `Request `.
287287
@@ -471,7 +471,7 @@ There are four cases where these exceptions might be raised:
471471
472472* When calling :meth: `Connection.start_next_cycle `
473473 (:exc: `LocalProtocolError `): This indicates that the connection is
474- not ready to be re-used , because one or both of the peers are not in
474+ not ready to be reused , because one or both of the peers are not in
475475 the :data: `DONE ` state. The :class: `Connection ` object remains
476476 usable, and you can try again later.
477477
@@ -507,7 +507,7 @@ the remote peer. But sometimes, for one reason or another, this
507507doesn't actually happen.
508508
509509Here's a concrete example. Suppose you're using h11 to implement an
510- HTTP client that keeps a pool of connections so it can re-use them
510+ HTTP client that keeps a pool of connections so it can reuse them
511511when possible (see :ref: `keepalive-and-pipelining `). You take a
512512connection from the pool, and start to do a large upload... but then
513513for some reason this gets cancelled (maybe you have a GUI and a user
@@ -518,7 +518,7 @@ successfully sent the full request, because you passed an
518518you didn't, because you never sent the resulting bytes. And then –
519519here's the really tricky part! – if you're not careful, you might
520520think that it's OK to put this connection back into the connection
521- pool and re-use it, because h11 is telling you that a full
521+ pool and reuse it, because h11 is telling you that a full
522522request/response cycle was completed. But this is wrong; in fact you
523523have to close this connection and open a new one.
524524
@@ -605,10 +605,10 @@ cases:
605605
606606.. _keepalive-and-pipelining :
607607
608- Re-using a connection: keep-alive and pipelining
608+ Reusing a connection: keep-alive and pipelining
609609------------------------------------------------
610610
611- HTTP/1.1 allows a connection to be re-used for multiple
611+ HTTP/1.1 allows a connection to be reused for multiple
612612request/response cycles (also known as "keep-alive"). This can make
613613things faster by letting us skip the costly connection setup, but it
614614does create some complexities: we have to keep track of whether a
@@ -635,7 +635,7 @@ these cases -- h11 will automatically add this header when
635635necessary. Just worry about setting it when it's actually something
636636that you're actively choosing.
637637
638- If you want to re-use a connection, you have to wait until both the
638+ If you want to reuse a connection, you have to wait until both the
639639request and the response have been completed, bringing both the client
640640and server to the :data: `DONE ` state. Once this has happened, you can
641641explicitly call :meth: `Connection.start_next_cycle ` to reset both
@@ -651,7 +651,7 @@ skip past the :data:`DONE` state directly to the :data:`MUST_CLOSE` or
651651thing you can legally do is to close this connection and make a new
652652one.
653653
654- HTTP/1.1 also allows for a more aggressive form of connection re-use ,
654+ HTTP/1.1 also allows for a more aggressive form of connection reuse ,
655655in which a client sends multiple requests in quick succession, and
656656then waits for the responses to stream back in order
657657("pipelining"). This is generally considered to have been a bad idea,
0 commit comments