hashicorp-copywrite[bot]
005636afa0
[COMPLIANCE] Add Copyright and License Headers
2023-04-10 15:36:59 +00:00
Piotr Kazmierczak
b63944b5c1
cleanup: replace TypeToPtr helper methods with pointer.Of ( #14151 )
...
Bumping compile time requirement to go 1.18 allows us to simplify our pointer helper methods.
2022-08-17 18:26:34 +02:00
Yoan Blanc
ac0d5d8bd3
chore: bump golangci-lint from v1.24 to v1.39
...
Signed-off-by: Yoan Blanc <yoan@dosimple.ch>
2021-04-03 09:50:23 +02:00
Chris Baker
719077a26d
added new policy capabilities for recommendations API
...
state store: call-out to generic update of job recommendations from job update method
recommendations API work, and http endpoint errors for OSS
support for scaling polices in task block of job spec
add query filters for ScalingPolicy list endpoint
command: nomad scaling policy list: added -job and -type
2020-10-28 14:32:16 +00:00
Mahmood Ali
d3a17b5c82
address review feedback
2020-10-22 11:49:37 -04:00
Mahmood Ali
58df967c3a
Tag Job spec with HCLv2 tags
2020-10-21 14:05:46 -04:00
Luiz Aoqui
88d4eecfd0
add scaling policy type
2020-09-29 17:57:46 -04:00
James Rasell
da91e1d0fc
api: add namespace to scaling status GET response object.
2020-07-24 11:19:25 +02:00
Chris Baker
9100b6b7c0
changes to make sure that Max is present and valid, to improve error messages
...
* made api.Scaling.Max a pointer, so we can detect (and complain) when it is neglected
* added checks to HCL parsing that it is present
* when Scaling.Max is absent/invalid, don't return extraneous error messages during validation
* tweak to multiregion handling to ensure that the count is valid on the interpolated regional jobs
resolves #8355
2020-07-04 19:05:50 +00:00
Chris Baker
aeb3ed449e
wip: added .PreviousCount to api.ScalingEvent and structs.ScalingEvent, with developmental tests
2020-06-15 19:40:21 +00:00
Chris Baker
11d8fb4b16
the api.ScalingEvent struct was missing the .Count field
2020-05-13 20:44:53 +00:00
Chris Baker
8ec252e627
added indices to the job scaling events, so we could properly do
...
blocking queries on the job scaling status
2020-04-01 17:28:19 +00:00
Chris Baker
40d6b3bbd1
adding raft and state_store support to track job scaling events
...
updated ScalingEvent API to record "message string,error bool" instead
of confusing "reason,error *string"
2020-04-01 16:15:14 +00:00
Chris Baker
5979d6a81e
more testing for ScalingPolicy, mainly around parsing and canonicalization for Min/Max
2020-03-24 19:43:50 +00:00
Chris Baker
f6ec5f9624
made count optional during job scaling actions
...
added ACL protection in Job.Scale
in Job.Scale, only perform a Job.Register if the Count was non-nil
2020-03-24 14:39:05 +00:00
Chris Baker
233db5258a
changes to Canonicalize, Validate, and api->struct conversion so that tg.Count, tg.Scaling.Min/Max are well-defined with reasonable defaults.
...
- tg.Count defaults to tg.Scaling.Min if present (falls back on previous default of 1 if Scaling is absent)
- Validate() enforces tg.Scaling.Min <= tg.Count <= tg.Scaling.Max
modification in ApiScalingPolicyToStructs, api.TaskGroup.Validate so that defaults are handled for TaskGroup.Count and
2020-03-24 13:57:17 +00:00
Chris Baker
5373d503c7
scaling api: put api.* objects in agreement with structs.* objects
2020-03-24 13:57:16 +00:00
Chris Baker
00092a6c29
fixed http endpoints for job.register and job.scalestatus
2020-03-24 13:57:16 +00:00
Chris Baker
925b59e1d2
wip: scaling status return, almost done
2020-03-24 13:57:15 +00:00
Chris Baker
42270d862c
wip: some tests still failing
...
updating job scaling endpoints to match RFC, cleaning up the API object as well
2020-03-24 13:57:14 +00:00
Chris Baker
abc7a52f56
finished refactoring state store, schema, etc
2020-03-24 13:57:14 +00:00
Luiz Aoqui
c74c01a643
wip: add scaling policies methods to the client
2020-03-24 13:57:12 +00:00
Chris Baker
3d54f1feba
wip: added Enabled to ScalingPolicyListStub, removed JobID from body of scaling request
2020-03-24 13:57:12 +00:00
Chris Baker
84953a1ed7
wip: remove PolicyOverride from scaling request
2020-03-24 13:57:11 +00:00
Chris Baker
1c5c2eb71b
wip: add GET endpoint for job group scaling target
2020-03-24 13:57:10 +00:00
Chris Baker
8453e667c2
wip: working on job group scaling endpoint
2020-03-24 13:55:20 +00:00