Michael Schurter
b8b1922b9b
test: fix by using mock.BatchJob
2018-03-21 16:51:45 -07:00
Michael Schurter
80885623c1
test: don't call t.Fatal from within a goroutine
2018-03-21 16:51:45 -07:00
Michael Schurter
aab1fb7672
Fix linting errors
2018-03-21 16:51:45 -07:00
Michael Schurter
e669e8213a
Improve drain log messages
...
Also delay "node complete" after the node has been marked complete to
capture a few more alloc events. There are other ways to implement this
that could trade off correctness for responsiveness as technically a
node is considered drained when all of its allocs have been marked to
stop and not when they've actually stopped (which may not happen for a
long time).
2018-03-21 16:51:45 -07:00
Michael Schurter
11d0eae5ed
Monitor node drains until completion in CLI
...
allow -detach like other commands
2018-03-21 16:51:45 -07:00
Michael Schurter
fb6c821526
Fix node eligibility test
2018-03-21 16:51:45 -07:00
Alex Dadgar
d15371405f
Toggle Drain allows resetting eligibility
...
This PR allows marking a node as eligible for scheduling while toggling
drain. By default the `nomad node drain -disable` commmand will mark it
as eligible but the drainer will maintain in-eligibility.
2018-03-21 16:51:44 -07:00
Alex Dadgar
7f989499ff
Correct defaulting
2018-03-21 16:51:44 -07:00
Alex Dadgar
7d58209927
code review
2018-03-21 16:51:44 -07:00
Alex Dadgar
d65ae92dfa
Small refactor and cleanups
2018-03-21 16:51:44 -07:00
Alex Dadgar
d6399cb733
Add eligibility to node view
2018-03-21 16:51:44 -07:00
Alex Dadgar
378c566294
node eligibility command
2018-03-21 16:51:44 -07:00
Alex Dadgar
0fb9ba7732
HTTP and API
2018-03-21 16:51:44 -07:00
Alex Dadgar
5c101de725
flag comment
2018-03-21 16:51:44 -07:00
Alex Dadgar
a7833bc609
Upgrade path
2018-03-21 16:51:43 -07:00
Alex Dadgar
2bdeacebff
Drain cli, api, http
2018-03-21 16:51:43 -07:00
Preetha
90581c15be
Merge pull request #4007 from hashicorp/f-show-rescheduling-cli-job-status
...
Show a section on upcoming delayed evaluations when applicable
2018-03-21 14:37:38 -05:00
Preetha Appan
6cf5a1b326
More code review feedback
2018-03-21 14:28:14 -05:00
Preetha Appan
9c7750e7c6
Fix test
2018-03-21 09:24:28 -05:00
Preetha Appan
a896b2edf2
Addressed code review feedback
2018-03-21 09:15:29 -05:00
Michael Schurter
09511dbf7d
Merge pull request #4003 from jrasell/f_gh_3988
...
Allow Nomads Consul health check names to be configurable.
2018-03-20 16:44:08 -07:00
Preetha Appan
5e038e4106
Show reschedule policy in addition to when the eval will get rescheduled
2018-03-20 13:34:29 -05:00
James Rasell
dda9207b06
Update Consul check params from using health-check to check.
2018-03-20 16:03:58 +01:00
Preetha Appan
c40803a63f
Unit test and linting fix
2018-03-19 22:11:07 -05:00
Preetha Appan
20a9613adf
Show a section on upcoming delayed evaluations when applicable
2018-03-19 21:42:37 -05:00
Preetha
87865ce99e
Merge pull request #4006 from hashicorp/b-alloc-status-cli-hide-unlimited-attempts
...
Hide the number of reschedule attempts for unlimited rescheduling
2018-03-19 18:25:20 -05:00
Preetha Appan
55d17cf26f
Hide the number of reschedule attempts for unlimited rescheduling
2018-03-19 18:06:15 -05:00
Michael Schurter
82fb214f93
Fix generating static assets
...
Broke due to a change in go-bindata-assetfs
2018-03-19 15:52:38 -07:00
James Rasell
2439310951
Allow Nomads Consul health checks to be configurable.
...
This change allows the client HTTP and the server HTTP, Serf and
RPC health check names within Consul to be configurable with the
defaults as previous. The configuration can be done via either a
config file or using CLI flags.
Closes #3988
2018-03-19 19:37:56 +01:00
Preetha
c57fe9e35b
Merge pull request #4002 from hashicorp/b-reschedule-systemjob-panic
...
Fix incorrect initialization of reschedule policy for system jobs.
2018-03-19 13:06:55 -05:00
Preetha Appan
e5b86d405e
Fix incorrect initialization of reschedule policy for system jobs.
2018-03-19 12:16:13 -05:00
Alex Dadgar
02132ed6ab
Merge pull request #3997 from hashicorp/b-serf-addr
...
RPC Advertise used exclusively for Clients
2018-03-19 09:30:20 -07:00
Alex Dadgar
7ba99a604d
enable server in test
2018-03-16 16:52:37 -07:00
Alex Dadgar
b49462b5ff
Heartbeat uses client rpc advertise and server defaults server rpc advertise addr
2018-03-16 16:47:08 -07:00
Alex Dadgar
5976511b05
Separate client and server rpc advertise addresses
2018-03-16 16:47:08 -07:00
Michael Schurter
5aff4dddfd
Remove unnecessary conversions
2018-03-16 16:32:59 -07:00
Michael Schurter
16538f6474
gofmt -s (simplify) files
2018-03-16 16:31:16 -07:00
Michael Schurter
b20421de3b
Merge pull request #3984 from hashicorp/f-loosen-consul-skipverify
...
Replace Consul TLSSkipVerify handling
2018-03-16 11:21:28 -07:00
Michael Schurter
9f50ab334c
Replace Consul TLSSkipVerify handling
...
Instead of checking Consul's version on startup to see if it supports
TLSSkipVerify, assume that it does and only log in the job service
handler if we discover Consul does not support TLSSkipVerify.
The old code would break TLSSkipVerify support if Nomad started before
Consul (such as on system boot) as TLSSkipVerify would default to false
if Consul wasn't running. Since TLSSkipVerify has been supported since
Consul 0.7.2, it's safe to relax our handling.
2018-03-14 17:43:06 -07:00
Alex Dadgar
66f85b20f0
Merge pull request #3978 from hashicorp/b-core-sched
...
Always add core scheduler
2018-03-14 16:13:15 -07:00
Preetha Appan
2ab03a13e0
fix method comment
2018-03-14 16:10:32 -05:00
Preetha Appan
69c4a58c34
Show reschedule eligibility time in alloc-status when followup evalid is available
2018-03-14 16:10:32 -05:00
Preetha Appan
74bd789c29
Fix formatting
2018-03-14 16:10:32 -05:00
Preetha Appan
d4056c4489
Rename DelayCeiling to MaxDelay
2018-03-14 16:10:32 -05:00
Preetha Appan
e65d870fe9
Add new reschedule options to API layer and unit tests
2018-03-14 16:10:32 -05:00
Alex Dadgar
61476d09a5
Always add core scheduler and detect invalid schedulers
2018-03-14 10:53:27 -07:00
Alex Dadgar
eceabb66f8
nodeevents -> events
2018-03-13 18:08:22 -07:00
Alex Dadgar
57ddd511cc
fixes
2018-03-13 18:08:22 -07:00
Chelsea Holland Komlo
319f80907c
code review feedback
2018-03-13 18:08:21 -07:00
Chelsea Holland Komlo
6eb9911caf
code review feedback
2018-03-13 18:08:21 -07:00