rangareddy commented on issue #17336:
URL: https://github.com/apache/hudi/issues/17336#issuecomment-5351233968

   This issue was reviewed as part of the JIRA-migrated backlog triage 
(HUDI-8702).
   
   **Findings: confirmed, still reproducible by inspection on `master`.**
   
   The CLI path does exactly what the description says. 
`hudi-cli/src/main/java/org/apache/hudi/cli/commands/TableCommand.java:226`:
   
   ```java
   @ShellMethod(key = "table update-configs", value = "Update the table configs 
with configs with provided file.")
   public String updateTableConfig(... final String updatePropsFilePath) throws 
IOException {
     ...
     HoodieTableConfig.update(client.getStorage(), client.getMetaPath(), 
updatedProps);
   ```
   
   and 
`hudi-common/src/main/java/org/apache/hudi/common/table/HoodieTableConfig.java:602`:
   
   ```java
   public static void update(HoodieStorage storage, StoragePath metadataFolder, 
Properties updatedProps) {
     modify(storage, metadataFolder, updatedProps, 
ConfigUtils::upsertProperties, Collections.EMPTY_SET);
   }
   ```
   
   That is a raw upsert of whatever keys the props file contains. No derivation 
runs.
   
   The logic that *would* recompute the strategy id does exist, but only on the 
create/upgrade path - `inferMergingConfigsForPreV9Table` plus the `CASE 
0/1/2/3` block at `HoodieTableConfig.java:883-961`, which sets 
`RECORD_MERGE_STRATEGY_ID` from the merge mode and payload class. `update()` 
never calls into it.
   
   So setting `hoodie.record.merge.mode` to `COMMIT_TIME_ORDERING` and the 
payload class to `OverwriteWithLatestPayload` via `table update-configs` leaves 
`hoodie.record.merge.strategy.id` pointing at `DEFAULT_MERGE_STRATEGY_UUID`, 
which agrees with your reproduction.
   
   Your framing looks right to me: since the strategy id is an internal 
implementation detail, the fix is to route config updates through the same 
reconciliation the create path uses rather than to document the CLI ordering. 
Note the same gap applies to `updateAndDeleteProps` and to any other caller of 
`HoodieTableConfig.update`, not just the CLI.
   
   Keeping this open.
   


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