How to prevent keep-alive in a HTTP 1.1 request?

7k views Asked by At

I'm implementing a simple HTTP client.

Which header should I add to a HTTP 1.1 request so it won't keep alive?

1

There are 1 answers

0
Opal On BEST ANSWER

You need to add header: Connection: close. Currently all connections are permanent and client must explicitly claim that it wants to close the connection.