Jobs were being marked incorectly as having paused allocations
when termimal allocations were marked with the paused boolean. The
UI should only mark a job as including paused allocations when
these paused allocations are in the correct client state, which is
pending.
---------
Co-authored-by: Phil Renaud <phil@riotindustries.com>
* Custom watchQuery equivalent on the storage index
* Tests for live updates to the storage page
* Deconditionalizing the pagination on storage, and fixing a bug where I was looking at filtered but not paginated DHV
* Test for pagination with live-updates
* First batch of x-icon to hds::icons
* Bunch more icons and a note for jobrow
* Fixes for tests that depended on specific action names
* Icon-bumped-down specified to solo-icons in table cells
* Class-basing the icon bump and deferring icon svg load in env
* Exec window sidebar icons were looking a little off
* An option to select, and column etc. to view, sentinel policy scope
* Flake potential: Seed(1) had a couple jobs with the same ModifyIndex
* More de-flaking
* DHV UI init
* /csi routes to /storage routes and a routeRedirector util (#25163)
* /csi routes to /storage routes and a routeRedirector util
* Tests and routes move csi/ to storage/
* Changelog added
* [ui] Storage UI overhaul + Dynamic Host Volumes UI (#25226)
* Storage index page and DHV model properties
* Naive version of a storage overview page
* Experimental fetch of alloc data dirs
* Fetch ephemeral disks and static host volumes as an ember concurrency task and nice table stylings
* Playing nice with section header labels to make eslint happy even though wcag was already cool with it
* inlined the storage type explainers and reordered things, plus tooltips and keynav
* Bones of a dynamic host volume individual page
* Woooo dynamic host volume model, adapter, and serializer with embedded alloc relationships
* Couple test fixes
* async:false relationship for dhv.hasMany('alloc') to prevent a ton of xhr requests
* DHV request type at index routemodel and better serialization
* Pagination and searching and query params oh my
* Test retrofits for csi volumes
* Really fantastic flake gets fixed
* DHV detail page acceptance test and a bunch of mirage hooks
* Seed so that the actions test has a guaranteed task
* removed ephemeral disk and static host volume manual scanning
* CapacityBytes and capabilities table added to DHV detail page
* Debugging actions flyout test
* was becoming clear that faker.seed editing was causing havoc elsewhere so might as well not boil the ocean and just tell this test to do what I want it to
* Post-create job gets taskCount instead of count
* CSI volumes now get /csi route prefix at detail level
* lazyclick method for unused keynav removed
* keyboard nav and table-watcher for DHV added
* Addressed PR comments, changed up capabilities table and id references, etc.
* Capabilities table for DHV and ID in details header
* Testfixes for pluginID and capabilities table on DHV page
* Changes the behaviour of system/batch/sysbatch jobs not to look for a latest stable version, as their versions never go to stable
* Dont show job stability on versions page for system/sysbatch/batch jobs
* Tests that depend on jobs to revert specify that they are Service jobs
* Batch jobs added to detail-restart test loop
* Right, they're not stable, they're just versions
* Add factory hooks for jobs to have previously stable versions and stopped status
* Since #24973 node-read isn't presupposed and so should regex match only on the common url parts
* Job detail tests for title buttons are now bimodal and default to having previously-stable version in history
* prettier plz
* Breaking a thing on purpose to see if my other broken thing is broken
* continue-on-error set to false to get things red when appropriate
* OK what if continue-on-error=true but we do a separate failure reporting after the fact
* fail-fast are you the magic incantation that I need?
* Re-fix my test now that fast-fail is off
* Fix to server-leader by adding a region first, and always()-append to uploading partition results
* Express failure step lists failing tests so you don't have to click back into ember-exam step
* temporary snapshot and logging for flakey test in service job detail
* Bunch of region and tasklogs test fixups
* using allocStatusDistribution to ensure service job always has a non-queued alloc
* Multi-condition start/revert/edit buttons when a job isn't running
* mirage-mocked revertable jobs and acceptance tests
* Remove version-watching from job index route
* Experimenting with a generic meta job-part component
* Taskstate.task gets me every time
* continue-on-error false test
* continue-on-error back in, but explicit success check after exam
* Testfixes for new meta structure on tasks and groups
* Clean up test and dev code
* Fixes an issue where system jobs' status were set to Scaled Down when their allocs get garbage collected
* Added to aggregateAllocStatus acceptance test and changelog
* Edit from Version functionality
* Reworked as Clone and Revert
* Change name warning for cloning as new job, version 0 checking, and erroring on sourceless clone
* If you try to plan a new version of a job with a different name of the one you're editing, suggest they might want to run a new one instead
* A few code comments and log cleanup
* Scaffolding new acceptance tests
* A whack of fun new tests
* Unit test for version number url passing on fetchRawDef
* Bit of cleanup
* fetchRawDefinition gets version support at adapter layer
* Handle spec-not-available-but-definition-is for clone-as-new-job
* Updates the Task Lifecycle Status chart to show which pre/poststart task may have failed
* Default colour to prevent HDS error
* De-duplicated data-test attr and added is-active and is-finished test classes
* Failed and Pending state tests
* Upon sign-in post-expiry/403, redirect to original route
* Tests for token expiry re-routing
* Had made one of the new test tokens a management token, which conflicted with another test but was not necessary
* ui: show region in header gutter when only one region exists
This PR adds a plain text label of the region to the header when there is
only one region present. Before, nothing was showin in this case, and a
dropdown was shown on federated clusters.
The use case here is for operators of multiple non-federated Nomad clusters,
when all the UI's involved otherwise look identical.
* [ui] Signing in with a token explicitly sets the region dropdown activeRegion (#24347)
* Signing in with a token explicitly sets the region dropdown activeREgion
* Test and Select a Region default text
* Account for 403 on mocked agent members req
* Dont show the region if it isnt set in agent config
* Small padding css change
* unit test condition moved to stubbable acceptance test
---------
Co-authored-by: Phil Renaud <phil.renaud@hashicorp.com>
* Modify variable access permissions for UI users with write in only certain namespaces
* Addressing some PR comments
* Variables index namespaces on * and ability checks are now namespaced
* Mistook Delete for Destroy, and update unit tests for mult-return allPaths
* TaggedVersion information in structs, rather than job_endpoint (#23841)
* TaggedVersion information in structs, rather than job_endpoint
* Test for taggedVersion description length
* Some API plumbing
* Tag and Untag job versions (#23863)
* Tag and Untag at API level on down, but am I unblocking the wrong thing?
* Code and comment cleanup
* Unset methods generally now I stare long into the namespace abyss
* Namespace passes through with QueryOptions removed from a write requesting struct
* Comment and PR review cleanup
* Version back to VersionStr
* Generally consolidate unset logic into apply for version tagging
* Addressed some PR comments
* Auth check and RPC forwarding
* uint64 instead of pointer for job version after api layer and renamed copy
* job tag command split into apply and unset
* latest-version convenience handling moved to CLI command level
* CLI tests for tagging/untagging
* UI parts removed
* Add to job table when unsetting job tag on latest version
* Vestigial no more
* Compare versions by name and version number with the nomad history command (#23889)
* First pass at passing a tagname and/or diff version to plan/versions requests
* versions API now takes compare_to flags
* Job history command output can have tag names and descriptions
* compare_to to diff-tag and diff-version, plus adding flags to history command
* 0th version now shows a diff if a specific diff target is requested
* Addressing some PR comments
* Simplify the diff-appending part of jobVersions and hide None-type diffs from CLI
* Remove the diff-tag and diff-version parts of nomad job plan, with an eye toward making them a new top-level CLI command soon
* Version diff tests
* re-implement JobVersionByTagName
* Test mods and simplification
* Documentation for nomad job history additions
* Prevent pruning and reaping of TaggedVersion jobs (#23983)
tagged versions should not count against JobTrackedVersions
i.e. new job versions being inserted should not evict tagged versions
and GC should not delete a job if any of its versions are tagged
Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
---------
Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
* [ui] Version Tags on the job versions page (#24013)
* Timeline styles and their buttons modernized, and tags added
* styled but not yet functional version blocks
* Rough pass at edit/unedit UX
* Styles consolidated
* better UX around version tag crud, plus adapter and serializers
* Mirage and acceptance tests
* Modify percy to not show time-based things
---------
Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
* Job revert command and API endpoint can take a string version tag name (#24059)
* Job revert command and API endpoint can take a string version tag name
* RevertOpts as a signature-modified alternative to Revert()
* job revert CLI test
* Version pointers in endpoint tests
* Dont copy over the tag when a job is reverted to a version with a tag
* Convert tag name to version number at CLI level
* Client method for version lookup by tag
* No longer double-declaring client
* [ui] Add tag filter to the job versions page (#24064)
* Rough pass at the UI for version diff dropdown
* Cleanup and diff fetching via adapter method
* TaggedVersion now VersionTag (#24066)
---------
Co-authored-by: Daniel Bennett <dbennett@hashicorp.com>
* First pass at global token creation and regional awareness at token fetch time
* Reset and refetch token when you switch region but stay in place
* Ugly and functional global token save
* Tests and log cleanup
* Generalized namespace handling, generalized facet searching, node pools facet search
* Testfixes for namespace facet on jobs list
* Filter or not, need to watch for * namespaces
* Stopped status passed through to the statuses endpoint and observed on job model and steady-state panel
* Status passed to statuses endpoint and test for FE model statuses
* Rework of attributes using pathTree
* Pack meta reintroduced and made local
* attributes table test updated for new pathTree syntax
* removed flat import and extended the PathTree type signature to include prefix
* Slightly darken the is-faded text in tables
* Adds a badge on the jobs index page if any task within any allocation of a running job is currently paused
* Snapshot and acceptance tests for paused states
* Cleared yarn cache
* Remove MirageScenario from the test dependency chain
* Logging before toString
* Cardinal sin of time-based test execution
* Maybe weve been lucky for years and the clientStatus has always been running for this test by happenstance
* Back away from the time-based and toward the settled() approach
* Maintains rawSearchText separate from searchText
* Filter expression suggestions
* Now super-stops duelling queries on else-type error
* Filter suggestions and corrections
* Errorlink is now template standard and testfixes
* Mirage simulates healthy errors
* Test for bad filter expressions and snapshots
* Gallery allows picking stuff
* Small fixes
* added sentinel templates
* Can set enforcement level on policies
* Working on the interactive sentinel dev mode
* Very rough development flow on FE
* Changed position in gutter menu
* More sentinel stuff
* PR cleanup: removed testmode, removed unneeded mixins and deps
* Heliosification
* Index-level sentinel policy deletion and page title fixes
* Makes the Canaries sentinel policy real and then comments out the unfinished ones
* rename Access Control to Administration in prep for moving Sentinel Policies and Node Pool admin there
* Sentinel policies moved within the Administration section
* Mirage fixture for sentinel policy endpoints
* Description length check and 500 prevention
* Sync review PR feedback addressed, implied butons on radio cards
* Cull un-used sentinel policies
---------
Co-authored-by: Mike Nomitch <mail@mikenomitch.com>
* Hacky but shows links and desc
* markdown
* Small pre-test cleanup
* Test for UI description and link rendering
* JSON jobspec docs and variable example job get UI block
* Jobspec documentation for UI block
* Description and links moved into the Title component and made into Helios components
* Marked version upgrade
* Allow links without a description and max description to 1000 chars
* Node 18 for setup-js
* markdown sanitization
* Ui to UI and docs change
* Canonicalize, copy and diff for job.ui
* UI block added to testJob for structs testing
* diff test
* Remove redundant reset
* For readability, changing the receiving pointer of copied job variables
* TestUI endpiont conversion tests
* -require +must
* Nil check on Links
* JobUIConfig.Links as pointer
---------
Co-authored-by: Tim Gross <tgross@hashicorp.com>
* Hook and latch on the initial index
* Serialization and restart of controller and table
* de-log
* allocBlocks reimplemented at job model level
* totalAllocs doesnt mean on jobmodel what it did in steady.js
* Hamburgers to sausages
* Hacky way to bring new jobs back around and parent job handling in list view
* Getting closer to hook/latch
* Latch from update on hook from initialize, but fickle
* Note on multiple-watch problem
* Sensible monday morning comment removal
* use of abortController to handle transition and reset events
* Next token will now update when there's an on-page shift
* Very rough anti-jostle technique
* Demoable, now to move things out of route and into controller
* Into the controller, generally
* Smarter cancellations
* Reset abortController on index models run, and system/sysbatch jobs now have an improved groupCountSum computed property
* Prev Page reverse querying
* n+1th jobs existing will trigger nextToken/pagination display
* Start of a GET/POST statuses return
* Namespace fix
* Unblock tests
* Realizing to my small horror that this skipURLModification flag may be too heavy handed
* Lintfix
* Default liveupdates localStorage setting to true
* Pagination and index rethink
* Big uncoupling of watchable and url-append stuff
* Testfixes for region, search, and keyboard
* Job row class for test purposes
* Allocations in test now contain events
* Starting on the jobs list tests in earnest
* Forbidden state de-bubbling cleanup
* Job list page size fixes
* Facet/Search/Filter jobs list tests skipped
* Maybe it's the automatic mirage logging
* Unbreak task unit test
* Pre-sort sort
* styling for jobs list pagination and general PR cleanup
* moving from Job.ActiveDeploymentID to Job.LatestDeployment.ID
* modifyIndex-based pagination (#20350)
* modifyIndex-based pagination
* modifyIndex gets its own column and pagination compacted with icons
* A generic withPagination handler for mirage
* Some live-PR changes
* Pagination and button disabled tests
* Job update handling tests for jobs index
* assertion timeout in case of long setTimeouts
* assert.timeouts down to 500ms
* de-to-do
* Clarifying comment and test descriptions
* Bugfix: resizing your browser on the new jobs index page would make the viz grow forever (#20458)
* [ui] Searching and filtering options (#20459)
* Beginnings of a search box for filter expressions
* jobSearchBox integration test
* jobs list updateFilter initial test
* Basic jobs list filtering tests
* First attempt at side-by-side facets and search with a computed filter
* Weirdly close to an iterative approach but checked isnt tracked properly
* Big rework to make filter composition and decomposition work nicely with the url
* Namespace facet dropdown added
* NodePool facet dropdown added
* hdsFacet for future testing and basic namespace filtering test
* Namespace filter existence test
* Status filtering
* Node pool/dynamic facet test
* Test patchups
* Attempt at optimize test fix
* Allocation re-load on optimize page explainer
* The Big Un-Skip
* Post-PR-review cleanup
* todo-squashing
* [ui] Handle parent/child jobs with the paginated Jobs Index route (#20493)
* First pass at a non-watchQuery version
* Parameterized jobs get child fetching and jobs index status style for parent jobs
* Completed allocs vs Running allocs in a child-job context, and fix an issue where moving from parent to parent would not reset index
* Testfix and better handling empty-child-statuses-list
* Parent/child test case
* Dont show empty allocation-status bars for parent jobs with no children
* Splits Settings into 2 sections, sign-in/profile and user settings (#20535)
* Changelog
* Fix a UI bug where promotion would be asked with no new canaries
* Because we now make sure of your allocations, our test cases should more accurately reflect a state of a promotable workflow
* Warning and better error handling for invalid-named variables and job templates
* Warning and better error handling for invalid-named variables and job templates
* Tests for variable pathname warnings
* Only show the bad-name warning if the variable is being created and path is editable
* HashiCorp Design System upgraded to 3.6.0
* Fresh yarn
* Responses out of range are brought back within
* General pass at a11y fixes with updated components and node
* Further tooltip updates
* 3 more partitions worth of toggle and tooltip updates
* scale-events-accordion and topo-viz node fixes
Adds Namespace UI to Access Control - Also adds two step buttons to other Access Control pages
---------
Co-authored-by: Phil Renaud <phil@riotindustries.com>
* Sign-in page now hides token secret by default (toggleable) and updates components to Helios
* General helios-ification
* All the notifications get dismissal buttons
* token-details grid for spacing
* node eligibilty taken into consideration when clients list filtered to 'ready'
* A working draft of complex positive querying
* tags and filter badge
* CompositeStatus -> Status
* Buttons within a Helios SegmentedGroup
* Convert the other dropdowns to helios on clients index
* A bunch of client index test fixes
* Remaining clients list acceptance tests for State facet modified