Rename Metrics to Monitors and move it second
All checks were successful
CI / naming (push) Successful in 4s
CI / frontend (push) Successful in 12s
CI / migrations-mysql (push) Successful in 43s
CI / backend (push) Successful in 4m17s

"Metrics" promised numbers. The tab holds tracked services, tracked processes
and network interfaces - things being WATCHED and their current state, only
one of which is a measurement. Monitors is what the panels actually are, and
it matches the word the agent's own config already uses for them.

Moved to second, ahead of Software. What is being watched on this box is the
question asked right after "what is it", and well before its application
inventory - which is reference data somebody goes looking for deliberately.

Tab order is now Details, Monitors, Software, Activity.

Contract 0.29.0 keeps its number. It is unreleased, so the group vocabulary it
introduces is still being settled and nothing can yet depend on the old name.
Both the server and the client fall back to 'details' for a group they do not
recognise, so a site that deploys these halves out of step gets a misplaced
card rather than a missing one.

Scope: product
This commit is contained in:
cproudlock
2026-08-31 15:21:46 -04:00
parent c71183375f
commit 2feb569686
7 changed files with 30 additions and 25 deletions

View File

@@ -25,7 +25,7 @@ pluginui_bp = Blueprint('pluginui', __name__)
#
# 'details' is first and is the fallback: it holds what an asset IS, which is
# what a panel declaring nothing almost always contributes.
ASSET_PANEL_GROUPS = ('details', 'software', 'metrics', 'activity')
ASSET_PANEL_GROUPS = ('details', 'monitors', 'software', 'activity')
def _collect(hookname):

View File

@@ -371,7 +371,7 @@ class BasePlugin(ABC):
# keys, rendered generically - see warranty)
'position': int, # order among panels
'group': str, # OPTIONAL. Which tab on the detail page:
# 'details' | 'software' | 'metrics'
# 'details' | 'monitors' | 'software'
# | 'activity'. Omitted means 'details'.
}
@@ -383,12 +383,13 @@ class BasePlugin(ABC):
existing plugin working untouched: an unknown or absent group resolves
to 'details', which is the tab that holds what an asset IS. Reach for
another group only when the panel is the thing that tab exists for -
an inventory listing, live telemetry, or a history feed.
what is being watched on the box, an inventory listing, or a history
feed.
There is deliberately no group for controls. A panel that acts on the
machine belongs beside the state it acts on: tracked services read as
telemetry first and a Start/Stop second, so they live in 'metrics' with
the rest of what the endpoint reports. Splitting the buttons away from
state first and a Start/Stop second, so they live in 'monitors' with
the rest of what is being watched. Splitting the buttons away from
the state they change made a tab that held one card and answered no
question on its own.