class JobQueueScaler extends Object implements Runnable
| Constructor and Description |
|---|
JobQueueScaler(RouterContext context,
JobQueue jobQueue)
Create a new JobQueueScaler.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getCurrentMaxRunners()
Get the current maximum runner limit (may be up to 2x configured or RAM-limited).
|
boolean |
isAlive()
Check if the scaler is currently running.
|
void |
run()
Main scaling loop.
|
void |
shutdown()
Shutdown the scaler gracefully.
|
void |
startup()
Start the scaler thread.
|
void |
updateMaxRunners(int configuredMax)
Update the maximum runner limit (called when configuration changes).
|
public JobQueueScaler(RouterContext context, JobQueue jobQueue)
context - the router contextjobQueue - the job queue to scalepublic int getCurrentMaxRunners()
public boolean isAlive()
public void shutdown()
public void startup()
public void updateMaxRunners(int configuredMax)