NAME
XAS::Lib::Mixin::Keepalive - A mixin to implement TCP keepalive
SYNOPSIS
use XAS::Class
version => '0.01',
base => 'XAS::Base',
mixin => 'XAS::Lib::Mixin::Keepalive'
;
DESCRIPTION
This module is a mixin class to share code for initializing TCP level keepalives.
METHODS
init_keepalive
This will attempt to define the necessary variables to allow TCP keepalive to function. Not all Perl's and OS's define the necessary values.
enable_keepalive($socket)
This will enable keepalive on the given socket. By default this will initialize keepalive to the RFC minimal, i.e. send a keepalive packet once every 2 hours. If the OS supports it, this will be modified to send up to 3 keepalive packets once every 15 minutes.
This should fix those pesky firewalls...
SEE ALSO
AUTHOR
Kevin L. Esteb, <kevin@kesteb.us>
COPYRIGHT AND LICENSE
Copyright (C) 2014 Kevin L. Esteb
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.
See http://dev.perl.org/licenses/ for more information.