Scale Deployments do not respect Update stanza
- Dominant language
- Go
- Stars
- 17k
- Forks
- 2.1k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 105
Description
### Nomad version
1.13.11-ent
### Operating system and Environment details
Ubuntu 20.04 on AWS
### Issue
Not sure if this is a bug in the scale functionality, or a documentation issue...
Job Scale commands do not respect the `max_parallel` value from a job's `update` stanza. If this is the intended behavior, the docs should be clearer about it. Scale commands create a deployment object, and this behavior does not align with other deployment behavior.
The docs imply that a scale is a job update:
>Scale will issue a request to update the matched job and then invoke an interactive monitor that exits automatically once the scheduler has processed the request. It is safe to exit the monitor early using ctrl+c.
However, a scale command starts or stops all allocations at once.
### Reproduction steps
Register a job with `count=2` and `max_parallel=2`.
Scale the job to `10`
#### Expected Result
Job scales 2 allocations at a time.
#### Actual Result
Job scales by 8 immediately.
### Job file (if appropriate)
### Nomad Server logs (if appropriate)
### Nomad Client logs (if appropriate)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the Nomad scale command and the deployment handling for jobs with an update stanza. Reproduce scaling from count=2 to 10 with max_parallel=2, then compare the observed allocation changes with the expected two-at-a-time behavior and determine whether the result requires a code fix or clearer documentation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- backend, cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100