Commit Graph

1146 Commits

Author SHA1 Message Date
Michael Lange b61d23feee Refactor job summary adapter to use the namespace ID base class 2020-07-29 19:07:24 -07:00
Michael Lange 17e6d5b836 Data modeling for job scale and scale events 2020-07-29 19:07:24 -07:00
Buck Doyle 7bed453de3
Add acceptance test accessibility auditing and fixes (#8455)
This introduces ember-a11y-testing to acceptance tests via a helper
wrapper that allows us to globally ignore rules that we can address
separately. It also adds fixes for the aXe rules that were failing.
2020-07-28 12:59:14 -05:00
Michael Lange e7d414d9c2 Include the region query param on the View Raw File link in the task fs explorer 2020-07-22 13:46:38 -07:00
Buck Doyle 9e3ae523d6
Fix layout of title component elements (#8495)
The spacing has been broken for job types that use this yield
(parameterised and periodic) since I added the exec button
to this template. This could be further refined to allow a more
logical grouping of elements where buttons and tags are
separate.
2020-07-22 11:30:58 -05:00
Michael Lange 1cb0de64e0 Always send region as a query param 2020-07-21 09:00:20 -07:00
Buck Doyle 7f0177548d
Add specificity to exec allocation URL generation (#8463)
Thanks to @notnoop for this UX improvement suggestion.
The allocation’s task group is always known, so it
might as well be preselected in the sidebar when the
exec window opens. Also, if the task group only has
one task, might as well preselect it too.
2020-07-20 16:07:39 -05:00
Buck Doyle 8a4dc0726d
Fix typo in exec button URL-generation (#8460)
This closes #8422, another bug facilitated by the difficulty
of automated testing when opening another window. Thanks to
@notnoop for narrowing this down.
2020-07-20 16:06:55 -05:00
Buck Doyle 77b4d59f5d
Change edition to Octane (#8418)
This updates the Ember edition setting to Octane, which I removed from #8319
because it required the template-only Glimmer components setting to be turned
on, which this does. These changes to templates accommodate that setting.
2020-07-13 09:26:12 -05:00
Michael Lange aaf32cabf0 Filter out new records from the job list page
When a prefix is set and the run job button is clicked,
the new job causes an error because it has no name yet.
2020-07-10 15:29:52 -07:00
Michael Lange d5b54ad84c Reset the system and refetch namespaces with every token change 2020-07-10 15:18:36 -07:00
Buck Doyle d7c26b033e
Fix client allocations table heading order (#8409)
This closes #8408. Thanks to @gmichalec-pandora for letting us
know about this.
2020-07-10 07:27:20 -05:00
Buck Doyle 244157786a
Add explicit this to templates (#8388)
This is the result of running the no-implicit-this-codemod, some manual fixes,
and the addition of a linting rule to prevent future ambiguity.
2020-07-09 15:19:07 -05:00
Buck Doyle ea2adb3bf6
Update template linting and fix missed curly invocations (#8382)
This includes fixes for newer template lint rules that came along with
updating that dependency, which was necessary to be able to use
the no-curly-component-invocation rule. It also updates some curly
invocations that I missed in #8075.
2020-07-09 12:30:11 -05:00
Buck Doyle 40332963ef
Update to Ember 3.16/Data 3.12 (#8319)
This updates to Ember 3.16 but leaves Ember Data at 3.12 so we don’t need
to use the model fragments beta. It can be reviewed on a commit-by-commit
basis: blueprint updates, fixes for test failures, and the removal of
now-deprecated partials.

It’s not a true update to Octane as that would involve turning on template-only
components by default, which breaks various things. We can accomplish that
separately and then add the edition setting to package.json.
2020-07-09 11:37:00 -05:00
Michael Lange 970ccedd1f
Merge pull request #8314 from hashicorp/f-ui/scaling-ux
UI: Scaling UI UX Improvements
2020-07-01 09:21:08 -07:00
Michael Lange f786ee5eae Persist the log stream/mode setting to localStorage 2020-06-30 17:09:52 -07:00
Buck Doyle 3afd14e30d
Change back to released Ember Power Select (#8317)
Thanks to @cibernox’s isActive clarification in
cibernox/ember-power-select#1374, this replaces the use
of a hacked Power Select API with a deliberate blurring
of the trigger element, which is equivalent to setting
the element to inactive.
2020-06-30 15:23:02 -05:00
Buck Doyle f7e8ab4302
Fix layering so logo is clickable (#8320)
The CSS I added in #8249 to make the search be properly
centred also made the logo unclickable as it was hidden
behind the centred element! This makes the logo stay
above the search container.
2020-06-30 15:22:31 -05:00
Michael Lange 7ad214f34a StepperInput UX improvements
- Click label to focus input
- Focusing input selects value
- Entering an invalid value reverts selection
- Entering a fractional number floors the value
2020-06-30 11:54:11 -07:00
Michael Lange 8072996ee2 Label buttons that only have icons for markup 2020-06-30 11:54:11 -07:00
Michael Lange 5d491167de Reset font weight for tooltips 2020-06-30 11:54:11 -07:00
Michael Lange 70cc9cb5c8 Add tooltips to scaling controls 2020-06-30 11:54:11 -07:00
Buck Doyle 196f27aec4
Add multiple substring highlights for search (#8287)
The fuzzy search highlighting was ignoring everything after the first
substring that was matched, this now highlights all substrings.
2020-06-25 15:26:52 -05:00
Michael Lange a61bc49595
Merge pull request #8283 from hashicorp/b-ui/text-alignment-view-raw-file
UI: Fix text alignment for the "view raw file" button/link on the fs file viewer
2020-06-25 09:28:30 -07:00
Michael Lange ff015d2997
Merge pull request #8281 from hashicorp/b-ui/fix-log-streaming
UI: Revert AbortController polyfill to use native AbortController on logs page
2020-06-25 09:26:49 -07:00
Michael Lange 6c7d3f49d5
Merge pull request #8280 from hashicorp/f-ui/wide-monitor-logs
UI: Make monitor log output full-width
2020-06-25 09:22:54 -07:00
Michael Lange 683a4c81ac
Merge pull request #8279 from hashicorp/b-ui/remove-safari-special-case
UI: Fix monitor in Safari
2020-06-25 09:22:39 -07:00
Buck Doyle bf7ed82def
Improve global search UX (#8249)
This updates the look of the search control, adds a hint about the slash
shortcut, adds highlighting of fuzzy search results, and addresses a few
edge case UX failures. It moves to using a fork of Ember Power Select
to handle an edge case where pressing escape would put the control
in an undesirable active-but-not-open state.
2020-06-25 08:51:52 -05:00
Michael Lange 18bf810936 Remove line-height override that breaks text alignment for anchors that look like buttons 2020-06-24 21:31:30 -07:00
Michael Lange f6fa2c6088 Revert AbortController polyfill to use native AbortController 2020-06-24 20:46:30 -07:00
Michael Lange 22f9faeb84 Make monitor log output full-width 2020-06-24 20:37:12 -07:00
Michael Lange 3182adeefa Remove special-casing of Safari to force use of a PollLogger 2020-06-24 20:30:52 -07:00
Buck Doyle b891dc88ff
Remove non-classic use of this.set (#8242)
This will fix a linting error introduced in 068ad06.
2020-06-22 13:23:28 -05:00
Buck Doyle ca7c252a96
Add linting for classic decorator (#8182)
This completes an installation step I missed when making #8144 and
marks classes that are using the EmberObject APIs as classic.
2020-06-22 10:48:53 -05:00
Michael Lange a9bf04675f Add a key to the alloc table on the task group detail page
Adding keys tells Ember to rerender matching entries instead of
destroying and recreating.

Without this key, every time the allocation collection changes, every
allocation row gets destroyed and recreated.

This happens a lot, since each allocation needs to be reloaded which
dirties the collection.

Since allocation rows fetch stats on init, each of these many many
renders results in a stats request.

By using key and rerendering matching records, this all goes away. Since
the rows aren't being destroyed and recreated, the init stats request
isn't being made overnumerously.
2020-06-19 11:27:57 -07:00
Buck Doyle ee7141a59a
Add phase 1 of global search (#8175)
This introduces a DataCaches service so recently-updated collections don’t need
to be requeried within a minute, or based on the current route. It only searches
jobs and nodes. There are known bugs that will be addressed in upcoming PRs.
2020-06-19 13:05:28 -05:00
Michael Lange 02fd45f02b Acceptance tests for task group scaling 2020-06-18 23:23:03 -07:00
Michael Lange 1cadcf90b8 Watch the latest deployment relationship to disable the stepper appropriately 2020-06-18 23:23:03 -07:00
Michael Lange d3cce73747 Wire up the scale action on the task group page 2020-06-18 23:23:03 -07:00
Michael Lange 6259e3ae5d Integrate the stepper input with the task group page 2020-06-18 22:32:56 -07:00
Michael Lange ddd5a7e342 Test coverage for the StepperInput 2020-06-18 22:08:29 -07:00
Michael Lange ff3653ddf6 Style the StepperInput component 2020-06-18 22:08:28 -07:00
Michael Lange 28916c22cf Add count StepperInput to the task group page 2020-06-18 22:08:28 -07:00
Michael Lange ba91a4ffe5 Barebones StepperInput component 2020-06-18 22:08:28 -07:00
Michael Lange 2e04719fbc Slow the debounce time. 2020-06-18 22:08:28 -07:00
Michael Lange c664f57361 Disable scale buttons when a deployment is running or ACL forbids it 2020-06-18 22:08:28 -07:00
Michael Lange 3b7b5f9649 Add canScale ability for jobs 2020-06-18 22:08:28 -07:00
Michael Lange 136b4ec354 Wire up the +/- buttons in task group rows to the job scale action 2020-06-18 22:08:28 -07:00
Michael Lange aebc896ff6 New scale action for jobs (and a convenience task group method) 2020-06-18 22:08:27 -07:00
Michael Lange 57f4e9a62e Create new AbortController with each tick of the ec task loops
This was a disturbing discovery. Requests in watch loops would recycle
AbortControllers meaning once any request was aborted, all requests
forever after were skipped. I noticed it with deployments and job
summary on the job detail page.

I suspect this regression occurred when jQuery was removed. This needs
test coverage still to make sure it doesn't happen again.
2020-06-18 22:08:27 -07:00
Michael Lange 64cfa62c71 Make sure buttons in a button bar have a very visible focus state 2020-06-18 22:08:27 -07:00
Michael Lange c583c00088 Add the elements of the manual scaling actions to the task-group-row component 2020-06-18 22:08:27 -07:00
Michael Lange 1182e76383 Add the min/max and policy y/n of a task group to the details ribbon 2020-06-18 22:08:27 -07:00
Michael Lange 76c6a9d89f Prevent inline definition key/value pairs from breaking the key and value onto separate lines 2020-06-18 22:08:27 -07:00
Michael Lange 2739da75d6 Additional button-bar treatments for use in a table row 2020-06-18 22:08:27 -07:00
Michael Lange dfcfdf0293 Extend button-bar support to buttons 2020-06-18 22:08:27 -07:00
Michael Lange b4b00282dd When an icon is intended as text, it shouldn't have pointer events
This prevents the svg from being a target in click events.
2020-06-18 22:08:27 -07:00
Michael Lange f9819105c3 New xsmall button size 2020-06-18 22:08:27 -07:00
Michael Lange c5bf7fc7a7 LazyClick should also get interrupted by buttons 2020-06-18 22:08:26 -07:00
Michael Lange d8c2853d65 Model the scaling properties of a task group as a fragment 2020-06-18 22:08:26 -07:00
Michael Lange da76edcabd Code review feedback 2020-06-17 14:56:16 -07:00
Michael Lange 3c03ee5621 Guard the request animation frame with the existing requestFrame flag 2020-06-17 14:50:55 -07:00
Michael Lange 562a957666 Select all shortcut support for the streaming file component 2020-06-16 12:51:52 -07:00
Michael Lange c62db754a3 Server monitor page 2020-06-16 10:23:36 -07:00
Michael Lange f745ce4269 Test coverage for new features of the server detail page 2020-06-16 10:23:36 -07:00
Michael Lange 56e66e76e6 Redesign the server detail page to be inline with everything else 2020-06-16 10:23:36 -07:00
Michael Lange 3381c835b1 Add nested monitor route to servers/server 2020-06-16 10:23:36 -07:00
Michael Lange e6928cb01d Refactor the servers/server pages to match the subnav style of nested pages 2020-06-16 10:23:36 -07:00
Michael Lange bb499bba72 Show a helpful forbidden message when monitor access is not authorized 2020-06-16 10:23:36 -07:00
Michael Lange 129ccec82c New component version of the forbidden-message partial 2020-06-16 10:23:36 -07:00
Michael Lange 58df659fdb Ability for agent:read 2020-06-16 10:23:36 -07:00
Michael Lange cfee0f74a4 Test coverage for the AgentMonitor component 2020-06-16 10:23:36 -07:00
Michael Lange c515a59b44 Preserve the log when switching log levels on monitor 2020-06-16 10:23:36 -07:00
Michael Lange 6cb83c6297 Inline-block the buttons to remove weird text-flow spacing 2020-06-16 10:23:36 -07:00
Michael Lange cdc7db07c6 Refactor AgentMonitor levels handling to be simpler 2020-06-16 10:23:36 -07:00
Michael Lange 38af76e277 Reimplement synchronizeScrollPosition in a way that actually works 2020-06-16 10:23:36 -07:00
Michael Lange ca99ec774b Implement the log streaming portion of the AgentMonitor component 2020-06-16 10:23:36 -07:00
Michael Lange e0fbd88d26 Monitor component and query param interaction 2020-06-16 10:23:35 -07:00
Michael Lange 10e1371d34 Create new monitor route for clients 2020-06-16 10:23:35 -07:00
Buck Doyle 97c5a85ee6 Remove stray commented-out line 2020-06-16 08:36:39 -05:00
Michael Lange de82051d14 Data cannot be a field in the base class and a CP in the child classes 2020-06-15 11:37:40 -05:00
Buck Doyle c1cc51a057 Remove superfluous uses of Object.freeze
This is no longer needed!
https://guides.emberjs.com/release/upgrading/current-edition/native-classes/#toc_properties-and-fields
2020-06-15 10:15:11 -05:00
Buck Doyle a4be011141 Rename clashing property 2020-06-15 10:14:36 -05:00
Buck Doyle 3de475f8e4 Convert field to overridable computed property
StatsTimeSeries defines description as a computed property,
which isn’t possible when this is a class field.
2020-06-15 10:14:36 -05:00
Buck Doyle 782bc3b7c0 Rename clashing action 2020-06-15 10:14:36 -05:00
Buck Doyle a950ae661d Remove problem field
It appears this gets turned into a getter-only computed property
somehow, which causes problems when subclasses override it.
2020-06-15 10:14:35 -05:00
Buck Doyle cd11cd290c Add manually-converted classes
I don’t know why the codemod ignored these files 🧐
2020-06-15 10:14:26 -05:00
Buck Doyle 577e85b007 Fix query parameters structures
I’d think the codemod would handle this if it’s a requirement
but apparently not, is it a bug?
2020-06-15 09:52:31 -05:00
Michael Lange c4e29f8afa Change URL-generation for job-updating
The id-processing in the WatchableNamespaceIds adapter was
happening twice; this removes urlForUpdate record so it
only happens once. @DingoEatingFuzz figured it out! 🥳
2020-06-15 09:51:15 -05:00
Michael Lange 16ed5451d2 Change with-namespace-ids mixin to a base class
This is a merge of 5d9fce5.
2020-06-15 09:47:15 -05:00
Buck Doyle c56726abd1 Remove unnecessary fetch-setting
Originally this was failing because it only had a getter.
I tried replacing it with a computed property and that
succeeded, but since we have already stopped using
jQuery, we might as well remove it.
2020-06-15 09:41:57 -05:00
Buck Doyle 6efc64818b Add fixes for ESLint getter-return
…I GUESS
2020-06-10 16:18:56 -05:00
Buck Doyle 89136cbf6a Add massaged results of class codemod
Manual interventions:
• decorators on the same line for service and controller
  injections and most computed property macros
• preserving import order when possible, both per-line
  and intra-line
• moving new imports to the bottom
• removal of classic decorator for trivial cases
• conversion of init to constructor when appropriate
2020-06-10 16:18:42 -05:00
Buck Doyle 1cca7abcab
Add Ember ESLint plugin (#8134)
This is extracted from #8094, where I have run into some snags. Since
these ESLint fixes aren’t actually connected to the Ember 3.16 update
but involve changes to many files, we might as well address them
separately. Where possible I fixed the problems but in cases where
a fix seemed too involved, I added per-line or -file exceptions.
2020-06-09 16:03:28 -05:00
Buck Doyle 2998deac50
Convert to angle bracket invocation (#8075)
This is mostly a direct application of the ember-angle-brackets-codemod.
I manually restored newlines in multi-line component invocations, usually
preserving file line length except for now-non-positional link-to @route.

I needed to rename task to taskState in some cases to avoid Ember
Concurrency naming conflicts.
2020-06-01 14:03:56 -05:00
Buck Doyle 9c0f85d7b6
UI: add filesystem browsing for allocations (#7951)
This partially addresses #7799.

Task state filesystems are contained within a subdirectory of their
parent allocation, so almost everything that existed for browsing task
state filesystems was applicable to browsing allocations, just without
the task name prepended to the path. I aimed to push this differential
handling into as few contained places as possible.

The tests also have significant overlap, so this includes an extracted
behavior to run the same tests for allocations and task states.
2020-06-01 08:15:59 -05:00
Michael Lange c395b83f5a Remove test code 2020-05-26 14:54:59 -07:00
Michael Lange e436d01b01 Remove jquery from the window resize helper 2020-05-26 14:35:57 -07:00
Michael Lange 083e82e6b7 Remove jquery from the lazy-click helper 2020-05-26 14:31:15 -07:00