Skip to content

Commit

Permalink
fix: undo unintended change
Browse files Browse the repository at this point in the history
  • Loading branch information
berezovskyi committed Dec 29, 2024
1 parent 448e5d9 commit cfd15cd
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions backend/src/main/java/sparqles/schedule/Scheduler.java
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,11 @@ public Scheduler() {
public Scheduler(int threads) {
int athreads = (int) (threads * 0.3);
int tthreads = threads - athreads;
SERVICE = Executors.newScheduledThreadPool(tthreads, Thread.ofVirtual().factory());
ASERVICE = Executors.newScheduledThreadPool(athreads, Thread.ofVirtual().factory());
// TODO: use virtual threads after JDK21
// SERVICE = Executors.newScheduledThreadPool(tthreads, Thread.ofVirtual().factory());
// ASERVICE = Executors.newScheduledThreadPool(athreads, Thread.ofVirtual().factory());
SERVICE = Executors.newScheduledThreadPool(tthreads);
ASERVICE = Executors.newScheduledThreadPool(athreads);

_monitor = new SchedulerMonitor();
_monitor.start();
Expand Down

0 comments on commit cfd15cd

Please sign in to comment.