jerrypeng commented on code in PR #56196: URL: https://github.com/apache/spark/pull/56196#discussion_r3360669623
########## core/src/main/scala/org/apache/spark/shuffle/streaming/MultiShuffleManager.scala: ########## @@ -0,0 +1,149 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.spark.shuffle.streaming + +import java.util.Properties +import java.util.concurrent.ConcurrentHashMap + +import org.apache.spark.{ShuffleDependency, SparkConf, SparkContext, SparkException, TaskContext} +import org.apache.spark.internal.Logging +import org.apache.spark.shuffle.{ShuffleBlockResolver, ShuffleHandle, ShuffleManager, ShuffleReader, ShuffleReadMetricsReporter, ShuffleWriteMetricsReporter, ShuffleWriter} +import org.apache.spark.shuffle.sort.SortShuffleManager +import org.apache.spark.shuffle.streaming.MultiShuffleManager.isStreamingShuffleEnabled + +class MultiShuffleHandle( + val streamingShuffleHandle: ShuffleHandle, + val otherShuffleHandle: ShuffleHandle) + extends ShuffleHandle(streamingShuffleHandle.shuffleId) + +object MultiShuffleManager { + val STREAMING_SHUFFLE_ENABLED_PROPERTY = "spark.shuffle.streaming.useForCurrentQuery" Review Comment: Actually we can just use the property declared in another PR to support concurrent scheduling of stages for RTM: https://github.com/apache/spark/pull/56055/changes#diff-d0f6837fa021fde4261cd3b035d2fe5ccad37e65aa351913b05f491a847c6d04R286. The idea when concurrent scheduling of stages is enabled we will use the streaming shuffle. It is simplified that way. I added a TODO to remove the literal declaration here once the other PR is merged. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
