Details
Details
- Reviewers
Alphare - Group Reviewers
hg-reviewers - Commits
- rHGdea766fca7e1: keepalive: remove pycompat.iteritems()
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Branch
- default
- Lint
No Linters Available - Unit
No Unit Test Coverage
( )
Alphare |
hg-reviewers |
No Linters Available |
No Unit Test Coverage |
Path | Packages | |||
---|---|---|---|---|
M | mercurial/keepalive.py (2 lines) |
Commit | Parents | Author | Summary | Date |
---|---|---|---|---|
32ae245b1fd3 | 1a88b4e20849 | Gregory Szorc | Feb 21 2022, 1:10 PM |
Status | Author | Revision | |
---|---|---|---|
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | D12339 ui: use input() directly | |
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg | ||
Closed | indygreg |
host is the host:port spec, as in 'www.cnn.com:8080' as passed in. | host is the host:port spec, as in 'www.cnn.com:8080' as passed in. | ||||
no error occurs if there is no connection to that host.""" | no error occurs if there is no connection to that host.""" | ||||
for h in self._cm.get_all(host): | for h in self._cm.get_all(host): | ||||
self._cm.remove(h) | self._cm.remove(h) | ||||
h.close() | h.close() | ||||
def close_all(self): | def close_all(self): | ||||
"""close all open connections""" | """close all open connections""" | ||||
for host, conns in pycompat.iteritems(self._cm.get_all()): | for host, conns in self._cm.get_all().items(): | ||||
for h in conns: | for h in conns: | ||||
self._cm.remove(h) | self._cm.remove(h) | ||||
h.close() | h.close() | ||||
def _request_closed(self, request, host, connection): | def _request_closed(self, request, host, connection): | ||||
"""tells us that this request is now closed and that the | """tells us that this request is now closed and that the | ||||
connection is ready for another request""" | connection is ready for another request""" | ||||
self._cm.set_ready(connection, True) | self._cm.set_ready(connection, True) |