Skip to content
This repository has been archived by the owner on Nov 15, 2022. It is now read-only.

Monitors your outbound HTTP requests for number of requests made over a persistent connection.

Notifications You must be signed in to change notification settings

fastly/http_connection_monitor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

http_connection_monitor

home

github.com/fastly/http_connection_monitor

rdoc

docs.seattlerb.org/http_connection_monitor

bugs

github.com/fastly/http_connection_monitor/issues

Description

Monitors your outbound HTTP requests for number of requests made over a persistent connection. This will help you find inefficiencies in your use of HTTP.

Features

  • Calculates per-destination and aggregate statistics

  • Allows offline processing of pcap dump files for easy use in production

  • Can drop root privileges after opening the packet capture devices

  • Allows capture from multiple ports and devices simultaneously

Synopsis

$ sudo http_connection_monitor

This will capture HTTP packets outbound on port 80 using the default interface.

$ sudo http_connection_monitor --port 80,3000 -i en0 -i en1

This will capture HTTP packets outbound on ports 80 and 3000 on interfaces en0 and en1.

$ http_connection_monitor --port 80,3000 --show-filter
((tcp dst port 80) or (tcp src port 80 and (tcp[tcpflags] & tcp-fin != 0))) \
or \
((tcp dst port 3000) or (tcp src port 3000 and (tcp[tcpflags] & tcp-fin != 0)))

This will display the filter you need to use in tcpdump if you don’t wish to install http_connection_monitor on your production servers. You can then process the packets offline:

$ http_connection_monitor -i production_packets.pcap --port 80,3000

Requirements

  • capp gem (libpcap library)

Install

sudo gem install http_connection_monitor

Developers

After checking out the source, run:

$ rake newb

This task will install any missing dependencies, run the tests/specs, and generate the RDoc.

License

(The MIT License)

Copyright © Fastly, Inc.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ‘Software’), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED ‘AS IS’, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

Monitors your outbound HTTP requests for number of requests made over a persistent connection.

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages