You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ji...@apache.org on 2019/06/24 06:19:49 UTC
[incubator-iotdb] branch feature_async_close_tsfile updated: fix a
null pointer problem in deletion
This is an automated email from the ASF dual-hosted git repository.
jiangtian pushed a commit to branch feature_async_close_tsfile
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git
The following commit(s) were added to refs/heads/feature_async_close_tsfile by this push:
new 417fa76 fix a null pointer problem in deletion
417fa76 is described below
commit 417fa761a99751ab83b2776326389a1e64c204d9
Author: 江天 <jt...@163.com>
AuthorDate: Mon Jun 24 14:17:43 2019 +0800
fix a null pointer problem in deletion
---
.../org/apache/iotdb/db/engine/filenodeV2/FileNodeProcessorV2.java | 7 +++----
.../java/org/apache/iotdb/db/qp/executor/OverflowQPExecutor.java | 2 +-
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/iotdb/src/main/java/org/apache/iotdb/db/engine/filenodeV2/FileNodeProcessorV2.java b/iotdb/src/main/java/org/apache/iotdb/db/engine/filenodeV2/FileNodeProcessorV2.java
index 1ff260d..42aeb87 100755
--- a/iotdb/src/main/java/org/apache/iotdb/db/engine/filenodeV2/FileNodeProcessorV2.java
+++ b/iotdb/src/main/java/org/apache/iotdb/db/engine/filenodeV2/FileNodeProcessorV2.java
@@ -379,11 +379,10 @@ public class FileNodeProcessorV2 {
List<ModificationFile> updatedModFiles = new ArrayList<>();
try {
- long lastUpdateTime = latestTimeForEachDevice.get(deviceId);
+ Long lastUpdateTime = latestTimeForEachDevice.get(deviceId);
// no tsfile data, the delete operation is invalid
- if (lastUpdateTime == Long.MIN_VALUE) {
- LOGGER.warn("The last update time is -1, delete overflow is invalid, "
- + "the storage group is {}", storageGroupName);
+ if (lastUpdateTime == null || lastUpdateTime == Long.MIN_VALUE) {
+ LOGGER.debug("No device {} in SG {}, deletion invalid", deviceId, storageGroupName);
return;
}
diff --git a/iotdb/src/main/java/org/apache/iotdb/db/qp/executor/OverflowQPExecutor.java b/iotdb/src/main/java/org/apache/iotdb/db/qp/executor/OverflowQPExecutor.java
index 5ce697a..1c1b908 100644
--- a/iotdb/src/main/java/org/apache/iotdb/db/qp/executor/OverflowQPExecutor.java
+++ b/iotdb/src/main/java/org/apache/iotdb/db/qp/executor/OverflowQPExecutor.java
@@ -521,7 +521,7 @@ public class OverflowQPExecutor extends QueryProcessExecutor {
throw new ProcessorException("unknown namespace type:" + namespaceType);
}
} catch (PathErrorException | IOException | FileNodeManagerException e) {
- throw new ProcessorException(e.getMessage());
+ throw new ProcessorException(e);
}
return true;
}