sunchao commented on code in PR #3784:
URL: https://github.com/apache/celeborn/pull/3784#discussion_r3739423075
##########
worker/src/main/scala/org/apache/celeborn/service/deploy/worker/FetchHandler.scala:
##########
@@ -147,36 +148,48 @@ class FetchHandler(
val startIndices = openStreamList.getStartIndexList
val endIndices = openStreamList.getEndIndexList
val readLocalFlags = openStreamList.getReadLocalShuffleList
- val pbOpenStreamListResponse = PbOpenStreamListResponse.newBuilder()
checkAuth(client, Utils.splitShuffleKey(shuffleKey)._1)
val openStreamRequestId = Utils.makeOpenStreamRequestId(
shuffleKey,
client.getChannel.id().toString,
rpcRequest.requestId)
workerSource.startTimer(WorkerSource.OPEN_STREAM_TIME,
openStreamRequestId)
- try {
- 0 until files.size() foreach { idx =>
- val pbStreamHandlerOpt = handleReduceOpenStreamInternal(
- client,
- shuffleKey,
- files.get(idx),
- startIndices.get(idx),
- endIndices.get(idx),
- readLocalFlags.get(idx))
- if (pbStreamHandlerOpt.getStatus != StatusCode.SUCCESS.getValue) {
+ val streamHandlerFutures = (0 until files.size()).map { idx =>
+ handleReduceOpenStreamAsync(
+ client,
+ shuffleKey,
+ files.get(idx),
Review Comment:
Fixed in 33ea2be. `FetchHandler` now validates that `fileName`,
`startIndex`, `endIndex`, and `readLocalShuffle` contain the same number of
entries before starting `OPEN_STREAM_TIME`. Malformed batches increment
`OPEN_STREAM_FAIL_COUNT` and return an RPC failure without starting the timer.
`FetchHandlerSuiteJ.testBatchOpenStreamRejectsMismatchedRequestFieldLengths`
covers both missing and extra entries.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]