Commit Graph

18247 Commits

Author SHA1 Message Date
Michael Lange c84070fc42 Key allocation rows to prevent unnecessary re-renders 2020-05-12 21:30:32 -07:00
Mahmood Ali 3b4116e0db
Merge pull request #7894 from hashicorp/b-cronexpr-dst-fix
Fix Daylight saving transition handling
2020-05-12 16:36:11 -04:00
Mahmood Ali 326793939e vendor: use tagged cronexpr, v1.1.0
Also, update to the version with modification notice
2020-05-12 16:20:00 -04:00
Jeff Escalante 25810fe526 fix formatting error on preemption docs page 2020-05-12 14:08:55 -04:00
Drew Bailey 7d53bb6283
Merge pull request #7936 from josegonzalez/patch-1
docs: add note that only system job preemption is available in OSS
2020-05-12 13:29:47 -04:00
Jose Diaz-Gonzalez 0b9c1db330
Update website/pages/docs/internals/scheduling/preemption.mdx
Co-authored-by: Drew Bailey <2614075+drewbailey@users.noreply.github.com>
2020-05-12 13:21:15 -04:00
Jose Diaz-Gonzalez de5b5a071d
docs: add note that only system job preemption is available in OSS 2020-05-12 13:02:13 -04:00
Mahmood Ali 3dfd663237
update changelog (#7934) 2020-05-12 12:22:22 -04:00
Mahmood Ali 04a3cfbeff
Merge pull request #7932 from hashicorp/f-docker-custom-runtimes
Docker runtimes
2020-05-12 11:59:36 -04:00
Mahmood Ali 9f95a50129 update tests 2020-05-12 11:39:09 -04:00
Spencer Owen 02d46b6e5a
fix typo in changelog (#7930)
Fixes a bad link in the changelog
2020-05-12 11:14:07 -04:00
Mahmood Ali 130d8d36e7 update docs 2020-05-12 11:07:12 -04:00
Mahmood Ali 182b95f7b1 use allow_runtimes for consistency
Other allow lists use allow_ prefix (e.g. allow_caps, allow_privileged).
2020-05-12 11:03:08 -04:00
Mahmood Ali 54565e3836
Apply suggestions from code review
Co-authored-by: Tim Gross <tgross@hashicorp.com>
2020-05-12 10:56:47 -04:00
Mahmood Ali 06c672cbf2 more tests 2020-05-12 10:14:54 -04:00
Mahmood Ali 0d692f0931 Add a knob to restrict docker runtimes 2020-05-12 10:14:43 -04:00
Chris Baker fce0e81d8c
Merge pull request #7928 from hashicorp/license-drop-tags
remove tags from api struct
2020-05-12 08:40:02 -05:00
Tim Gross 4374c1a837
csi: support Secrets parameter in CSI RPCs (#7923)
CSI plugins can require credentials for some publishing and
unpublishing workflow RPCs. Secrets are configured at the time of
volume registration, stored in the volume struct, and then passed
around as an opaque map by Nomad to the plugins.
2020-05-11 17:12:51 -04:00
Drew Bailey 64b58775ab
remove tags from api struct 2020-05-11 16:38:35 -04:00
Tim Gross 938e626750
changelog entries for 0.11.2 CSI bugfixes and improvements (#7926) 2020-05-11 16:13:25 -04:00
Buck Doyle 8959791bfd
Add changelog entry for exec ACL-checking (#7925) 2020-05-11 15:04:48 -05:00
Buck Doyle c46d5517bb
Add ACL-checking to turn off exec button (#7919)
This closes #7453. It adds an abstraction to handle the common
needs of ability-determination.
2020-05-11 14:43:17 -05:00
Mahmood Ali 5fa6d2f54a
Merge pull request #7924 from hashicorp/b-codecgen-flags
Clarify Msgpack handling of json tags
2020-05-11 15:04:36 -04:00
Drew Bailey 93a2d81ff2
Merge pull request #7922 from hashicorp/disable-future-commands
disable license cli commands
2020-05-11 14:35:12 -04:00
Mahmood Ali 938e916d9c When serializing msgpack, only consider codec tag
When serializing structs with msgpack, only consider type tags of
`codec`.

Hashicorp/go-msgpack (based on ugorji/go) defaults to interpretting
`codec` tag if it's available, but falls to using `json` if `codec`
isn't present.

This behavior is surprising in cases where we want to serialize json
differently from msgpack, e.g. serializing `ConsulExposeConfig`.
2020-05-11 14:14:10 -04:00
Mahmood Ali b4fa8e9588 codec: we use hashicorp/go-msgpack exclusively
No need to maintain two msgpack handles!
2020-05-11 14:05:29 -04:00
Drew Bailey 466e8d5043
disable license cli commands 2020-05-11 13:49:29 -04:00
Seth Hoenig b533c19b9d
Merge pull request #7921 from hashicorp/f-upgrade-e2e-consul
e2e: upgrade consul in packer setup to 1.7.3 from 1.6.1
2020-05-11 11:21:07 -06:00
Seth Hoenig 623c804046 e2e: upgrade consul in packer setup to 1.7.3 from 1.6.1
There have been a number of bug fixes and features particularly around
Connect that will help us in Nomad's e2e tests. Upgrade Consul in our
packer builder so e2e can make use of the new version.
2020-05-11 11:17:28 -06:00
Buck Doyle 5956e2e322
Add assertions for title-area buttons (#7836)
This closes #7452.
2020-05-11 11:29:30 -05:00
Mahmood Ali faecf3a760
Add tests for running allocation client count (#7906)
* Add tests for running allocation client count

* remove redundant assertions
2020-05-11 12:28:31 -04:00
Tim Gross 6554e9ee37
csi: log fallthrough on invalid node IDs for client RPC (#7918)
When a CSI client RPC is given a specific node for a controller but
the lookup fails (because the node is gone or is an older version), we
fallthrough to select a node from all those available. This adds
logging to this case to aid in diagnostics.
2020-05-11 12:26:10 -04:00
Michael Lange a798c8c246
Merge pull request #7896 from hashicorp/f-ui/csi-namespace-issue
UI: CSI namespace bugs
2020-05-11 09:22:32 -07:00
Tim Gross 1ec41b6770
volumewatcher: stop watcher goroutines when there's no work (#7909)
The watcher goroutines will be automatically started if a volume has
updates, but when idle we shouldn't keep a goroutine running and
taking up memory.
2020-05-11 09:32:05 -04:00
Mahmood Ali 061a439f2c
Merge pull request #7912 from hashicorp/f-scheduler-algorithm-followup
Scheduler Algorithm Defaults handling and docs
2020-05-11 09:30:58 -04:00
Mahmood Ali 0384543d05
Merge pull request #7913 from hashicorp/deflake-TestTaskTemplateManager_BlockedEvents
Deflake TestTaskTemplateManager_BlockedEvents test
2020-05-11 09:30:44 -04:00
Mahmood Ali dff0fcf2f3
Merge pull request #7914 from hashicorp/b-csi-fix-slice-initialization
Fix slice initialization
2020-05-11 09:27:01 -04:00
Tim Gross 3aa761b151
Periodic GC for volume claims (#7881)
This changeset implements a periodic garbage collection of CSI volumes
with missing allocations. This can happen in a scenario where a node
update fails partially and the allocation updates are written to raft
but the evaluations to GC the volumes are dropped. This feature will
cover this edge case and ensure that upgrades from 0.11.0 and 0.11.1
get any stray claims cleaned up.
2020-05-11 08:20:50 -04:00
James Rasell d8ddb01a8e
Merge pull request #7916 from hashicorp/changelog-7903
changelog: add entry for GH-7902
2020-05-11 13:15:58 +02:00
James Rasell 8ca0b3081a
changelog: add entry for GH-7902 2020-05-11 09:26:43 +02:00
James Rasell aaf2fe033e
Merge pull request #7903 from hashicorp/b-gh-7902
api: validate scale count value is not negative.
2020-05-11 09:17:01 +02:00
Mahmood Ali 9fac6ea5d9 Fix slice initialization 2020-05-09 21:35:42 -04:00
Mahmood Ali 64de395df0 tests: ease debugging TestClientEndpoint_CreateNodeEvals
TestClientEndpoint_CreateNodeEvals flakes a bit but its output is very
confusing, as `structs.Evaluations` overrides GoString.

Here, we emit the entire struct of the evaluation, and hopefully we'll
figure out the problem the next time it happens
2020-05-09 16:04:32 -04:00
Mahmood Ali ff5c3e81b0 avoid logging after a test completes 2020-05-09 14:40:00 -04:00
Mahmood Ali 543f08c1ae Deflake TestTaskTemplateManager_BlockedEvents test
This change deflakes TestTaskTemplateManager_BlockedEvents test, because
it is expecting a number of events without accounting for transitional
state.

The test TestTaskTemplateManager_BlockedEvents attempts to ensure that a
template rendering emits blocked events for missing template ksys.

It works by setting a template that requires keys 0,1,2,3,4 and then
eventually sets keys 0,1,2,3 and ensures that we get a final event indicating
that keys 3 and 4 are still missing.

The test waits to get a blocked event for the final state, but it can
fail if receives a blocked event for a transitional state (e.g. one
reporting 2,3,4,5 are missing).

This fixes the test by ensuring that it waits until the final message
before assertion.

Also, it clarifies the intent of the test with stricter assertions and
additional comments.
2020-05-09 14:09:39 -04:00
Mahmood Ali 2c963885b0 handle upgrade path and defaults
Ensure that `""` Scheduler Algorithm gets explicitly set to binpack on
upgrades or on API handling when user misses the value.

The scheduler already treats `""` value as binpack.  This PR merely
ensures that the operator API returns the effective value.
2020-05-09 12:34:08 -04:00
Mahmood Ali cb39226332 Document scheduler algorithm 2020-05-09 12:12:38 -04:00
Michael Lange 5e6a89836b The active namespace is now shared between jobs and storage 2020-05-08 17:35:27 -07:00
Michael Lange b3fe5b4f75 Changing namespaces now situationally redirects to jobs or volumes
Changing namespaces can be done anywhere in the app even though many
Nomad resources aren't namespace-sensitive (e.g., clients, plugins).

A user changing namespaces is an intent to reset context, "now I want
to begin a task that relates to Namespace X". Where that task begins
used to always be the Jobs list, since it was the only namespace
sensitive resource. Now with CSI Volumes, "square 1" is Volumes if the
namespace is changed from a storage page.
2020-05-08 17:35:27 -07:00
Michael Lange 2d6cedc1b5
Merge pull request #7895 from hashicorp/f-ui/csi-search-and-filter
UI: CSI Searchable volumes and plugins lists
2020-05-08 17:34:24 -07:00