Commit Graph

13611 Commits

Author SHA1 Message Date
Preetha Appan
4453602c24 Make affinity e2e tests wait for leader through Before method 2018-12-19 09:56:44 -06:00
Preetha Appan
f86c6976ed minor refactoring of affinities tests 2018-12-19 09:05:01 -06:00
Danielle Tomlinson
0b12ef11a2 changelog: Add entry for glob namespaces 2018-12-19 13:09:45 +01:00
Danielle Tomlinson
0ca8b236ff Merge pull request #4982 from hashicorp/f-acls-glob-ns
acl: Add support for globbing namespaces
2018-12-19 12:49:43 +01:00
Danielle Tomlinson
f10dbbec54 guides: Update for globbed namespace rules 2018-12-19 12:48:56 +01:00
Nick Ethier
a57dc29cbf Merge pull request #4964 from hashicorp/f-drivermananger-part2
client driver manager
2018-12-19 00:44:14 -05:00
Nick Ethier
c98aaad342 devicemanager: fix devicemanager tests 2018-12-19 00:35:12 -05:00
Nick Ethier
1ff3b681da drivermanager: use correct plugin config types 2018-12-18 23:07:01 -05:00
Nick Ethier
12528cadda drivermanager: attempt to reattach and shutdown driver plugin if blocked by allow/block lists 2018-12-18 23:01:57 -05:00
Nick Ethier
6951ca487d drivermanager: use allocID and task name to route task events 2018-12-18 23:01:51 -05:00
Nick Ethier
3100f7bd64 client/pluginmanager: add plugin manager interface to device/driver managers 2018-12-18 22:56:23 -05:00
Nick Ethier
331793e283 client: batch initial fingerprinting in plugin manangers
drivermanager: fix pr comments/feedback
2018-12-18 22:56:19 -05:00
Nick Ethier
2f010a2f25 client/drivermananger: fixup issues from rebase and address PR comments 2018-12-18 22:55:38 -05:00
Nick Ethier
32aaedd6b7 tr: deregister task handler on cleanup 2018-12-18 22:55:38 -05:00
Nick Ethier
39ca1b00dd client/drivermananger: add driver manager
The driver manager is modeled after the device manager and is started by the client.
It's responsible for handling driver lifecycle and reattachment state, as well as
processing the incomming fingerprint and task events from each driver. The mananger
exposes a method for registering event handlers for task events that is used by the
task runner to update the server when a task has been updated with an event.

Since driver fingerprinting has been implemented by the driver manager, it is no
longer needed in the fingerprint mananger and has been removed.
2018-12-18 22:55:18 -05:00
Alex Dadgar
c6bb070bdf Merge pull request #5015 from hashicorp/f-plugin-versions
Add plugin API versioning to plugin loader and plugins
2018-12-18 16:49:02 -08:00
Alex Dadgar
52202c68fc fix docker launching plugins 2018-12-18 16:48:01 -08:00
Alex Dadgar
07a7555acd lint 2018-12-18 16:48:00 -08:00
Alex Dadgar
ed4f8eac6e Add plugin API versioning to plugin loader and plugins 2018-12-18 16:48:00 -08:00
Alex Dadgar
0cdf6634a5 base fixes 2018-12-18 16:48:00 -08:00
Alex Dadgar
d4fd73d536 protos 2018-12-18 16:48:00 -08:00
Alex Dadgar
296141bb58 Merge pull request #5002 from hashicorp/b-task-config-resources
Convert driver resource to AllocatedTaskResource
2018-12-18 16:46:34 -08:00
Preetha
e6aa2168be Merge pull request #5024 from hashicorp/f-affinities-e2e
Affinities e2e tests
2018-12-18 18:41:16 -06:00
Preetha Appan
d10b9b79a2 Affinities e2e tests 2018-12-18 18:39:45 -06:00
Danielle Tomlinson
5d3e27e691 Merge pull request #5007 from hashicorp/dani/f-allocrunner-async
allocrunner: Async api for shutdown/destroy/update
2018-12-19 01:26:41 +01:00
Alex Dadgar
517bf1c35f Fix unit tests + upgrade pathing resources 2018-12-18 15:50:44 -08:00
Alex Dadgar
d5512c39f0 Lint 2018-12-18 15:50:44 -08:00
Alex Dadgar
7a0b73341a LinuxResources doesn't use task.Resources 2018-12-18 15:50:44 -08:00
Alex Dadgar
cd6879409c Drivers 2018-12-18 15:50:11 -08:00
Alex Dadgar
da6925bfc1 utilities 2018-12-18 15:48:52 -08:00
Alex Dadgar
e1cf3ac69e protos 2018-12-18 15:48:52 -08:00
Danielle Tomlinson
0984bf1812 Merge pull request #5021 from hashicorp/dani/rand-tasks
taskrunner: Use a random suffix for Task Config
2018-12-19 00:39:55 +01:00
Danielle Tomlinson
b92bc1178d taskrunner: Use a random suffix for Task Config
The RestartCount is not really suitable for use as a source of
uniqueness within task invocations as it is not monotonic, and interacts
with the restart stanza in a users config, so conflates restarts due to
task failures, with restarts due to enviromental changes, such as consul
template or vault secrets changing.

Here we instead use a substring from a uuid, which is more random than
we strictly need, but is nicer than rolling our own random string
generator here.
2018-12-19 00:38:54 +01:00
Danielle Tomlinson
f619db297f client: Update tests for async destroy 2018-12-18 23:38:34 +01:00
Danielle Tomlinson
502f36335e allocrunner: Drop and log updates after closing waitCh 2018-12-18 23:38:34 +01:00
Danielle Tomlinson
5464a9565a allocrunner: Documentation for ShutdownCh/DestroyCh 2018-12-18 23:38:34 +01:00
Danielle Tomlinson
9f1b53f2a8 fixup: Log when we detect out of order updates 2018-12-18 23:38:33 +01:00
Danielle Tomlinson
69fc73767a allocrunner: Handle updates asynchronously
This creates a new buffered channel and goroutine on the allocrunner for
serializing updates to allocations. This allows us to take updates off
the routine that is used from processing updates from the server,
without having complicated machinery for tracking update lifetimes, or
other external synchronization.

This results in a nice performance improvement and signficantly better
throughput on batch changes such as preempting a large number of jobs
for a larger placement.
2018-12-18 23:38:33 +01:00
Danielle Tomlinson
6f636ea15a gc: Wait for allocrunners to be destroyed 2018-12-18 23:38:33 +01:00
Danielle Tomlinson
934d2e6bf6 client: Async API for shutdown/destroy allocrunners 2018-12-18 23:38:33 +01:00
Danielle Tomlinson
800bd57333 allocrunner: Async shutdown and destroy
This commit reduces the locking required to shutdown or destroy
allocrunners, and allows parallel shutdown and destroy of allocrunners during
shutdown.
2018-12-18 23:38:33 +01:00
Omar Khawaja
a6e15202ce Commenting out dead link to demo.nomadproject.io (#5017)
* removing dead link

* comment out header and footer to UI demo

* adding reference to link back and commenting it out
2018-12-18 17:26:51 -05:00
Preetha
08ffb0b15f Merge pull request #5012 from hashicorp/f-e2e-provisioning
Terraform configs for e2e tests
2018-12-18 13:45:58 -06:00
Preetha Appan
75294a781a added readme 2018-12-18 13:37:03 -06:00
Michael Lange
5084eda866 Merge pull request #4981 from hashicorp/b-ui-hide-stats-graphs-for-non-running-resources
UI: Hide stats graphs for non running resources
2018-12-18 11:15:39 -08:00
Danielle Tomlinson
be9763dc9b Merge pull request #5016 from hashicorp/dani/b-docker-delete-task-on-destroy
docker: Delete Task on Destroy
2018-12-18 18:22:36 +01:00
Danielle Tomlinson
ad4bac8d77 docker: Delete Task on Destroy
Currently the docker driver does not remove tasks from its state map
when destroying the task, which leads to issues when restarting tasks in
place, and leaks expired handles over time.
2018-12-18 15:53:31 +01:00
Michael Lange
fc7455c104 Merge pull request #4994 from hashicorp/b-ui-dots-in-tasks
UI: Bugs around dots in task/task-group/driver names
2018-12-17 15:50:31 -08:00
Preetha Appan
82f95b2e0c suggestions from code review 2018-12-17 15:06:22 -06:00
Jack Pearkes
dca95c2e57 Terraform configs for e2e tests 2018-12-17 11:40:09 -06:00