Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
var sys = require('sys');
var fleetdb = require('./fleetdb');
var db = new fleetdb.Database();
db.open('http://127.0.0.1:3400');
var done = 0;
setInterval(function() {
if (done == 100000) {
sys.puts('all done');
db.close();
}
}, 100);
for(var i=0; i<100000; i++) {
db.query(['ping'], function(status, data) {
done += 1
if ((done % 10000) == 0) {
sys.puts('done: ' + done);
}
});
};
sys.puts('all enqueued');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.