Event-Stats

 view release on metacpan or  search on metacpan

TODO  view on Meta::CPAN

fix bug with C-level callbacks

document API better

gettimeofday isn't portable -- avoid it?

lib/Event/Stats.pm  view on Meta::CPAN

positive.

=item $round_sec = round_seconds($sec)

Statistics are not collected in one second intervals.  This function
converts a *desired* time interval into an *available* time interval.
Units are in seconds.

=item $elapse = total_time($sec)

Due to long-running callbacks, measurement intervals may take longer
than expected.  This function returns the actual clock-time for a
given measurement interval.

=item ($rans, $dies, $elapse) = idle_time($sec)

=item ($runs, $dies, $elapse) = $watcher->stats($sec)

Return statistics for the last $sec seconds of operation.  Three
numbers are returned: the number of times the callback has been
invoked, the number of uncaught exceptions and the number of seconds



( run in 2.996 seconds using v1.01-cache-2.11-cpan-9b1e4054eb1 )