scalien/scaliendb — Issue #385: Writing over the BatchLimit performance
Author: alippai
Created: 2012-02-24 09:51:38+00:00
State: open

Writing over the BatchLimit extreme fall in performance:

```java
for(int tests = 1; tests <= 16*1024; tests *=2) {
client.setBatchLimit(tests*128);
Database db = client.getDatabase(databaseName);
Table table = db.getTable(tableName);

long start = System.nanoTime();
// write document 10000 times
for(int i = 1; i < 10000; i++) {
table.set("a", ""+i);
}
// and submit
client.submit();
long end = System.nanoTime();

System.out.println("Size:\t" + tests + "\t" + (end - start)/1000/1000);
}
```

Output

```
Size:	1	8964
Size:	2	9706
Size:	4	9729
Size:	8	42
Size:	16	19
Size:	32	23
Size:	64	43
Size:	128	18
Size:	256	21
Size:	512	37
Size:	1024	17
Size:	2048	20
Size:	4096	17
Size:	8192	41
Size:	16384	15
```