Github user xuanyuanking commented on the issue: https://github.com/apache/spark/pull/17702 @cloud-fan Thanks for your reply! It's possible to consolidate them but may be not so necessary? I can consolidate them by replace the logic in `getGlobbedPaths` list below to `InMemoryFileIndex.bulkListLeafFiles` ``` + val expanded = sparkSession.sparkContext + .parallelize(paths, paths.length) + .map { pathString => + SparkHadoopUtil.get.globPathIfNecessary(new Path(pathString)).map(_.toString) + }.collect() + expanded.flatMap(paths => paths.map(new Path(_))).toSeq ``` , and also change the interface of `bulkListLeafFiles` by adding a default param to parse the function `globPathIfNecessary`, because of the glob path can be nested in many levels. Maybe current logic to add a new parallelize job is better than consolidate, what do you think?
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org