mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-11-06 19:12:23 +00:00
A new root task can only be added to executors queue when 90% free
rest is reserved for fan out of existing tasks.
This commit is contained in:
1 parent
f400435ccc
commit
4d258b6cbd
1 file changed
+2
-2
@@ -77,7 +77,7 @@ public class PolarDataMiner {
|
||||
protected void afterExecute(Runnable r, Throwable t) {
|
||||
super.afterExecute(r, t);
|
||||
synchronized (fixQueue) {
|
||||
while (this.getQueue().size() < (EXECUTOR_QUEUE_SIZE / 3) && !fixQueue.isEmpty()) {
|
||||
while (this.getQueue().size() < (EXECUTOR_QUEUE_SIZE / 10) && !fixQueue.isEmpty()) {
|
||||
GPSFixMovingWithOriginInfo fix = fixQueue.poll();
|
||||
enrichingProcessor.processElement(fix);
|
||||
}
|
||||
@@ -212,7 +212,7 @@ public class PolarDataMiner {
|
||||
if (PolarFixFilterCriteria.isInLeadingCompetitors(trackedRace, fixWithOriginInfo.getCompetitor(),
|
||||
backendPolarSheetGenerationSettings.getPctOfLeadingCompetitorsToInclude())) {
|
||||
synchronized (fixQueue) {
|
||||
if (executor.getQueue().size() >= EXECUTOR_QUEUE_SIZE / 3) {
|
||||
if (executor.getQueue().size() >= EXECUTOR_QUEUE_SIZE / 10) {
|
||||
fixQueue.add(fixWithOriginInfo);
|
||||
} else {
|
||||
enrichingProcessor.processElement(fixWithOriginInfo);
|
||||
|
||||
Reference in new issue
Block a user