mirror of
https://git.mirrors.martin98.com/https://github.com/mendableai/firecrawl
synced 2025-08-06 00:56:01 +08:00
Update queue.ts
This commit is contained in:
parent
8e78511ed4
commit
b9e06e27f4
@ -88,7 +88,7 @@ export async function queuesController(req: Request, res: Response) {
|
|||||||
|
|
||||||
export async function autoscalerController(req: Request, res: Response) {
|
export async function autoscalerController(req: Request, res: Response) {
|
||||||
try {
|
try {
|
||||||
const maxNumberOfMachines = 100;
|
const maxNumberOfMachines = 80;
|
||||||
const minNumberOfMachines = 20;
|
const minNumberOfMachines = 20;
|
||||||
|
|
||||||
const scrapeQueue = getScrapeQueue();
|
const scrapeQueue = getScrapeQueue();
|
||||||
@ -110,7 +110,7 @@ export async function autoscalerController(req: Request, res: Response) {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
const machines = await request.json();
|
const machines = await request.json();
|
||||||
|
|
||||||
// Only worker machines
|
// Only worker machines
|
||||||
const activeMachines = machines.filter(machine => (machine.state === 'started' || machine.state === "starting") && machine.config.env["FLY_PROCESS_GROUP"] === "worker").length;
|
const activeMachines = machines.filter(machine => (machine.state === 'started' || machine.state === "starting") && machine.config.env["FLY_PROCESS_GROUP"] === "worker").length;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user