Always specify header of connection keep-alive regardless of python v… (#62218)

* Always specify header of connection keep-alive regardless of python version.

* Add chgangelog fragment

* Fixes to changelog fragment
This commit is contained in:
Chris Trufan 2019-09-12 15:05:23 -04:00 committed by Felix Fontein
parent 6952295114
commit 606e13919e
2 changed files with 7 additions and 1 deletions

View file

@ -0,0 +1,3 @@
bugfixes:
- "openssl_certificate - When provider is ``entrust``, use a ``connection: keep-alive`` header for ECS API connections."
- "ecs_certificate - Always specify header ``connection: keep-alive`` for ECS API connections."

View file

@ -241,7 +241,10 @@ class ECSSession(object):
return resource
def _set_config(self, name, **kwargs):
headers = {"Content-Type": "application/json"}
headers = {
"Content-Type": "application/json",
"Connection": "keep-alive",
}
self.request = Request(headers=headers, timeout=60)
configurators = [self._read_config_vars]