You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by li...@apache.org on 2019/06/13 09:45:39 UTC
[incubator-iotdb] branch
test_fix_nativeRestoreTsFileWriter_if_file_is_complete created (now
34c3a5f)
This is an automated email from the ASF dual-hosted git repository.
liurui pushed a change to branch test_fix_nativeRestoreTsFileWriter_if_file_is_complete
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git.
at 34c3a5f test NativeRestorableIOWriter
This branch includes the following new commits:
new 34c3a5f test NativeRestorableIOWriter
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[incubator-iotdb] 01/01: test NativeRestorableIOWriter
Posted by li...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
liurui pushed a commit to branch test_fix_nativeRestoreTsFileWriter_if_file_is_complete
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git
commit 34c3a5f6eb1133699357b0512d68236575af07b2
Author: liuruiyiyang <24...@qq.com>
AuthorDate: Thu Jun 13 17:45:11 2019 +0800
test NativeRestorableIOWriter
---
.../iotdb/tsfile/write/writer/NativeRestorableIOWriter.java | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/tsfile/src/main/java/org/apache/iotdb/tsfile/write/writer/NativeRestorableIOWriter.java b/tsfile/src/main/java/org/apache/iotdb/tsfile/write/writer/NativeRestorableIOWriter.java
index 9281ff7..b59682a 100644
--- a/tsfile/src/main/java/org/apache/iotdb/tsfile/write/writer/NativeRestorableIOWriter.java
+++ b/tsfile/src/main/java/org/apache/iotdb/tsfile/write/writer/NativeRestorableIOWriter.java
@@ -122,4 +122,17 @@ public class NativeRestorableIOWriter extends TsFileIOWriter {
public void endFile() throws IOException {
super.endFile(new FileSchema(knownSchemas));
}
+
+ public static void main(String[] args) {
+ String path = args[0];
+ String append = args[1];
+ try {
+ long start = System.currentTimeMillis();
+ new NativeRestorableIOWriter(new File(path), Boolean.parseBoolean(append));
+ long elapse = System.currentTimeMillis() - start;
+ System.out.println("new NativeRestorableIOWriter cost " + elapse + " ms");
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ }
}