codope commented on a change in pull request #4693: URL: https://github.com/apache/hudi/pull/4693#discussion_r835753092
########## File path: hudi-client/hudi-client-common/src/main/java/org/apache/hudi/client/BaseHoodieWriteClient.java ########## @@ -915,6 +917,39 @@ public boolean scheduleCompactionAtInstant(String instantTime, Option<Map<String return scheduleTableService(instantTime, extraMetadata, TableServiceType.COMPACT).isPresent(); } + public Option<String> scheduleIndexing(List<MetadataPartitionType> partitionTypes) { + String instantTime = HoodieActiveTimeline.createNewInstantTime(); + return scheduleIndexingAtInstant(partitionTypes, instantTime) ? Option.of(instantTime) : Option.empty(); + } + + private boolean scheduleIndexingAtInstant(List<MetadataPartitionType> partitionTypes, String instantTime) throws HoodieIOException { + Option<HoodieIndexPlan> indexPlan = createTable(config, hadoopConf, config.isMetadataTableEnabled()) Review comment: we check table config to see inflight/completed indexes and this would return false in case triggered twice. -- 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: commits-unsubscr...@hudi.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org