提交 52e268f5 编写于 作者: Z zhangxin10

解决RegisterPersistenceThread没有合理的使用offset文件和offset.bak文件

上级 ccbfbe57
......@@ -95,8 +95,12 @@ public class MemoryRegister {
reader = new BufferedReader(new FileReader(file));
String offsetData;
while ((offsetData = reader.readLine()) != null && !"EOF".equals(offsetData)) {
String[] ss = offsetData.split("\t");
entries.put(ss[0], new FileRegisterEntry(ss[0], Integer.valueOf(ss[1]), FileRegisterEntry.FileRegisterEntryStatus.UNREGISTER));
try {
String[] ss = offsetData.split("\t");
entries.put(ss[0], new FileRegisterEntry(ss[0], Integer.valueOf(ss[1]), FileRegisterEntry.FileRegisterEntryStatus.UNREGISTER));
} catch (Exception e) {
continue;
}
}
}
} catch (FileNotFoundException e) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册