HTTP::Server::Simple::RecorderHTTP::Server::Simple::Recorder is Perl module for mixin to record HTTP::Server::Simple's sockets. | |
Download |
HTTP::Server::Simple::Recorder Ranking & Summary
Advertisement
- License:
- Perl Artistic License
- Price:
- FREE
- Publisher Name:
- David Glasser
- Publisher web site:
- http://search.cpan.org/~glasser/HTTP-Server-Simple-Recorder-0.02/lib/HTTP/Server/Simple/Recorder.pm
HTTP::Server::Simple::Recorder Tags
HTTP::Server::Simple::Recorder Description
HTTP::Server::Simple::Recorder is Perl module for mixin to record HTTP::Server::Simple's sockets. HTTP::Server::Simple::Recorder is Perl module for mixin to record HTTP::Server::Simple's sockets.SYNOPSIS package MyServer; use base qw/HTTP::Server::Simple::Recorder HTTP::Server::Simple::CGI/; sub recorder_prefix { "path/to/logs/record" } # defaults to /tmp/http-server-simple-recorder # logs to path/to/logs/record.34244.1.in, # path/to/logs/record.34244.1.out, # path/to/logs/record.34244.2.in, # path/to/logs/record.34244.2.out, etc, if 34244 is the PID of the serverThis module allows you to record all HTTP communication between an HTTP::Server::Simple-derived server and its clients. It is a mixin, so it doesn't itself subclass HTTP::Server::Simple; you need to subclass from both HTTP::Server::Simple::Recorder and an actual HTTP::Server::Simple subclass, and HTTP::Server::Simple::Recorder should be listed first.Every time a client connects to your server, this module will open a pair of files and log the communication between the file and server to these files. Each connection gets a serial number starting at 1. The filename used is >, then a period, then the connection serial number, then a period, then either "in" or "out". recorder_prefix defaults to /tmp/http-server-simple-recorder, but you can override that in your subclass. For example, you might want to include the process ID. Requirements: · Perl · IO::Tee · HTTP::Server::Simple
HTTP::Server::Simple::Recorder Related Software