hudi-agent commented on code in PR #18921:
URL: https://github.com/apache/hudi/pull/18921#discussion_r3368459515


##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/index/simple/HoodieGlobalSimpleIndex.java:
##########
@@ -68,13 +68,20 @@ public <R> HoodieData<HoodieRecord<R>> tagLocation(
   protected <R> HoodieData<HoodieRecord<R>> tagLocationInternal(
       HoodieData<HoodieRecord<R>> inputRecords, HoodieEngineContext context,
       HoodieTable hoodieTable) {
+    if (config.getSimpleIndexUseCaching()) {

Review Comment:
   🤖 nit: could you hoist `config.getSimpleIndexUseCaching()` into a local 
`boolean useCaching` at the top of the method? It makes the persist/unpersist 
symmetry more obvious and ensures both branches always stay in sync if the 
condition ever changes.
   
   <sub><i>- AI-generated; verify before applying. React 👍/👎 to flag 
quality.</i></sub>



-- 
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]

Reply via email to