Nick Ethier
7d80fe286f
drivers: use consts for task handle version
2019-01-16 21:52:31 -05:00
Nick Ethier
be81ecd5e6
drivers: add upgrade path for rawexec, java, rkt and qemu
2019-01-16 11:19:25 -05:00
Nick Ethier
52c40c6403
drivers: fix test
2019-01-16 09:28:41 -05:00
Nick Ethier
e7a4dbb8a7
cleanup code comments and small fixes from refactor
2019-01-15 17:07:21 -05:00
Nick Ethier
9ce0347e59
driver: add pre09 migration logic
2019-01-15 16:57:09 -05:00
Nick Ethier
12ae83bb79
executor: add pre 0.9 client and wrapper
2019-01-15 16:55:12 -05:00
Chris Baker
bb57f00f2c
Merge pull request #5194 from hashicorp/f-minor-update-docs-tense
...
docs: updated tense around fixed bug
2019-01-15 14:50:57 -05:00
Alex Dadgar
48283ae752
Merge pull request #5195 from hashicorp/d-update-087-date
...
make change to the 0.8.7 release date
2019-01-15 09:53:07 -08:00
Cathy Chang
1e7b110962
make change to the 0.8.7 release date
2019-01-15 09:47:13 -08:00
Chris Baker
25013af5b6
docs: updated tense around fixed bug
2019-01-15 17:43:03 +00:00
Danielle Tomlinson
9cf6e1ae27
Merge pull request #5192 from hashicorp/dani/executor-close
...
executor: Always close stdout/stderr fifos
2019-01-15 17:49:04 +01:00
Danielle Tomlinson
fb1e24d2b9
Merge pull request #5184 from hashicorp/dani/b-logmon-reattach
...
docker: Terminate dockerlogger
2019-01-15 16:48:40 +01:00
Danielle Tomlinson
17dbace46b
executor: Always close stdout/stderr fifos
2019-01-15 16:47:27 +01:00
Michael Schurter
3a491ab2b4
Merge pull request #5187 from hashicorp/test-consul
...
Port a bunch of pre-0.9 Consul tests to 0.9
2019-01-15 07:41:50 -08:00
Mahmood Ali
1bfec9e8e7
Merge pull request #5189 from hashicorp/b-fix-executor-logs
...
propagate logs to executor plugin
2019-01-15 10:26:01 -05:00
Danielle Tomlinson
f9a4594095
docker: Terminate dockerlogger
...
Previously, we did not attempt to stop Docker Logger processes until
DestroyTask, which means that under many circumstances, we will never
successfully close the plugin client.
This commit terminates the plugin process when `run` terminates, or when
`DestroyTask` is called.
Steps to repro:
```
$ nomad agent -dev
$ nomad init
$ nomad run example.nomad
$ nomad stop example
$ ps aux | grep nomad # See docker logger process running
$ signal the dev agent
$ ps aux | grep nomad # See docker logger process running
```
2019-01-15 14:58:05 +01:00
Mahmood Ali
2cc4466573
propogate logs to executor plugin
2019-01-15 08:25:03 -05:00
Alex Dadgar
109c5ef650
Merge pull request #5173 from hashicorp/b-log-levels
...
Plugins use parent loggers
2019-01-14 16:14:30 -08:00
Nick Ethier
97a73e0116
Merge pull request #5018 from hashicorp/f-executor-stats
...
executor: streaming stats api
2019-01-14 15:02:35 -05:00
Michael Schurter
7445e418ca
test: port some pre-0.9 DeploymentHealth tests
...
Skipping a failing one as I need to move to some other work and don't
want to leave this work orphaned on my machine.
2019-01-14 09:56:53 -08:00
Michael Schurter
b58a77ecc0
test: assert service interpolation behavior
...
Ported from pre-0.9 tests.
2019-01-14 09:56:53 -08:00
Michael Schurter
df0a6dc34e
test: add some extra logging
2019-01-14 09:56:53 -08:00
Michael Schurter
ceee126241
Remove old comment; it's been fixed!
2019-01-14 09:56:53 -08:00
Michael Schurter
99a5586aed
test: assert shutdown delay deregs first
...
Restore a pre-0.9 test that asserts Consul services are deregistered
before a task's shutdown delay.
2019-01-14 09:56:53 -08:00
Michael Schurter
903779769d
Update client/allocrunner/taskrunner/stats_hook.go
...
Co-Authored-By: nickethier <ncethier@gmail.com >
2019-01-14 12:31:27 -05:00
Nick Ethier
091cdbcb12
tr: stop stats collection on Exited hook
2019-01-14 12:30:14 -05:00
Nick Ethier
d086bb2d20
qemu: missing gofmt
2019-01-13 16:06:56 -05:00
Michael Schurter
60acfc8289
Update drivers/qemu/driver_test.go
...
use t.Logf instead of fmt.Printf
Co-Authored-By: nickethier <ncethier@gmail.com >
2019-01-12 21:33:55 -05:00
Nick Ethier
fc84e8f2bc
tr: add retry /w backoff to stats_hook failure
2019-01-12 12:18:24 -05:00
Nick Ethier
72a4685534
drivers: plumb grpc client logger
2019-01-12 12:18:23 -05:00
Nick Ethier
9904463da2
executor: fix failing stats related test
2019-01-12 12:18:23 -05:00
Nick Ethier
f6af1d4d04
docker: add test for stats collection
2019-01-12 12:18:22 -05:00
Nick Ethier
fbf9a4c772
executor: implement streaming stats API
...
plugins/driver: update driver interface to support streaming stats
client/tr: use streaming stats api
TODO:
* how to handle errors and closed channel during stats streaming
* prevent tight loop if Stats(ctx) returns an error
drivers: update drivers TaskStats RPC to handle streaming results
executor: better error handling in stats rpc
docker: better control and error handling of stats rpc
driver: allow stats to return a recoverable error
2019-01-12 12:18:22 -05:00
Preetha
f10c6259cb
Merge pull request #5164 from hashicorp/b-client-addalloc-errhandle
...
Handle client initialization errors when adding/restoring allocs
2019-01-12 10:40:41 -06:00
Preetha Appan
19777b870b
linting fixes
2019-01-12 10:38:20 -06:00
Preetha Appan
c66f2abefd
Make unit test for allocrunner failure much nicer
2019-01-12 10:38:20 -06:00
Preetha Appan
a1a7a02e48
Add unit test to simulate alloc runner creation failure
2019-01-12 10:38:20 -06:00
Preetha Appan
032ec425c2
Only set deployment health if not already set
2019-01-12 10:38:20 -06:00
Michael Schurter
a20ae598c7
Apply suggestions from code review
...
Co-Authored-By: preetapan <preetha@hashicorp.com >
2019-01-12 10:38:20 -06:00
Preetha Appan
72dead7448
REfactor statedb factory config to set it directly in client config
2019-01-12 10:38:20 -06:00
Preetha Appan
5d7472fe82
Remove invalid allocs
2019-01-12 10:38:20 -06:00
Preetha Appan
80919bf713
Modified destroy failure handling to rely on allocrunner's destroy method
...
Added a unit test with custom statedb implementation that errors, to
use to verify destroy errors
2019-01-12 10:37:12 -06:00
Preetha Appan
29894883a2
Add back code to mark alloc as failed when restore fails
...
Also modify restore such that any handled errors don't propagate
back to the client
2019-01-12 10:37:12 -06:00
Preetha Appan
80d92481ca
Revert code that made an alloc update when restore fails
...
Restore currently shuts down the client so the alloc update cant
always make it to the server
2019-01-12 10:37:12 -06:00
Preetha Appan
cf9c398296
Handle client initialization errors when adding allocs or restoring allocs
...
We mark the alloc as failed and track failed allocs so that we don't send
updates after the first time
2019-01-12 10:37:12 -06:00
Danielle Tomlinson
03bf0bb65a
Merge pull request #5025 from hashicorp/dani/allocLockCleanup
...
client: Cleanup allocrunner access
2019-01-11 23:35:02 +01:00
Alex Dadgar
754b84edb1
changelog
2019-01-11 13:09:44 -08:00
Alex Dadgar
f171a723cb
Enable json logs
2019-01-11 11:36:37 -08:00
Alex Dadgar
16e8cdf5bb
Update client1.hcl
2019-01-11 11:36:37 -08:00
Alex Dadgar
e3859dc5e5
fix rkt use of executor
2019-01-11 11:36:37 -08:00