Restore defaults

This commit is contained in:
Iván Ovejero 2024-11-07 17:15:27 +01:00
parent 83c33a43fa
commit ea04ee23ed
No known key found for this signature in database

View file

@ -2,7 +2,7 @@ import { TaskRunnersConfig } from '@n8n/config';
import { strict } from 'node:assert'; import { strict } from 'node:assert';
import { Service } from 'typedi'; import { Service } from 'typedi';
// import { Time } from '@/constants'; import { Time } from '@/constants';
import { OnShutdown } from '@/decorators/on-shutdown'; import { OnShutdown } from '@/decorators/on-shutdown';
import { Logger } from '@/logging/logger.service'; import { Logger } from '@/logging/logger.service';
import { TaskRunnerProcess } from '@/runners/task-runner-process'; import { TaskRunnerProcess } from '@/runners/task-runner-process';
@ -80,11 +80,8 @@ export class RunnerLifecycleManager {
} }
private startIdleChecks() { private startIdleChecks() {
// const idleTimeout = this.runnerConfig.idleTimeout * Time.minutes.toMilliseconds; const idleTimeout = this.runnerConfig.idleTimeout * Time.minutes.toMilliseconds;
// const idleChecksFrequency = this.runnerConfig.idleChecksFrequency * Time.minutes.toMilliseconds; const idleChecksFrequency = this.runnerConfig.idleChecksFrequency * Time.minutes.toMilliseconds;
const idleTimeout = 10_000;
const idleChecksFrequency = 10_000;
this.idleChecksInterval = setInterval(() => { this.idleChecksInterval = setInterval(() => {
if (this.state === 'running' && Date.now() - this.lastActivityTime > idleTimeout) { if (this.state === 'running' && Date.now() - this.lastActivityTime > idleTimeout) {