Alex Dadgar
6d0cd01a6a
Merge pull request #4868 from hashicorp/b-plugin-ctx
...
Plugin client's handle plugin dying
2018-11-13 10:26:53 -08:00
Mahmood Ali
66fc70fe50
Merge pull request #4845 from hashicorp/r-exec-refactor
...
Update exec driver to match rawexec
2018-11-12 20:59:32 -05:00
Alex Dadgar
9d42f4d039
Plugin client's handle plugin dying
...
This PR plumbs the plugins done ctx through the base and driver plugin
clients (device already had it). Further, it adds generic handling of
gRPC stream errors.
2018-11-12 17:09:27 -08:00
Danielle Tomlinson
1a17741e86
rawexec: Only use cgroups when running as root.
...
If Nomad is not running as root, we should not try to use cgroups for pid
freezing.
This originally was implemented pre-driver-support in
https://github.com/hashicorp/nomad/blob/v0.8.6/client/driver/raw_exec.go#L120-L130
2018-11-10 06:45:11 -08:00
Mahmood Ali
c794e70c4d
Update exec driver to match rawexec
...
Update exec driver with latest patterns used by rawexec, and eliminate
accidental diffs.
2018-11-08 10:00:49 -08:00
Alex Dadgar
57f40c7e3e
Device manager
...
Introduce a device manager that manages the lifecycle of device plugins
on the client. It fingerprints, collects stats, and forwards Reserve
requests to the correct plugin. The manager, also handles device plugins
failing and validates their output.
2018-11-07 10:43:15 -08:00
Mahmood Ali
f7d83d7e80
Implement java driver
2018-11-06 12:41:39 -08:00
Michael Schurter
fdbe446ea6
client: first pass at implementing task restoring
...
Task restoring works but dead tasks may be restarted
2018-11-05 12:32:05 -08:00
Michael Schurter
4d707b5e8c
rawexec: standardize names/code
2018-11-01 15:53:07 -07:00
Michael Schurter
0d1a8bf7fd
rawexec: fix fingerprint results and tests
...
In tests:
* always cleanup (Kill) the harness
* don't call SetConfig more than once (a race)
* avoid cgroups to allow running without being root
2018-10-30 17:16:22 -07:00
Michael Schurter
7d250fc58c
rawexec: fix race around h.procState
2018-10-30 17:15:47 -07:00
Nick Ethier
da7563b8c3
Merge pull request #4795 from hashicorp/f-plugin-config
...
Pass client configuration to plugins through loader
2018-10-29 18:42:27 -07:00
Nick Ethier
95d381cff7
rename NomadConfig to ClientAgentConfig
2018-10-29 21:34:34 -04:00
Nick Ethier
b837bf3ce3
drivers: update SetConfig to handle driver client config
2018-10-18 23:32:17 -04:00
Nick Ethier
87748fe423
update rkt and exec setconfig funcs
2018-10-16 23:00:26 -04:00
Nick Ethier
3244a4cc57
plumb NomadConfig into plugins
2018-10-16 22:47:22 -04:00
Alex Dadgar
a10d3964d0
Do not use cty in drivers
2018-10-16 17:17:07 -07:00
Michael Schurter
4175e908dd
fixup comments, logging, and missing method impls
...
from #4777 comments
2018-10-16 16:56:56 -07:00
Michael Schurter
7848acbea4
register drivers by default
...
Do not register mock_driver on release builds.
2018-10-16 16:56:56 -07:00
Nick Ethier
2e055fe18a
client: add test for driverfailure during fingerprinting
2018-10-16 16:56:56 -07:00
Preetha Appan
53381035db
Get raw exec tests compiling and passing again
2018-10-16 16:56:56 -07:00
Nick Ethier
4f9522dd54
client: review comments and fixup/skip tests
2018-10-16 16:56:56 -07:00
Nick Ethier
d335a82859
client: begin driver plugin integration
...
client: fingerprint driver plugins
2018-10-16 16:56:56 -07:00
Alex Dadgar
627e20801d
Fix lints
2018-10-16 16:56:56 -07:00
Nick Ethier
db981de8e4
drivers/shared: move eventer to subpackage under drivers shared package
2018-10-16 16:56:55 -07:00
Nick Ethier
ca27a0254b
drivers/utils: better handling of consumer cleanup in eventer
2018-10-16 16:56:55 -07:00
Nick Ethier
207522be55
drivers/rawexec: PR comments and feedback
2018-10-16 16:56:55 -07:00