Start with a fresh DB when doing benchmark

This commit is contained in:
Jonathan Leibiusky
2010-08-08 15:21:59 -03:00
parent 048d87d26c
commit 8d8c5131f1
2 changed files with 3 additions and 1 deletions

View File

@@ -14,6 +14,7 @@ public class GetSetBenchmark {
Jedis jedis = new Jedis("localhost");
jedis.connect();
jedis.auth("foobared");
jedis.flushAll();
long begin = Calendar.getInstance().getTimeInMillis();

View File

@@ -8,13 +8,14 @@ import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPipeline;
public class PipelinedGetSetBenchmark {
private static final int TOTAL_OPERATIONS = 100000;
private static final int TOTAL_OPERATIONS = 200000;
public static void main(String[] args) throws UnknownHostException,
IOException {
Jedis jedis = new Jedis("localhost");
jedis.connect();
jedis.auth("foobared");
jedis.flushAll();
long begin = Calendar.getInstance().getTimeInMillis();