javanna commented on code in PR #14364:
URL: https://github.com/apache/lucene/pull/14364#discussion_r1999421774


##########
lucene/suggest/src/java/org/apache/lucene/search/suggest/document/Completion101PostingsFormat.java:
##########
@@ -25,17 +25,9 @@
  * @lucene.experimental
  */
 public class Completion101PostingsFormat extends CompletionPostingsFormat {
-  /** Creates a {@link Completion101PostingsFormat} that will load the 
completion FST on-heap. */
+  /** Creates a {@link Completion101PostingsFormat} that will load the 
completion FST off-heap. */
   public Completion101PostingsFormat() {
-    this(FSTLoadMode.ON_HEAP);
-  }
-
-  /**
-   * Creates a {@link Completion101PostingsFormat} that will use the provided 
<code>fstLoadMode
-   * </code> to determine if the completion FST should be loaded on or off 
heap.
-   */
-  public Completion101PostingsFormat(FSTLoadMode fstLoadMode) {

Review Comment:
   I find that these constructors taking the fst load mode are trappy, in that 
they make readers think that calling them allows to override the load mode. In 
practice, the load mode is only ever used at read time, and that codepath goes 
through SPI loading, so via the default constructor. I think removing these is 
the best path forward to avoid confusion.



-- 
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: issues-unsubscr...@lucene.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to