From c6c0a73cdaeb5d81fb0982260d1dc1fdd384367f Mon Sep 17 00:00:00 2001 From: Cal Corum Date: Sat, 28 Feb 2026 07:29:35 -0600 Subject: [PATCH] store: Fix: n8n Server Health Monitor Discord escalation notifications lacked issue details --- ...r-discord-escalation-notificatio-aab3d0.md | 44 +++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 graph/fixes/fix-n8n-server-health-monitor-discord-escalation-notificatio-aab3d0.md diff --git a/graph/fixes/fix-n8n-server-health-monitor-discord-escalation-notificatio-aab3d0.md b/graph/fixes/fix-n8n-server-health-monitor-discord-escalation-notificatio-aab3d0.md new file mode 100644 index 00000000000..4c6373f9ebe --- /dev/null +++ b/graph/fixes/fix-n8n-server-health-monitor-discord-escalation-notificatio-aab3d0.md @@ -0,0 +1,44 @@ +--- +id: aab3d007-0cdf-4a4f-9b55-096ea4bdc168 +type: fix +title: "Fix: n8n Server Health Monitor Discord escalation notifications lacked issue details" +tags: [n8n, monitoring, discord, health-check, homelab, claude-runner-monitoring, fix] +importance: 0.65 +confidence: 0.8 +created: "2026-02-28T13:29:35.319456+00:00" +updated: "2026-02-28T13:29:35.319456+00:00" +--- + +# Fix: n8n Server Health Monitor Discord Escalation Notifications Lacked Issue Details + +## Problem + +The n8n "Server Health Monitor - Master Loop" (workflow ID: `p7XmW23SgCs3hEkY`) was sending Discord escalation notifications that only showed raw issue counts — e.g., "escalation_needed (2 issues)" — with no detail about which servers had problems or what was wrong. + +## Root Cause + +The Aggregate Results node (`nodeId: code-aggregate`) in the master workflow was not formatting the issue data into human-readable output before sending to the Discord embed. It surfaced raw aggregate counts only. + +## Two Notification Paths + +The monitoring system has two distinct notification paths: +- **Exit code 1 (auto-remediated):** Goes through `notifier.py` on CT 302 directly — this path already had good detail. +- **Exit code 2 (escalation needed):** Goes through the n8n master workflow Discord embed — this was the broken path. + +Only the master workflow needed fixing. + +## Fix + +Updated the `code-aggregate` jsCode node in the master workflow via `n8n-mcp` partial update. Changes: + +1. **Skip healthy servers** — only unhealthy servers appear in the body; a footer shows "7/9 servers healthy". +2. **List issues under server name** — each issue message is shown with the redundant " on {server_key}" suffix stripped. +3. **Show remediated items** — formatted as "Restarted {container} (success)". +4. **Include Claude remediation snippet** — when escalation was invoked, shows first 150 chars of Claude's output. + +## Method + +Updated via `mcp__n8n-mcp__n8n_update_partial_workflow` targeting `nodeId: code-aggregate` within workflow `p7XmW23SgCs3hEkY`. + +## Tags +n8n, monitoring, discord, health-check, homelab, claude-runner-monitoring