diff --git a/internal/monitoring/monitor.go b/internal/monitoring/monitor.go index 22accaa..0b1dee1 100644 --- a/internal/monitoring/monitor.go +++ b/internal/monitoring/monitor.go @@ -7264,7 +7264,7 @@ func buildGuestLookups(snapshot models.StateSnapshot, metadataStore *config.Gues key := alerts.BuildGuestKey(vm.Instance, vm.Node, vm.VMID) byKey[key] = info - vmidKey := fmt.Sprintf("%d", vm.VMID) + vmidKey := strconv.Itoa(vm.VMID) byVMID[vmidKey] = append(byVMID[vmidKey], info) // Persist last-known name and type for this guest @@ -7286,7 +7286,7 @@ func buildGuestLookups(snapshot models.StateSnapshot, metadataStore *config.Gues byKey[key] = info } - vmidKey := fmt.Sprintf("%d", ct.VMID) + vmidKey := strconv.Itoa(ct.VMID) byVMID[vmidKey] = append(byVMID[vmidKey], info) // Persist last-known name and type for this guest @@ -7320,7 +7320,7 @@ func enrichWithPersistedMetadata(metadataStore *config.GuestMetadataStore, byVMI continue // Invalid key format } - vmidKey := fmt.Sprintf("%d", vmid) + vmidKey := strconv.Itoa(vmid) // Check if we already have a live entry for this exact guest hasLiveEntry := false diff --git a/internal/monitoring/temperature.go b/internal/monitoring/temperature.go index 7a2242a..e93da6b 100644 --- a/internal/monitoring/temperature.go +++ b/internal/monitoring/temperature.go @@ -259,7 +259,7 @@ func (tc *TemperatureCollector) runSSHCommand(ctx context.Context, host, command "-o", "BatchMode=yes", "-o", "LogLevel=ERROR", // Suppress host key warnings that break JSON parsing "-o", "ConnectTimeout=5", - "-p", fmt.Sprintf("%d", tc.sshPort), // Use configured SSH port + "-p", strconv.Itoa(tc.sshPort), // Use configured SSH port } if tc.hostKeys != nil && tc.hostKeys.Path() != "" {