Explorar o código

delete run_tests_timers

dpacaud %!s(int64=12) %!d(string=hai) anos
pai
achega
728074170e
Modificáronse 1 ficheiros con 0 adicións e 52 borrados
  1. 0 52
      run_timer_tests.js

+ 0 - 52
run_timer_tests.js

@@ -1,52 +0,0 @@
-////////////////////////////////////////////////////
-//
-// Usage : 	node run_tests.js [nb user keys] [nb packets to send per user] [nb Requests Before Wait] [wait time in seconds]
-//
-// Example : 	node run_tests.js 5 50 20 10 
-// It will generate 5 userKeys and will send 50 packet for each userKey. 
-// The process will wait 10 secons every 20 requests
-//
-//
-var dgram = require('dgram'),
-	util = require('util');
-
-var DEBUG = true;
-
-
-
-
-/////////////////////////////////////////////////////////////////////////////
-// Send packets to statsd for each userKeys randomly
-
-// Open udp socket
-var client = dgram.createSocket("udp4");
-
-var send = function(host, port, message, closeSocket) {
-	client.send(message, 0, message.length, port, host, function(err, bytes) {
-		if(err) {
-			client.close();
-			process.stdout.write("\n");
-			console.log("Error when sending packet ! Exit...");
-			process.exit(-1);
-		}
-		if(closeSocket) {
-			process.stdout.write("\n");
-			console.log('Done sending packets.');
-			client.close();
-		}
-		//console.log("Packet sent: " + message);
-	});
-}
-
-console.log("Start sending...");
-
-
-var message = new Buffer("test_timer:256|ms");
-if(DEBUG) console.log("  - packet: " + message);
-
-// Send packet to statsd for this userKey
-process.stdout.write(".");
-
-send("localhost", 8125, message, true);
-	
-