Michael Schurter
b58a22c2e9
remove spurious TODOs and FIXMEs
2018-03-21 16:55:22 -07:00
Michael Schurter
50a94d73c9
test: try to prevent flakiness on travis
2018-03-21 16:51:45 -07:00
Michael Schurter
1537061ebc
alloc_runner: watch health for deployed batch jobs
2018-03-21 16:51:45 -07:00
Michael Schurter
3ca9cdfadc
client: don't monitor health of non-service jobs
...
Also fix system job draining; won't work without deadline fixes
2018-03-21 16:51:44 -07:00
Alex Dadgar
3fe3c6eff7
Improve DeadlineTime helper
2018-03-21 16:51:44 -07:00
Alex Dadgar
48d637dad1
RPC, FSM, State Store for marking DesiredTransistion
...
fix build tag
2018-03-21 16:49:48 -07:00
Michael Schurter
91e8fd098f
mock_driver: improve Kill() logging
2018-03-21 16:49:48 -07:00
Michael Schurter
95b3b6eb02
drain: initial drainv2 structs and impl
2018-03-21 16:49:48 -07:00
Chelsea Holland Komlo
eb3a53efa2
always set initial health status for every driver
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
127b2c6ef7
set driver to unhealthy once if it cannot be detected in periodic check
2018-03-21 15:15:26 -04:00
Alex Dadgar
b59bea98b0
Docker driver doesn't return errors but injects into the DriverInfo
2018-03-21 15:15:26 -04:00
Alex Dadgar
ffe9292e24
Only run health check if driver is detected
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
9c143301de
fix issue when updating node events
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
cba0a4d441
function rename and re-arrange functions in fingerprint_manager
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
06a306e460
improve comments; update watchDriver
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
7b2ed01472
remove unused function
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
8597da0c5d
simplify logic
...
bump log level
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
115d54cb19
fix up health check logic comparison; add node events to client driver checks
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
8aefd294e1
Code review feedback
2018-03-21 15:15:26 -04:00
Alex Dadgar
3ad03d9498
notes from walk through
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
8a0ed4e5ff
improve tests
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
521fbd4f97
refresh driver information for non-health checking drivers periodically
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
240fee4848
fix up codereview feedback
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
865b7e0ace
fix up racy tests
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
fd25db9e1d
updating comments; locking concurrent node access
2018-03-21 15:15:26 -04:00
Chelsea Holland Komlo
9dfb5c6b46
go style; update comments
2018-03-21 15:15:25 -04:00
Chelsea Holland Komlo
9ec5a93bc1
fix scheduler driver name; create node structs file
2018-03-21 15:15:25 -04:00
Chelsea Holland Komlo
a340baddf1
allow nomad to schedule based on the status of a client driver health check
...
Slight updates for go style
2018-03-21 15:15:25 -04:00
Chelsea Holland Komlo
1570972cb3
add concept of health checks to fingerprinters and nodes
...
fix up feedback from code review
add driver info for all drivers to node
2018-03-21 15:15:25 -04: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
68b2e9678f
Merge pull request #3990 from hashicorp/f-rkt-groups
...
rkt: allow specifying --group
2018-03-16 11:19:53 -07:00
Michael Schurter
eeaaa60e5a
rkt: allow specifying --group
2018-03-16 11:08:22 -07:00
Michael Schurter
b096fd7539
docker: make volume errors recoverable
...
The interface+mock just to test this one little error handling may seem
like overkill but there was just no other way to write an automated test
around this logic as there's no way to simluate this error with stock
Docker.
2018-03-15 17:52:43 -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
Preetha Appan
dc183ad209
Fix spelling in comment
2018-03-14 15:54:25 -05:00
Alex Dadgar
4252ffe71c
fix clearing node events
2018-03-14 09:48:59 -07:00
Chelsea Komlo
9cb3a02b0f
Merge pull request #3945 from hashicorp/f-add-node-events
...
Add node events
2018-03-14 08:42:55 -04:00
Preetha
c4389cd61a
Merge pull request #3968 from hashicorp/f-nicer-vault-error
...
Make server side error messages from vault more clearer
2018-03-13 20:49:39 -05:00
Alex Dadgar
8ba5ba33de
small cleanup
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
Chelsea Holland Komlo
9ef6ad031a
fix up go check warnings
2018-03-13 18:08:21 -07:00
Chelsea Holland Komlo
a72dcbfcdd
add client side emitting of node events
...
Changelog
2018-03-13 18:08:21 -07:00
Preetha Appan
d83ad728db
Address some code review comments
2018-03-13 18:19:16 -05:00
Preetha Appan
f4a4685d84
Return the err from server correctly
2018-03-13 18:10:14 -05:00
Preetha Appan
71e4061e0e
Remove error wrapping and make vault connection server side errors clearer.
2018-03-13 17:09:03 -05:00
Michael Schurter
a90ce65def
Merge pull request #3958 from simplesurance/swappiness
...
fix: disable swap for executor_linux allocations
2018-03-13 10:10:22 -07:00
Fabian Holler
fbc461b904
fix: disable swap for executor_linux allocations
...
A comment in the nomad source code states that swapping for
executor_linux allocations is disabled but it wasn't.
Nomad wrote -1 to the memsw.limit_in_bytes cgroup file to disable
swapping.
This has the following problems:
1.) Writing -1 to the file does not disable swapping. It sets
the limit for memory and swap to unlimited.
2.) On common Linux distributions like Ubuntu 16.04 LTS the
memsw.limit_in_bytes cgroup file does not exist by default.
The memsw.limit_in_bytes file only exist if the Linux kernel is
build with CONFIG_MEMCG_SWAP=yes and either
CONFIG_MEMCG_SWAP_ENABLED=yes or when the kernel parameter
swapaccount=1 is passed during boot.
Most Linux distributions disable swap accounting by default because
of higher memory usage.
Nomad silently ignores if writing to the memsw.limit_in_bytes file
fails. The allocation succeeds, no message is logged to notify the
user.
To ensure that disabling swap works on common Linux kernels, disable
swapping by writing 0 to the memory.swappiness file.
Using the memory.swappiness file only requires that the kernel is
compiled with CONFIG_MEMCG=yes. This is the default in common Linux
kernels.
2018-03-13 10:52:50 +01:00
Alex Dadgar
42e9fe1b57
Merge pull request #3890 from hashicorp/b-heartbeat
...
Heartbeat improvements and handling failures during establishing leadership
2018-03-12 14:41:59 -07:00
Michael Schurter
8da7335c16
non-Existent -> nonexistent
...
Reverting from #3963
https://www.merriam-webster.com/dictionary/existent
2018-03-12 11:59:33 -07:00