remove useless config, and make sure file writer is flush.

This commit is contained in:
wusheng 2016-11-29 22:22:31 +08:00
parent fe1702da36
commit 24f133d8e2
2 changed files with 6 additions and 14 deletions

View File

@ -13,16 +13,6 @@ public class Config {
}
public static class DataConsumer {
public static int CHANNEL_SIZE = 10;
public static int BUFFER_SIZE = 1000;
public static int CONSUMER_SIZE = 5;
}
public static class DataFile {
public static String PATH = "/data/file";

View File

@ -20,12 +20,14 @@ public class DataFileWriter {
}
IndexMetaCollection collections = new IndexMetaCollection();
for (SpanData data : spanData) {
collections.add(dataFile.write(data));
try {
for (SpanData data : spanData) {
collections.add(dataFile.write(data));
}
}finally {
dataFile.flush();
}
dataFile.flush();
return collections;
}