- home
- rdoc
- bugs
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.
-
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
$ 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
-
capp gem (libpcap library)
sudo gem install http_connection_monitor
After checking out the source, run:
$ rake newb
This task will install any missing dependencies, run the tests/specs, and generate the RDoc.
(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.