Skip to content

Commit f624336

Browse files
committed
Disable HNSW connectedComponents (#14214) (#14436)
* Disable HNSW connectedComponents (#14214) * add changes
1 parent 9b2ab90 commit f624336

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

lucene/CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,8 @@ Bug Fixes
174174

175175
* GITHUB#14320: Fix DirectIOIndexInput seek to not read when position is within buffer (Chris Hegarty)
176176

177+
* GITHUB#14436: Disable connectedComponents logic in HNSW graph building. Relates to GITHUB#14214, GITHUB#12627, GITHUB#13566. (Ben Trent)
178+
177179
Changes in Runtime Behavior
178180
---------------------
179181
* GITHUB#14189: Bump floor segment size to 16MB in TieredMergePolicy and

lucene/core/src/java/org/apache/lucene/util/hnsw/HnswGraphBuilder.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,10 +448,13 @@ private static int getRandomGraphLevel(double ml, SplittableRandom random) {
448448

449449
void finish() throws IOException {
450450
// System.out.println("finish " + frozen);
451-
connectComponents();
451+
// TODO: Connect components can be exceptionally expensive, disabling
452+
// see: https://github.com/apache/lucene/issues/14214
453+
// connectComponents();
452454
frozen = true;
453455
}
454456

457+
@SuppressWarnings("unused")
455458
private void connectComponents() throws IOException {
456459
long start = System.nanoTime();
457460
for (int level = 0; level < hnsw.numLevels(); level++) {

0 commit comments

Comments
 (0)