This is an automated email from the ASF dual-hosted git repository.
tanxinyu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git
The following commit(s) were added to refs/heads/master by this push:
new 872aca3138d [region migration] Fix exception capture processing logic
#13034
872aca3138d is described below
commit 872aca3138d2316c8ea6e31cf8f97e35664a05a6
Author: Xiangpeng Hu <[email protected]>
AuthorDate: Fri Jul 26 10:46:01 2024 +0800
[region migration] Fix exception capture processing logic #13034
---
.../db/queryengine/execution/executor/RegionReadExecutor.java | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/execution/executor/RegionReadExecutor.java
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/execution/executor/RegionReadExecutor.java
index 016c3ed21fb..3b6a0f0adb0 100644
---
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/execution/executor/RegionReadExecutor.java
+++
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/execution/executor/RegionReadExecutor.java
@@ -94,6 +94,12 @@ public class RegionReadExecutor {
resp.setMessage(info.getMessage());
}
return resp;
+ } catch (ConsensusGroupNotExistException e) {
+ LOGGER.error("Execute FragmentInstance in ConsensusGroup {} failed.",
groupId, e);
+ resp.setMessage(String.format(ERROR_MSG_FORMAT, e.getMessage()));
+ resp.setNeedRetry(true);
+ resp.setStatus(new
TSStatus(TSStatusCode.CONSENSUS_GROUP_NOT_EXIST.getStatusCode()));
+ return resp;
} catch (Throwable e) {
LOGGER.error("Execute FragmentInstance in ConsensusGroup {} failed.",
groupId, e);
resp.setMessage(String.format(ERROR_MSG_FORMAT, e.getMessage()));
@@ -104,9 +110,6 @@ public class RegionReadExecutor {
|| t instanceof ServerNotReadyException) {
resp.setNeedRetry(true);
resp.setStatus(new
TSStatus(TSStatusCode.RATIS_READ_UNAVAILABLE.getStatusCode()));
- } else if (t instanceof ConsensusGroupNotExistException) {
- resp.setNeedRetry(true);
- resp.setStatus(new
TSStatus(TSStatusCode.CONSENSUS_GROUP_NOT_EXIST.getStatusCode()));
}
return resp;
}