Commit Graph

6268 Commits

Author SHA1 Message Date
Michael Schurter ec81325ddc Stop being so confusing 2017-01-12 11:17:35 -08:00
Michael Schurter 4d081490e6 Add Cleanup method to Driver interface
Cleanup can be used for cleaning up resources created by drivers to run
a task. Initially the Docker driver is the only user (to remove
downloaded images).
2017-01-11 17:23:33 -08:00
Alex Dadgar a616e9d970 Merge pull request #2163 from hashicorp/b-summary
Job Summary: Fix queued accounting and remove in-place state store updates
2017-01-11 13:36:36 -08:00
Alex Dadgar e2b79a4877 Changelog 2017-01-11 13:27:13 -08:00
Alex Dadgar aafb9ca8b2 Merge pull request #2177 from hashicorp/b-blocking-getallocs
GetAllocs uses a blocking query
2017-01-11 13:24:32 -08:00
Alex Dadgar 5d2b56b387 Random wait 2017-01-11 13:24:23 -08:00
Alex Dadgar efbb2894c7 Review fixes 2017-01-11 13:18:36 -08:00
Michael Schurter 93892a9a72 Add entry for force_pull #2147 2017-01-11 13:15:44 -08:00
Alex Dadgar 5c7b6c654d changelog 2017-01-11 13:12:37 -08:00
Michael Schurter 5d4df63f61 Merge pull request #2147 from novilabs/docker-force-pull
add force_pull to docker driver
2017-01-11 13:11:38 -08:00
Alex Dadgar 0f046b179a Merge pull request #2155 from hashicorp/f-cancel
Cancel blocked evals upon successful one for job
2017-01-11 13:10:35 -08:00
Cameron Davison c910f9b304
using new ctx instead of getting both params back 2017-01-10 16:54:01 -06:00
Cameron Davison 7ccbd8a000
fixing typo in comment 2017-01-10 16:54:01 -06:00
Cameron Davison 88a462d5b9
add force_pull to docker driver 2017-01-10 16:54:01 -06:00
Alex Dadgar cdc08bbd22 Merge pull request #2179 from hashicorp/b-panic
Fix nil dereference
2017-01-10 14:15:17 -08:00
Alex Dadgar bb329977a4 Fix nil dereference 2017-01-10 14:14:58 -08:00
Michael Schurter 0b7f8163d2 Merge pull request #2174 from hashicorp/b-fix-executor-test
Switch to a less timing dependent test command
2017-01-10 13:45:12 -08:00
Michael Schurter 1347a941b0 Fix missing value in test failure message 2017-01-10 13:39:05 -08:00
Alex Dadgar fec2c32bdf Changelog 2017-01-10 13:36:35 -08:00
Alex Dadgar 4127a3ea9d Merge pull request #2173 from hashicorp/b-stats
Don't retrieve Driver Stats if unsupported
2017-01-10 13:32:03 -08:00
Alex Dadgar c19985244a GetAllocs uses a blocking query
This PR makes GetAllocs use a blocking query as well as adding a sanity
check to the clients watchAllocation code to ensure it gets the correct
allocations.

This PR fixes https://github.com/hashicorp/nomad/issues/2119 and
https://github.com/hashicorp/nomad/issues/2153.

The issue was that the client was talking to two different servers, one
to check which allocations to pull and the other to pull those
allocations.  However the latter call was not with a blocking query and
thus the client would not retreive the allocations it requested.

The logging has been improved to make the problem more clear as well.
2017-01-10 13:30:35 -08:00
Michael Schurter 7462379086 Switch to a less timing dependent test command
`/usr/bin/yes` could produce output very quickly (100s of MBps on my
laptop) and therefore could cause log files to roll over.

A bash loop with a sleep avoids that issue. The test is slower but
should be much more resilient to the massive timing differences between
workstations and Travis.
2017-01-09 15:40:53 -08:00
Alex Dadgar 426d806401 Merge branch 'master' of github.com:hashicorp/nomad 2017-01-09 15:38:11 -08:00
Alex Dadgar 669dd0bd9a Add better docs for destination 2017-01-09 15:38:04 -08:00
Alex Dadgar 2be221d664 Don't retrieve Driver Stats if unsupported
This PR makes us only try to collect stats once if the Driver doesn't
support collecting stats.

Fixes https://github.com/hashicorp/nomad/issues/1986
2017-01-09 13:47:06 -08:00
Alex Dadgar 26e2c5bb74 Merge pull request #2164 from hashicorp/b-dispatch
Create Task directory structure in the Run method
2017-01-09 11:24:46 -08:00
Alex Dadgar 119fbc45d6 Merge pull request #2165 from hashicorp/b-driver-events
Send Driver events to servers immediately
2017-01-09 11:23:38 -08:00
Alex Dadgar 302a0cf382 Fix adjust test 2017-01-08 14:14:35 -08:00
Alex Dadgar ea0de75889 Merge pull request #2162 from asvoboda/patch-1
Update network.html.md
2017-01-08 13:55:56 -08:00
Alex Dadgar 2a5fd85e3b Move to Run() 2017-01-08 13:55:12 -08:00
Alex Dadgar 6f8483b575 Changelog 2017-01-08 13:55:12 -08:00
Alex Dadgar 2affef2972 Create task directory during Prestart() 2017-01-08 13:55:12 -08:00
Alex Dadgar 2c838a80f6 Detect newly created allocation's properly 2017-01-08 13:55:03 -08:00
Alex Dadgar d0f918495b Store pointer of JobSummary in state store and remove in-place modifications of the object and replace with Copy-Update-Insert operations 2017-01-08 13:55:03 -08:00
Alex Dadgar 4ffd9a69e5 Send Driver events to servers immediately
This PR causes driver events to be sent to the server immediately rather
than waiting for Prestart() to finish.
2017-01-08 13:54:43 -08:00
Alex Dadgar 724edb6659 Fix fingerprint tests 2017-01-08 13:53:27 -08:00
Andrew Svoboda c46594534a Update network.html.md
Update typo
2017-01-06 17:32:24 -08:00
Diptanu Choudhury 9456b861dc Merge pull request #2161 from hashicorp/f-cpu-arch
Fixed namespacing for the cpu arch
2017-01-06 14:41:08 -08:00
Diptanu Choudhury eb123416c5 Fixed namespacing for the cpu arch 2017-01-06 14:23:22 -08:00
Michael Schurter d032893010 Merge pull request #2132 from hashicorp/f-chrootectomy-4
Move chroot building into TaskRunner
2017-01-06 13:03:08 -08:00
Michael Schurter 65fb580216 Fix inconsistent task env setting
Consolidate task environment building in GetTaskEnv since it can
determine what kind of filesystem isolation is used.

This means drivers no longer have to manipulate task environment paths.
2017-01-06 12:19:32 -08:00
Diptanu Choudhury 5163e0fa94 Updated docs for /job/allocations endpoint 2017-01-06 11:44:49 -08:00
Michael Schurter d3270799f0 Fix executor tests 2017-01-06 11:39:18 -08:00
Michael Schurter acd11f678d Add COMPAT comment 2017-01-06 11:39:17 -08:00
Michael Schurter e203928d64 Driver is now required in test tasks 2017-01-06 11:39:17 -08:00
Michael Schurter 90f6ac7490 Fix tests post rebase 2017-01-06 11:39:13 -08:00
Alex Dadgar a37656e7d8 Add QueuedAllocations to api.Evaluation 2017-01-06 11:32:14 -08:00
Alex Dadgar f8c930d006 Version bump 2017-01-06 11:22:38 -08:00
Michael Schurter 579f378bee Remove debug logging 2017-01-05 16:31:56 -08:00
Michael Schurter baf6f078d6 Remove task name prefix from executor logs 2017-01-05 16:31:56 -08:00