Mahmood Ali
d30c3d10b0
Merge pull request #5747 from hashicorp/b-test-fixes-20190521-1
...
More test fixes
2019-06-05 19:09:18 -04:00
Lang Martin
0f6f543a5f
deployment_watcher auto promote iff every task group is auto promotable
2019-05-22 12:34:57 -04:00
Lang Martin
0c668ecc7a
log error on autoPromoteDeployment failure
2019-05-22 12:32:08 -04:00
Lang Martin
b5fd735960
add update AutoPromote bool
2019-05-22 12:32:08 -04:00
Lang Martin
3c5a9fed22
deployments_watcher_test new TestWatcher_AutoPromoteDeployment
2019-05-22 12:32:08 -04:00
Lang Martin
0bebf5d7f8
deployment_watcher when it's ok to autopromote, do so
2019-05-22 12:32:08 -04:00
Lang Martin
0cf4168ed9
deployments_watcher comments
2019-05-22 12:32:08 -04:00
Lang Martin
e1e28307be
new deploymentwatcher/doc.go for package level documentation
2019-05-22 12:32:08 -04:00
Mahmood Ali
3b0152d778
tests: fix deploymentwatcher tests data races
2019-05-21 14:29:45 -04:00
Alex Dadgar
be54e56570
review fixes
2018-11-08 09:48:36 -08:00
Alex Dadgar
1c31970464
Fix multiple tgs with progress deadline handling
...
Fix an issue in which the deployment watcher would fail the deployment
based on the earliest progress deadline of the deployment regardless of
if the task group has finished.
Further fix an issue where the blocked eval optimization would make it
so no evals were created to progress the deployment. To reproduce this
issue, prior to this commit, you can create a job with two task groups.
The first group has count 1 and resources such that it can not be
placed. The second group has count 3, max_parallel=1, and can be placed.
Run this first and then update the second group to do a deployment. It
will place the first of three, but never progress since there exists a
blocked eval. However, that doesn't capture the fact that there are two
groups being deployed.
2018-11-05 16:06:17 -08:00
Alex Dadgar
de442226ae
Fix other instances of blocking queries
2018-09-24 13:52:39 -07:00
Alex Dadgar
7f0d241ef4
always handle failed allocation
2018-09-21 15:13:54 -07:00
Alex Dadgar
b2449ae1ce
Fix deployment watcher index usage
...
Fixes three issues:
1. Retrieving the latest evaluation index was not properly selecting the
greatest index. This would undermine checks we had to reduce the number
of evaluations created when the latest eval index was greater than any
alloc change
2. Fix an issue where the blocking query code was using the incorrect
index such that the index was higher than necassary.
3. Special case handling of blocked evaluation since the create/snapshot
index is no particularly useful since they can be reblocked.
2018-09-21 13:59:11 -07:00
Alex Dadgar
3c19d01d7a
server
2018-09-15 16:23:13 -07:00
Alex Dadgar
c6576ddac1
Fix make check errors
2018-09-04 16:03:52 -07:00
Alex Dadgar
300b1a7a15
Tests only use testlog package logger
2018-06-13 15:40:56 -07:00
Preetha Appan
c7edbd5f41
newlines in test
2018-05-07 14:55:01 -05:00
Preetha Appan
4e75456beb
Fix deadlock in deadline timer logic when progress deadline is passed and the deployment is updated.
2018-05-07 14:55:01 -05:00
Preetha Appan
19b096d203
Set modify time for allocs in unit test, and define current time in one spot
2018-05-07 14:55:01 -05:00
Preetha Appan
4c377b112e
Fix panic in deployment watcher when deployment is not in the state store due to a gc
2018-05-07 14:55:01 -05:00
Alex Dadgar
768fec8505
Allow healthy canary deployment to skip progress deadline
2018-05-07 14:55:01 -05:00
Michael Schurter
a3038cefb4
typo: transistion -> transition
2018-05-07 14:50:01 -05:00
Alex Dadgar
bd38675365
Fix tests
2018-05-07 14:50:01 -05:00
Preetha Appan
b2b773e696
better comments and remove commented code
2018-05-07 14:50:01 -05:00
Preetha Appan
90a2311cef
Fix deadlock in deployment watcher when deployment starts with no allocations and eventually has failed allocations
2018-05-07 14:50:01 -05:00
Alex Dadgar
8d50955054
Fix typos
2018-05-07 14:50:01 -05:00
Alex Dadgar
641ef81cbf
Test fixes
2018-05-07 14:50:01 -05:00
Alex Dadgar
8a81038cdb
Set Reschedule from deployment watcher
2018-05-07 14:50:01 -05:00
Alex Dadgar
a510774451
Use UpdateAllocDesiredTransistion instead of UpsertEval but no transistions yet
2018-05-07 14:50:01 -05:00
Alex Dadgar
fcf4f582d0
small review feedback fixes
2018-05-07 14:50:01 -05:00
Alex Dadgar
9bff9024b3
add latest eval back
2018-05-07 14:50:01 -05:00
Alex Dadgar
99e00fb774
Pass through timestamp
2018-05-07 14:50:01 -05:00
Alex Dadgar
c49b5f9949
Handle progressed deployments and tests
2018-05-07 14:50:01 -05:00
Alex Dadgar
9e75ea0a11
Deployment watcher based on deployment having progress deadline
2018-05-07 14:50:01 -05:00
Alex Dadgar
1336002255
Progress deadline in deployment state
2018-05-07 14:50:01 -05:00
Alex Dadgar
55b483709f
Fix tests
2018-05-07 14:50:01 -05:00
Alex Dadgar
ee50789c22
Initial implementation
2018-05-07 14:50:01 -05:00
Michael Schurter
0a17076ad2
refactor drainer into a subpkg
2018-03-21 16:51:44 -07:00
Alex Dadgar
4844317cc2
Merge pull request #3890 from hashicorp/b-heartbeat
...
Heartbeat improvements and handling failures during establishing leadership
2018-03-12 14:41:59 -07:00
Josh Soref
173ce63fe9
spelling: transition
2018-03-11 19:06:05 +00:00
Josh Soref
88537de497
spelling: passed
2018-03-11 18:36:49 +00:00
Josh Soref
0869d9c4ee
spelling: deployments
2018-03-11 17:53:43 +00:00
Alex Dadgar
040599dae9
Fix leaking time.After function
2018-02-20 12:47:43 -08:00
Alex Dadgar
601177c250
Add escape hatches when non-leader
2018-02-20 10:22:15 -08:00
Preetha Appan
6468883cd1
Adds comment to handleRollbackValidity method and other small test readability fixes.
2017-11-03 17:05:15 -05:00
Preetha Appan
7526853b4b
Added more unit tests for testing rollback when job has identical spec to AllocHealth and DeploymentStatus endpoints.
2017-11-03 16:07:06 -05:00
Preetha Appan
b9f44c0ae0
Check that job version doesn't change when rollback does not occur due to identical spec
2017-11-03 15:46:37 -05:00
Preetha Appan
317fbf04b1
Adds SpecChanged check to alloc health and fail deployment end points, and other code review comments.
2017-11-03 15:33:34 -05:00
Preetha Appan
97474a1521
Clarify comment about infinite revert cycles
2017-11-03 14:25:14 -05:00