imbajin commented on code in PR #704:
URL: 
https://github.com/apache/incubator-hugegraph-toolchain/pull/704#discussion_r2704459159


##########
hugegraph-loader/src/main/java/org/apache/hugegraph/loader/executor/LoadOptions.java:
##########
@@ -329,6 +343,11 @@ public final class LoadOptions implements Cloneable {
                description = "The task scheduler type (when creating graph if 
not exists")
     public String schedulerType = "distributed";
 
+    @Parameter(names = {"--batch-failure-fallback"}, arity = 1,
+               description = "Whether to fallback to single insert when batch 
insert fails. " +
+                             "Default: false")
+    public boolean batchFailureFallback = false;

Review Comment:
   ⚠️ **Important - 默认行为改变可能影响现有用户**
   
   此 PR 改变了批量插入失败的默认行为:
   - **旧行为:** 批量失败自动 fallback 到单条插入(静默降级)
   - **新行为:** 批量失败直接停止加载(快速失败)
   
   **影响分析:**
   1. 对于依赖自动降级的现有用户,升级后可能导致加载中断
   2. 虽然新行为更符合 "fail-fast" 原则,但属于 breaking change
   3. 需要明确的版本说明和迁移指南
   
   **建议:**
   1. 在 PR 描述中明确标注这是 breaking change
   2. 提供迁移指南:如何恢复旧行为(`--batch-failure-fallback=true`)
   3. 考虑在日志启动时打印当前配置,提醒用户:
      ```java
      LOG.info("Batch failure handling: {}", 
               options.batchFailureFallback ? "fallback to single insert" : 
"stop loading");
      ```
   
   **文档要求:**
   需要在 release notes 或文档中说明:
   - 为什么改变默认行为
   - 如何恢复旧行为
   - 建议的最佳实践



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to