perfsonar-dev - [pS-dev] [GEANT/SA2/SA2T3-OPPD] r784 - branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP
Subject: perfsonar development work
List archive
[pS-dev] [GEANT/SA2/SA2T3-OPPD] r784 - branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP
Chronological Thread
- From:
- To:
- Subject: [pS-dev] [GEANT/SA2/SA2T3-OPPD] r784 - branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP
- Date: Wed, 19 Dec 2012 12:26:21 +0000 (GMT)
Author: dfn.calim
Date: 2012-12-19 12:26:21 +0000 (Wed, 19 Dec 2012)
New Revision: 784
Modified:
branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP/OWAMP.pm
Log:
solving nan value in delays fields
Modified: branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP/OWAMP.pm
===================================================================
--- branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP/OWAMP.pm 2012-12-17
11:10:17 UTC (rev 783)
+++ branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP/OWAMP.pm 2012-12-19
12:26:21 UTC (rev 784)
@@ -288,9 +288,6 @@
/one-way delay min\/median\/max =
(\S+\/\S+\/\S+)\s+(\w+),\s+\((.+)\)/){
my $delay = $1;
my ($min,$med,$max) = split ("/", $delay);
- $data_hash{"min_delay"} = $min;
- $data_hash{"med_delay"} = $med;
- $data_hash{"max_delay"} = $max;
$data_hash{"timeType"} = $2;
if ( $3 =~
# unsynchronized
@@ -301,6 +298,13 @@
/err=(.+)\s+(\w+)/){
$data_hash{"maxError"} = $1;
}
+ #Sometime occur for delay nan adjust it to schema NaN
+ $min = "NaN" if $min =~ m/nan/;
+ $med = "NaN" if $med =~ m/nan/;
+ $max = "NaN" if $max =~ m/nan/;
+ $data_hash{"min_delay"} = $min;
+ $data_hash{"med_delay"} = $med;
+ $data_hash{"max_delay"} = $max;
#$data_hash{"error_units"} = $4;
#push @datalines, \%data_hash;
}elsif ($resultline =~
@@ -317,6 +321,7 @@
}elsif ($resultline =~
#TTL not reported
/TTL not reported/){
+ $data_hash{"hops"} = 0; #No hops
last;
}else { next; }
}#End foreach
- [pS-dev] [GEANT/SA2/SA2T3-OPPD] r784 - branches/perfsonar-oppd-all-0.53/lib/perfSONAR/MP, svn-noreply, 12/19/2012
Archive powered by MHonArc 2.6.16.