fix: ship the rebuilt binary with heartbeat_ack fix + test (v1.3.1)
The prebuilt theta-agent-linux-amd64 was built before the v1.3.0 heartbeat_ack fix, so the installed agent still logged 'Unknown command type: heartbeat_ack'. Rebuild it with the fix; add a test asserting heartbeat_ack is silently ignored (no response, no command, no log).
This commit is contained in:
+5
-1
@@ -139,7 +139,11 @@ func connectWebSocket(cm *ConfigManager, exec Executor) {
|
||||
|
||||
func handleCommand(cm *ConfigManager, msg WSMessage, c MessageWriter, exec Executor) {
|
||||
cfg := cm.Get()
|
||||
log.Printf("Received command: %s", msg.Type)
|
||||
// Don't log the server's fire-and-forget heartbeat ack — it arrives every
|
||||
// 60s and is not a command to act on; logging it is pure per-minute noise.
|
||||
if msg.Type != "heartbeat_ack" {
|
||||
log.Printf("Received command: %s", msg.Type)
|
||||
}
|
||||
|
||||
sendResponse := func(status string, message string) {
|
||||
resp, _ := json.Marshal(map[string]string{"status": status, "message": message})
|
||||
|
||||
Reference in New Issue
Block a user