cleanup(#1014): remove manager pinning from frontend — no special treatment for ruth
This commit is contained in:
parent
7a035911ef
commit
79265e04f8
2 changed files with 0 additions and 18 deletions
|
|
@ -169,13 +169,6 @@ window.marked = marked;
|
|||
if (containersState.delete(ev.name)) renderContainersFromState();
|
||||
}
|
||||
|
||||
// Logical name of the manager agent. Populated from `s.manager_name`
|
||||
// on snapshot load so chip lists don't hardcode the manager name.
|
||||
let managerNameState = '';
|
||||
function syncManagerNameFromSnapshot(s) {
|
||||
if (s.manager_name) managerNameState = s.manager_name;
|
||||
}
|
||||
|
||||
// Derived tombstones + meta_inputs. Both are emitted as full
|
||||
// snapshots (not diffs) — the lists are tiny and recomputing
|
||||
// avoids ordering races between a same-tick destroy + purge.
|
||||
|
|
@ -2593,12 +2586,8 @@ window.marked = marked;
|
|||
// one place. Returns the wrapping `<label class="schedule-field">`
|
||||
// ready to append to the form.
|
||||
function buildTargetChips({ idPrefix, fieldName, checked, extraNames = [] }) {
|
||||
// Surface manager first so it always appears before non-manager agents.
|
||||
const managerName = containersState.has(managerNameState) ? managerNameState : null;
|
||||
const candidates = ['operator'];
|
||||
if (managerName) candidates.push(managerName);
|
||||
const containerNames = Array.from(containersState.values())
|
||||
.filter((c) => c.name !== managerNameState)
|
||||
.map((c) => c.name)
|
||||
.filter((n) => n !== 'operator')
|
||||
.sort();
|
||||
|
|
@ -2903,9 +2892,7 @@ window.marked = marked;
|
|||
const out = [];
|
||||
const push = (n) => { if (!seen.has(n)) { seen.add(n); out.push(n); } };
|
||||
push('operator');
|
||||
if (containersState.has(managerNameState)) push(managerNameState);
|
||||
const containerNames = Array.from(containersState.values())
|
||||
.filter((c) => c.name !== managerNameState)
|
||||
.map((c) => c.name)
|
||||
.filter((n) => n !== 'operator')
|
||||
.sort();
|
||||
|
|
@ -3474,7 +3461,6 @@ window.marked = marked;
|
|||
// `transientsState` + `containersState`, not from `s.*`).
|
||||
syncTransientsFromSnapshot(s);
|
||||
syncContainersFromSnapshot(s);
|
||||
syncManagerNameFromSnapshot(s);
|
||||
syncTombstonesFromSnapshot(s);
|
||||
syncMetaInputsFromSnapshot(s);
|
||||
syncRebuildQueueFromSnapshot(s);
|
||||
|
|
|
|||
|
|
@ -173,9 +173,6 @@ struct StateSnapshot {
|
|||
/// "apply everything you've buffered".
|
||||
seq: u64,
|
||||
hostname: String,
|
||||
/// The logical name of the manager agent. Lets the dashboard identify
|
||||
/// the manager container without a separate `is_manager` bool on each row.
|
||||
manager_name: String,
|
||||
manager_port: u16,
|
||||
any_stale: bool,
|
||||
containers: Vec<ContainerView>,
|
||||
|
|
@ -449,7 +446,6 @@ async fn api_state(headers: HeaderMap, State(state): State<AppState>) -> axum::J
|
|||
axum::Json(StateSnapshot {
|
||||
seq,
|
||||
hostname,
|
||||
manager_name: MANAGER_NAME.to_owned(),
|
||||
manager_port: lifecycle::agent_web_port(MANAGER_NAME),
|
||||
any_stale,
|
||||
containers,
|
||||
|
|
|
|||
Loading…
Reference in a new issue