Skip to content

Commit baea033

Browse files
Bring back threshold & make constructor test only
Co-authored-by: Florentin Dörre <florentin.dorre@neotechnology.com>
1 parent 7cb526d commit baea033

File tree

1 file changed

+14
-12
lines changed

1 file changed

+14
-12
lines changed

algo/src/main/java/org/neo4j/gds/steiner/ShortestPathsSteinerAlgorithm.java

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121

2222
import com.carrotsearch.hppc.BitSet;
2323
import org.apache.commons.lang3.mutable.MutableBoolean;
24+
import org.jetbrains.annotations.TestOnly;
2425
import org.neo4j.gds.Algorithm;
2526
import org.neo4j.gds.api.Graph;
2627
import org.neo4j.gds.core.concurrency.ParallelUtil;
@@ -51,7 +52,6 @@ public class ShortestPathsSteinerAlgorithm extends Algorithm<SteinerTreeResult>
5152

5253
private int binSizeThreshold;
5354

54-
5555
public ShortestPathsSteinerAlgorithm(
5656
Graph graph,
5757
long sourceId,
@@ -70,19 +70,21 @@ public ShortestPathsSteinerAlgorithm(
7070
this.isTerminal = createTerminals();
7171
this.applyRerouting = applyRerouting;
7272
this.executorService = executorService;
73+
this.binSizeThreshold = SteinerBasedDeltaStepping.BIN_SIZE_THRESHOLD;
7374
}
7475

75-
ShortestPathsSteinerAlgorithm(
76-
Graph graph,
77-
long sourceId,
78-
List<Long> terminals,
79-
double delta,
80-
int concurrency,
81-
boolean applyRerouting,
82-
int binSizeThreshold,
83-
ExecutorService executorService
84-
) {
85-
super(ProgressTracker.NULL_TRACKER);
76+
@TestOnly
77+
ShortestPathsSteinerAlgorithm(
78+
Graph graph,
79+
long sourceId,
80+
List<Long> terminals,
81+
double delta,
82+
int concurrency,
83+
boolean applyRerouting,
84+
int binSizeThreshold,
85+
ExecutorService executorService
86+
) {
87+
super(ProgressTracker.NULL_TRACKER);
8688
this.graph = graph;
8789
this.sourceId = sourceId;
8890
this.terminals = terminals;

0 commit comments

Comments
 (0)