r35608 - in /branches/upstream/libsys-statistics-linux-perl/current: ChangeLog META.yml lib/Sys/Statistics/Linux.pm lib/Sys/Statistics/Linux/ProcStats.pm
ryan52-guest at users.alioth.debian.org
ryan52-guest at users.alioth.debian.org
Sun May 17 21:10:10 UTC 2009
Author: ryan52-guest
Date: Sun May 17 21:10:04 2009
New Revision: 35608
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=35608
Log:
[svn-upgrade] Integrating new upstream version, libsys-statistics-linux-perl (0.50)
Modified:
branches/upstream/libsys-statistics-linux-perl/current/ChangeLog
branches/upstream/libsys-statistics-linux-perl/current/META.yml
branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux.pm
branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux/ProcStats.pm
Modified: branches/upstream/libsys-statistics-linux-perl/current/ChangeLog
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsys-statistics-linux-perl/current/ChangeLog?rev=35608&op=diff
==============================================================================
--- branches/upstream/libsys-statistics-linux-perl/current/ChangeLog (original)
+++ branches/upstream/libsys-statistics-linux-perl/current/ChangeLog Sun May 17 21:10:04 2009
@@ -1,3 +1,7 @@
+0.50 Released at 2009-05-17.
+ - ProcStats: renamed stat "procs_blocked" to "blocked" and added
+ stat "running".
+
0.49 Released at 2009-03-15.
- Just a full version... all tests runs without errors.
Modified: branches/upstream/libsys-statistics-linux-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsys-statistics-linux-perl/current/META.yml?rev=35608&op=diff
==============================================================================
--- branches/upstream/libsys-statistics-linux-perl/current/META.yml (original)
+++ branches/upstream/libsys-statistics-linux-perl/current/META.yml Sun May 17 21:10:04 2009
@@ -1,6 +1,6 @@
---
name: Sys-Statistics-Linux
-version: 0.49
+version: 0.50
author:
- Jonny Schulz
abstract: Front-end module to collect system statistics
@@ -18,7 +18,7 @@
provides:
Sys::Statistics::Linux:
file: lib/Sys/Statistics/Linux.pm
- version: 0.49
+ version: 0.50
Sys::Statistics::Linux::Compilation:
file: lib/Sys/Statistics/Linux/Compilation.pm
version: 0.10
@@ -48,7 +48,7 @@
version: 0.15
Sys::Statistics::Linux::ProcStats:
file: lib/Sys/Statistics/Linux/ProcStats.pm
- version: 0.16
+ version: 0.17
Sys::Statistics::Linux::Processes:
file: lib/Sys/Statistics/Linux/Processes.pm
version: 0.25
Modified: branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux.pm?rev=35608&op=diff
==============================================================================
--- branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux.pm (original)
+++ branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux.pm Sun May 17 21:10:04 2009
@@ -433,7 +433,7 @@
=cut
package Sys::Statistics::Linux;
-our $VERSION = '0.49';
+our $VERSION = '0.50';
use strict;
use warnings;
Modified: branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux/ProcStats.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux/ProcStats.pm?rev=35608&op=diff
==============================================================================
--- branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux/ProcStats.pm (original)
+++ branches/upstream/libsys-statistics-linux-perl/current/lib/Sys/Statistics/Linux/ProcStats.pm Sun May 17 21:10:04 2009
@@ -1,6 +1,6 @@
=head1 NAME
-Sys::Statistics::Linux::ProcStats - Collect linux load average statistics.
+Sys::Statistics::Linux::ProcStats - Collect linux process statistics.
=head1 SYNOPSIS
@@ -23,14 +23,19 @@
For more informations read the documentation of the front-end module L<Sys::Statistics::Linux>.
+=head1 IMPORTANT
+
+I renamed key C<procs_blocked> to C<blocked>!
+
=head1 LOAD AVERAGE STATISTICS
Generated by F</proc/stat> and F</proc/loadavg>.
- new - Number of new processes that were produced per second.
- runqueue - The number of processes waiting for runtime.
- count - The total amount of processes on the system.
- procs_blocked - Number of processes blocked waiting for I/O to complete (Linux 2.5.45 onwards.)
+ new - Number of new processes that were produced per second.
+ runqueue - The number of currently executing kernel scheduling entities (processes, threads).
+ count - The number of kernel scheduling entities that currently exist on the system (processes, threads).
+ blocked - Number of processes blocked waiting for I/O to complete (Linux 2.5.45 onwards).
+ running - Number of processes in runnable state (Linux 2.5.45 onwards).
=head1 METHODS
@@ -89,7 +94,7 @@
use Carp qw(croak);
use Time::HiRes;
-our $VERSION = '0.16';
+our $VERSION = '0.17';
sub new {
my ($class, %opts) = @_;
@@ -151,12 +156,9 @@
my $lavg = $self->_procs;
open my $fh, '<', $file->{loadavg} or croak "$class: unable to open $file->{loadavg} ($!)";
-
- ( $lavg->{runqueue}
- , $lavg->{count}
- ) = (split m@/@, (split /\s+/, <$fh>)[3]);
-
+ ($lavg->{runqueue}, $lavg->{count}) = (split m@/@, (split /\s+/, <$fh>)[3]);
close($fh);
+
return $lavg;
}
@@ -169,12 +171,13 @@
open my $fh, '<', $file->{stat} or croak "$class: unable to open $file->{stat} ($!)";
while (my $line = <$fh>) {
- if ($line =~ /^(processes|procs_blocked)\s+(\d+)/) {
+ if ($line =~ /^processes\s+(\d+)/) {
+ $stat{new} = $1;
+ } elsif ($line =~ /^procs_(blocked|running)\s+(\d+)/) {
$stat{$1} = $2;
}
}
- $stat{new} = delete $stat{processes};
close($fh);
return \%stat;
}
More information about the Pkg-perl-cvs-commits
mailing list