Skip to content

Commit

Permalink
Merge pull request #201 from SuperFlyTV/fix/excessive-worker-restarting
Browse files Browse the repository at this point in the history
  • Loading branch information
jstarpl authored Oct 28, 2024
2 parents 9e17ba2 + b567535 commit 9ab6bdc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions shared/packages/api/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ const appContainerArguments = defineArguments({
},
minRunningApps: {
type: 'number',
default: parseInt(process.env.APP_CONTAINER_MIN_RUNNING_APPS || '', 10) || 0,
default: parseInt(process.env.APP_CONTAINER_MIN_RUNNING_APPS || '', 10) || 1,
describe: 'Minimum amount of apps (of a certain appType) to be running',
},
maxAppKeepalive: {
Expand All @@ -220,7 +220,7 @@ const appContainerArguments = defineArguments({
},
minCriticalWorkerApps: {
type: 'number',
default: 0,
default: 1,
describe: 'Number of Workers reserved for fulfilling playout-critical expectations that will be kept running',
},

Expand Down
3 changes: 2 additions & 1 deletion shared/packages/workforce/src/workforce.ts
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,8 @@ export class Workforce {
statuses['any-workers'] =
this.workerAgents.size === 0
? {
statusCode: StatusCode.BAD,
// This is perfectly normal in some scenarios, so we don't report this as an error
statusCode: StatusCode.GOOD,
message: 'No workers connected to workforce',
}
: {
Expand Down

0 comments on commit 9ab6bdc

Please sign in to comment.