Skip to content

Commit 12a0414

Browse files
committed
Do not override user-specified max.bg.threads
1 parent 44322a7 commit 12a0414

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

common/src/main/java/org/embeddedt/modernfix/core/ModernFixMixinPlugin.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,10 @@ public void run() {
9595
}
9696

9797
private void computeBetterThreadCount() {
98+
// Allow user-provided thread count to take precedence
99+
if (System.getProperty("max.bg.threads") != null) {
100+
return;
101+
}
98102
// Server thread + client thread + GC thread
99103
int reservedCores = 3;
100104
int availableBackgroundCores = Math.max(1, Runtime.getRuntime().availableProcessors() - reservedCores);

0 commit comments

Comments
 (0)