rmuir commented on code in PR #16086:
URL: https://github.com/apache/lucene/pull/16086#discussion_r3285246608
##########
lucene/core/src/java/org/apache/lucene/index/IndexWriterConfig.java:
##########
@@ -561,4 +561,21 @@ public IndexWriterConfig setParentField(String
parentField) {
this.parentField = parentField;
return this;
}
+
+ /**
+ * Expert: sets the interval in bytes between abort checks during merge
integrity verification.
+ * During merges, codec readers verify file integrity by reading entire
files to compute
+ * checksums. This setting controls how often the merge abort flag is
checked during these reads.
+ * Smaller values allow merges to be aborted more promptly but add slight
overhead.
+ *
+ * @param intervalBytes the interval in bytes, must be positive
+ */
+ public IndexWriterConfig setMergeAbortCheckIntervalBytes(int intervalBytes) {
Review Comment:
does require need a configurable value at all, just a reasonable one (e.g.
1MB). If someone is doing s3, even setting this to `1` could take "forever" due
to network latency. We shouldn't overengineer here.
If we can simplify how we do it (see idea on CodecUtil.java), i'd suggest
overloading the implementing function with a parameter, to allow unit tests to
use a small value, but it doesn't need to be public.
--
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]