Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
By using a session object we can reuse the tcp connection. We use one session per domain. There is some uncertainty about the thread safety of Session (psf/requests#2766), but it seems to work well when not making requests to many different domains (1 in our case).
- Loading branch information
Showing
3 changed files
with
17 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters