papertrail / papertrail-cli

Command-line client for Papertrail hosted syslog & app log management service
http://papertrailapp.com/
MIT License
427 stars 46 forks source link

Use HTTP Keep-Alive when possible #99

Closed markdascher closed 6 years ago

markdascher commented 6 years ago

Adds start and finish methods to Papertrail::HttpClient and Papertrail::Connection, mimicking Net::HTTP#start. I wanted to use Forwardable/def_delegators, but needed a different return or yield value.

Modified any CLI tool that makes multiple API calls, but it's primarily intended for papertrail -f. With HTTP Keep-Alive, we can avoid renegotiating a separate TLS connection every two seconds.

jshawl commented 6 years ago

oo should also bump gem spec ver - https://github.com/papertrail/papertrail-cli/blob/4a38d8e5c19d5b10c9ded25c5a2557b5636a888d/papertrail.gemspec#L12