muyihao commented on code in PR #11914:
URL: https://github.com/apache/hudi/pull/11914#discussion_r1760486231
##########
hudi-hadoop-mr/src/main/java/org/apache/hudi/hadoop/hive/HoodieCombineHiveInputFormat.java:
##########
@@ -375,6 +389,45 @@ public InputSplit[] getSplits(JobConf job, int numSplits)
throws IOException {
// clear work from ThreadLocal after splits generated in case of thread is
reused in pool.
Utilities.clearWorkMapForConf(job);
+ // build internal schema for the query
+ if (job.getBoolean(INTERNAL_SCHEMA_CACHE_ENABLE, true)) {
+ if (result.size() > 0) {
+ Map<String, String> schemaMap = new HashMap<>();
+ ArrayList<String> uniqTablePaths = new ArrayList<>();
+ Arrays.stream(paths).forEach(path -> {
+ HoodieStorage storage = null;
+ try {
+ storage = new HoodieHadoopStorage(path.getFileSystem(job));
+ Option<StoragePath> tablePath =
TablePathUtils.getTablePath(storage, HadoopFSUtils.convertToStoragePath(path));
Review Comment:
> In which case there are multiple table paths?
When we perform a query on two different Hudi tables, such as union, join,
or subquery, there will be multiple table paths.
--
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]