This is an automated email from the ASF dual-hosted git repository.
chengpan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kyuubi.git
The following commit(s) were added to refs/heads/master by this push:
new 2ab27892a4 Revert "[KYUUBI #6639] Port HIVE-27815: Support update
numModifiedRows"
2ab27892a4 is described below
commit 2ab27892a4f651725ed2dd3df292a0cd805276a6
Author: Cheng Pan <[email protected]>
AuthorDate: Fri Nov 29 00:43:17 2024 +0800
Revert "[KYUUBI #6639] Port HIVE-27815: Support update numModifiedRows"
This reverts commit 2d883e7cac6e72f7792dabf69a2bb099df15b210.
---
.../org/apache/kyuubi/jdbc/hive/KyuubiStatement.java | 18 +++++-------------
1 file changed, 5 insertions(+), 13 deletions(-)
diff --git
a/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiStatement.java
b/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiStatement.java
index 84965df203..23f0a1f43d 100644
---
a/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiStatement.java
+++
b/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiStatement.java
@@ -380,7 +380,7 @@ public class KyuubiStatement implements SQLStatement,
KyuubiLoggable {
TGetOperationStatusResp statusResp = null;
// Poll on the operation status, till the operation is complete
- do {
+ while (!isOperationComplete) {
try {
/**
* For an async SQLOperation, GetOperationStatus will use the long
polling approach It will
@@ -427,7 +427,7 @@ public class KyuubiStatement implements SQLStatement,
KyuubiLoggable {
isLogBeingGenerated = false;
throw new KyuubiSQLException(e.toString(), "08S01", e);
}
- } while (!isOperationComplete);
+ }
/*
we set progress bar to be completed when hive query execution has
completed
@@ -513,7 +513,7 @@ public class KyuubiStatement implements SQLStatement,
KyuubiLoggable {
@Override
public int executeUpdate(String sql) throws SQLException {
execute(sql);
- return getUpdateCount();
+ return 0;
}
@Override
@@ -589,16 +589,8 @@ public class KyuubiStatement implements SQLStatement,
KyuubiLoggable {
* client might end up using executeAsync and then call this to check if
the query run is
* finished.
*/
- long numModifiedRows = -1L;
- TGetOperationStatusResp resp = waitForOperationToComplete();
- if (resp != null && resp.isSetNumModifiedRows()) {
- numModifiedRows = resp.getNumModifiedRows();
- }
- if (numModifiedRows == -1L || numModifiedRows > Integer.MAX_VALUE) {
- LOG.warn("Invalid number of updated rows: {}", numModifiedRows);
- return -1;
- }
- return (int) numModifiedRows;
+ waitForOperationToComplete();
+ return -1;
}
@Override