proxyhunter
view release on metacpan or search on metacpan
bin/proxyhunter view on Meta::CPAN
=head2 speed_checkdate
Date and time when last speed check was performed
=head2 fails
How much failed checks in a row was performed. Each successful check resets this counter
=head2 type
Type of the proxy. One of C<HTTPS_PROXY>, C<HTTP_PROXY>, C<CONNECT_PROXY>, C<SOCKS4_PROXY>, C<SOCKS5_PROXY>, C<DEAD_PROXY>.
Not checked proxy has C<DEAD_PROXY> type. See L<Net::Proxy::Type> for proxy types description.
=head2 in_progress
Is proxy in the queue for check
=head2 conn_time
Connection time to this proxy host
lib/App/ProxyHunter.pm view on Meta::CPAN
unless ($type == DEAD_PROXY || $type == UNKNOWN_PROXY) {
return ($type, $conn_time);
}
}
return;
}
my %uri_scheme = (
&HTTP_PROXY => 'http',
&CONNECT_PROXY => 'connect',
&HTTPS_PROXY => 'connect',
&SOCKS4_PROXY => 'socks4',
&SOCKS5_PROXY => 'socks',
);
sub _check_speed {
my ($class, $checker, $config, $proxy) = @_;
$checker->proxy(['http', 'https'] => sprintf('%s://%s:%s', $uri_scheme{$proxy->type}, $proxy->host, $proxy->port));
( run in 1.011 second using v1.01-cache-2.11-cpan-d7a12ab2c7f )