Commit Graph

34 Commits

Author SHA1 Message Date
Piotr Kazmierczak
c4be2c6078 cleanup: replace TypeToPtr helper methods with pointer.Of (#14151)
Bumping compile time requirement to go 1.18 allows us to simplify our pointer helper methods.
2022-08-17 18:26:34 +02:00
Seth Hoenig
b242957990 ci: swap ci parallelization for unconstrained gomaxprocs 2022-03-15 12:58:52 -05:00
James Rasell
f5567b3261 cli: move tests to use NewMockUi func. 2020-10-05 16:07:41 +02:00
Tim Gross
a7bc31b011 fix broken test expectation from message change (#6635) 2019-11-06 16:33:13 -05:00
Michael Schurter
4a70644df0 drain: fix node drain monitoring
The whole approach to monitoring drains has ordering issues and lacks
state to output useful error messages.

AFAICT to get the tests passing reliably I needed to change the behavior
of monitoring.

Parts of these tests are skipped in CI, and they should be rewritten as
e2e tests.
2019-01-08 09:35:16 -08:00
Nick Ethier
0b235d89d9 fix test 2018-12-20 13:54:29 -05:00
Nick Ethier
617d102ce4 command: wait for drivers to be ready before test 2018-12-20 13:52:33 -05:00
Danielle Tomlinson
5050c5ffed command: Remove Extraneous field in nodedrain test 2018-11-30 10:46:13 +01:00
Alex Dadgar
29ee68d543 test less of the monitor on travis 2018-06-07 15:47:03 -07:00
Alex Dadgar
3402f2539f code review 2018-06-06 14:52:26 -07:00
Alex Dadgar
3c9ad243a4 Monitoring non-draining node exits 2018-06-05 17:58:44 -07:00
Alex Dadgar
304b76e1e2 Fix node drain monitor 2018-05-31 15:50:05 -07:00
Nick Ethier
0c62b9cd0f command: fix node drain monitor case 2018-05-24 06:39:12 -04:00
Nick Ethier
d7b17a719c command: add '-monitor' flag to node drain 2018-05-24 06:37:25 -04:00
James Rasell
805b5278e7 Update node-drain logging message to clearer for operators.
This change updates the console log message when performing a node
drain and particulary when a node has marked all allocs for
migration. Previously it logged 'drain complete' which was a little
confusing to operators as the node is not drained at this point.

Closes #4183
2018-04-24 07:50:01 +01:00
Nick Ethier
4a4ed06db1 command: update tests to check for new error message 2018-04-18 13:51:17 -04:00
Michael Schurter
55b98ee299 cli: add color to drain output 2018-03-30 11:15:12 -07:00
Michael Schurter
4cefb6f06a drain: block cli until all allocs stop
Before the drain CLI would block until the node was marked as completing
drain operations. While technically correct, it could lead operators (or
more likely: scripts) to shutdown drained nodes before all of its
allocations had *actually* terminated.

This change makes the CLI block until all allocations have terminated
(unless ignoring system jobs).
2018-03-29 10:56:09 -07:00
Michael Schurter
e669e8213a Improve drain log messages
Also delay "node complete" after the node has been marked complete to
capture a few more alloc events. There are other ways to implement this
that could trade off correctness for responsiveness as technically a
node is considered drained when all of its allocs have been marked to
stop and not when they've actually stopped (which may not happen for a
long time).
2018-03-21 16:51:45 -07:00
Michael Schurter
11d0eae5ed Monitor node drains until completion in CLI
allow -detach like other commands
2018-03-21 16:51:45 -07:00
Alex Dadgar
2bdeacebff Drain cli, api, http 2018-03-21 16:51:43 -07:00
Michael Schurter
8da7335c16 non-Existent -> nonexistent
Reverting from #3963

https://www.merriam-webster.com/dictionary/existent
2018-03-12 11:59:33 -07:00
Josh Soref
ac40c42533 spelling: existent 2018-03-11 18:30:37 +00:00
Alex Dadgar
01f584a9d8 Remove tests checking autocomplete only does 1 arg 2017-08-28 15:42:32 -07:00
Alex Dadgar
f18fbc6ba4 node drain 2017-08-22 13:13:44 -07:00
Alex Dadgar
a77c6a4f71 Parallel 2017-07-20 21:24:21 -07:00
Alex Dadgar
da25a3d5ce Switch to in-process agent 2017-07-20 21:07:32 -07:00
Ivo Verberk
cc4fea99fc Provide a consistent user experience with prefix based lookups.
* Require at least two characters for identifier
* Automatically strip off the last character in case of uneven length
2016-01-21 22:21:35 +01:00
Ivo Verberk
de3bc00a00 Detect a half-byte prefix and display a user-friendly error. 2016-01-21 20:53:05 +01:00
Ivo Verberk
ab9409184a Shorten CLI identifiers
* Truncate all UUID identifiers to eight characters by default
* Refactor the node identifier to an auto-generated UUID
* Created and updated tests and mocks
2016-01-14 21:57:43 +01:00
Ivo Verberk
905742249e Refactoring continued
* Refactor other cli commands to new design
* Add PrefixList method to api package
* Add more tests
2015-12-24 20:53:37 +01:00
Ryan Uber
550434dc9b command: dump allocations for nodes in node-status 2015-09-15 11:20:08 -07:00
Ryan Uber
7e26f938a2 command: use meta struct for common options 2015-09-14 13:24:03 -07:00
Ryan Uber
90108c7820 command: add node-drain command 2015-09-14 13:24:03 -07:00