perfsonar-dev - r1615 - trunk/perfsonar/contrib/benchmarking/ls
Subject: perfsonar development work
List archive
- From:
- To:
- Subject: r1615 - trunk/perfsonar/contrib/benchmarking/ls
- Date: Wed, 6 Sep 2006 16:52:48 -0400
Author: boote
Date: 2006-09-06 16:52:47 -0400 (Wed, 06 Sep 2006)
New Revision: 1615
Modified:
trunk/perfsonar/contrib/benchmarking/ls/generateDB.pl
Log:
code clean-up, no changes to active code
Modified: trunk/perfsonar/contrib/benchmarking/ls/generateDB.pl
===================================================================
--- trunk/perfsonar/contrib/benchmarking/ls/generateDB.pl 2006-09-06
20:02:00 UTC (rev 1614)
+++ trunk/perfsonar/contrib/benchmarking/ls/generateDB.pl 2006-09-06
20:52:47 UTC (rev 1615)
@@ -255,99 +255,3 @@
FOOTER
exit 0;
-__END__
-
-$TOTAL = $ARGV[0];
-
-@nameLength=(0..9,9..0);
-
-@ip=(0..255);
-
-@nameArray
= (a..z,A..Z);
-srand;
-
-open(FILE, ">gen" . $TOTAL . ".xml");
-
-print FILE "<?xml version=\'1.0\' encoding=\'UTF-8\'?>\n";
-print FILE "<nmwg:message id=\"msg1\"
xmlns:nmwg=\"http:\/\/ggf.org\/ns\/nmwg\/base\/2.0\/\">\n";
-
-for($x = 0; $x < $TOTAL; $x++) {
- if($TOTAL/10 == 1) {
- $mod = 10;
- }
- else {
- $mod = $TOTAL/10;
- }
-
- if($x % $mod == 0) {
- $MD_ID = genuid();
-
- $nameLen = int(rand scalar(@nameLength));
- $someName = "";
- for($y = 0; $y < $nameLen; $y++) {
- $rand = int(rand scalar(@nameArray));
- $someName = $someName . $nameArray[$rand];
- }
-
-
- print FILE " <nmwg:metadata id=\"$MD_ID\">\n";
- print FILE " <perfsonar:subject id=\"", genuid(), "\"
xmlns:perfsonar=\"http:\/\/ggf.org\/ns\/nmwg\/tools\/org\/perfsonar\/1.0\/\">\n";
- print FILE " <psservice:service id=\"", genuid(), "\"
xmlns:psservice=\"http:\/\/ggf.org\/ns\/nmwg\/tools\/org\/perfsonar\/service\/1.0\/\">\n";
- print FILE " <psservice:serviceName>This is an MA called
$someName.</psservice:serviceName>\n";
- print FILE "
<psservice:accessPoint>http://www.$someName.edu:8080/axis/services/MeasurementArchive</psservice:accessPoint>\n";
- print FILE " <psservice:serviceType>MA</psservice:serviceType>\n";
- print FILE " <psservice:serviceDescription>$someName is a
Measurement Archive located somwhere...</psservice:serviceDescription>\n";
- print FILE " </psservice:service>\n";
- print FILE " </perfsonar:subject>\n";
- print FILE " </nmwg:metadata>\n";n
- }
-
- print FILE " <nmwg:data id=\"", genuid(), "\"
metadataIdRef=\"$MD_ID\">\n";
- print FILE " <nmwg:metadata id=\"", genuid(), "\">\n";
- print FILE " <netutil:subject id=\"", genuid(), "\"
xmlns:netutil=\"http:\/\/ggf.org\/ns\/nmwg\/characteristic\/utilization\/2.0\/\">\n";
- print FILE " <nmwgt:interface
xmlns:nmwgt=\"http:\/\/ggf.org\/ns\/nmwg\/topology\/2.0\/\">\n";
-
- $yum = $x+$nameLen;
-
- $nameLen = int(rand scalar(@nameLength));
- $domain = "";
- $big = "";
- for($y1 = 0; $y1 < $nameLen/2; $y1++) {
- if($y1 != 0) {
- $big = $big . $domain . ".";
- }
- for($y = 0; $y < $nameLen/2; $y++) {
- $rand = int(rand scalar(@nameArray));
- $domain = $domain . $nameArray[$rand/2];
- }
- }
-
-
- print FILE "
<nmwgt:hostName>$big$someName.edu</nmwgt:hostName>\n";
-
- $eth = (($x*$nameLen)/10)+1;
-
- print FILE " <nmwgt:ifName>eth$eth</nmwgt:ifName>\n";
- print FILE " <nmwgt:ifDescription>eth$x/$nameLen Interface on
$big$someName.edu</nmwgt:ifDescription>\n";
-
- $a = $ip[int(rand scalar(@ip))];
- $b = $ip[int(rand scalar(@ip))];
- $c = $ip[int(rand scalar(@ip))];
- $d = $ip[int(rand scalar(@ip))];
-
- print FILE " <nmwgt:ifAddress
type=\"ipv4\">$a.$b.$c.$d</nmwgt:ifAddress>\n";
- print FILE " <nmwgt:capacity>10000000000</nmwgt:capacity>\n";
- print FILE " </nmwgt:interface>\n";
- print FILE " </netutil:subject>\n";
- print FILE "
<nmwg:eventType>interface.utilization</nmwg:eventType>\n";
- print FILE " </nmwg:metadata>\n";
- print FILE " </nmwg:data>\n";
-
-}
-
-print FILE "</nmwg:message>\n";
-
-
-close(FILE);
-
-
- r1615 - trunk/perfsonar/contrib/benchmarking/ls, svnlog, 09/06/2006
Archive powered by MHonArc 2.6.16.