This is an automated email from the ASF dual-hosted git repository.
zuston pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-uniffle.git
The following commit(s) were added to refs/heads/master by this push:
new 41d78aafa [#1764] fix(client): Fix timeout time unit for unregister
requests (#1766)
41d78aafa is described below
commit 41d78aafac933e7c7ffa5dddd440b7465a3bb63e
Author: Enrico Minack <[email protected]>
AuthorDate: Tue Jun 4 10:53:17 2024 +0200
[#1764] fix(client): Fix timeout time unit for unregister requests (#1766)
### What changes were proposed in this pull request?
Method `ThreadUtils.executeTasks` expects milliseconds, but seconds are
given.
### Why are the changes needed?
Requests are interrupted before the configured timeout passes.
Fix: #1764
### Does this PR introduce _any_ user-facing change?
Configured timeout is respected.
### How was this patch tested?
Manually tested.
---
.../java/org/apache/uniffle/client/impl/ShuffleWriteClientImpl.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git
a/client/src/main/java/org/apache/uniffle/client/impl/ShuffleWriteClientImpl.java
b/client/src/main/java/org/apache/uniffle/client/impl/ShuffleWriteClientImpl.java
index ed240c887..c109668ac 100644
---
a/client/src/main/java/org/apache/uniffle/client/impl/ShuffleWriteClientImpl.java
+++
b/client/src/main/java/org/apache/uniffle/client/impl/ShuffleWriteClientImpl.java
@@ -957,6 +957,7 @@ public class ShuffleWriteClientImpl implements
ShuffleWriteClient {
@Override
public void unregisterShuffle(String appId, int shuffleId) {
+ int unregisterTimeMs = unregisterRequestTimeSec * 1000;
RssUnregisterShuffleRequest request = new
RssUnregisterShuffleRequest(appId, shuffleId);
Map<Integer, Set<ShuffleServerInfo>> appServerMap =
shuffleServerInfoMap.get(appId);
@@ -991,7 +992,7 @@ public class ShuffleWriteClientImpl implements
ShuffleWriteClient {
}
return null;
},
- unregisterRequestTimeSec,
+ unregisterTimeMs,
"unregister shuffle server");
} finally {
@@ -1004,6 +1005,7 @@ public class ShuffleWriteClientImpl implements
ShuffleWriteClient {
@Override
public void unregisterShuffle(String appId) {
+ int unregisterTimeMs = unregisterRequestTimeSec * 1000;
RssUnregisterShuffleByAppIdRequest request = new
RssUnregisterShuffleByAppIdRequest(appId);
if (appId == null) {
@@ -1039,7 +1041,7 @@ public class ShuffleWriteClientImpl implements
ShuffleWriteClient {
}
return null;
},
- unregisterRequestTimeSec,
+ unregisterTimeMs,
"unregister shuffle server");
} finally {