You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@uniffle.apache.org by "zuston (via GitHub)" <gi...@apache.org> on 2023/08/30 03:42:34 UTC
[GitHub] [incubator-uniffle] zuston commented on a diff in pull request #1179: [#1177] improvement: Reduce the write time of tasks
zuston commented on code in PR #1179:
URL: https://github.com/apache/incubator-uniffle/pull/1179#discussion_r1309596420
##########
client-spark/spark3/src/main/java/org/apache/spark/shuffle/writer/RssShuffleWriter.java:
##########
@@ -293,24 +297,47 @@ protected List<CompletableFuture<Long>> postBlockEvent(
List<ShuffleBlockInfo> shuffleBlockInfoList) {
List<CompletableFuture<Long>> futures = new ArrayList<>();
for (AddBlockEvent event : bufferManager.buildBlockEvents(shuffleBlockInfoList)) {
+ event.addCallback(
+ () -> {
+ boolean ret = finishEventQueue.add(new Object());
+ if (!ret) {
+ LOG.error("Add event " + event + " to finishEventQueue fail");
+ }
+ });
futures.add(shuffleManager.sendData(event));
}
return futures;
}
@VisibleForTesting
protected void checkBlockSendResult(Set<Long> blockIds) {
- long start = System.currentTimeMillis();
- while (true) {
- checkIfBlocksFailed();
- Set<Long> successBlockIds = shuffleManager.getSuccessBlockIds(taskId);
- blockIds.removeAll(successBlockIds);
- if (blockIds.isEmpty()) {
- break;
+ boolean interrupted = false;
Review Comment:
It looks complex for current implement.
And I think the sendTimeout is wrong, which is valid for all everytime `queue.poll`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org