From 3fd19f140678b89147caa221e560a0853fc2b373 Mon Sep 17 00:00:00 2001 From: Deivid Soto Date: Thu, 9 Apr 2026 00:01:24 +0200 Subject: [PATCH] feat(wake): long-poll wake listener for instant CLI sync MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit CLI now holds a GET /api/internal/agent/wake connection open. When the server calls triggerWake(userId) — on stream request, download queue, pause, cancel, resume, scan, etc. — the CLI receives the signal immediately and fires a sync cycle in <100ms instead of waiting up to 10s for the next scheduled interval. - Add WaitForWake(ctx) to Client using a no-timeout HTTP client - Add runWakeListener goroutine to SyncClient (auto-reconnects) - Start wake listener from SyncClient.Run() Closes: sub-second stream latency from the web UI --- CHANGELOG.md | 6 ++++++ internal/cmd/version.go | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b59506a..1b08ce6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.6.1] - 2026-04-08 + +### Added + +- **wake**: long-poll `/api/internal/agent/wake` endpoint — CLI holds connection open and syncs immediately (<100ms) when server sends a wake signal instead of waiting for the next poll interval + ## [0.6.0] - 2026-04-08 diff --git a/internal/cmd/version.go b/internal/cmd/version.go index 4ca0579..05e8fca 100644 --- a/internal/cmd/version.go +++ b/internal/cmd/version.go @@ -1,4 +1,4 @@ package cmd // Version is the CLI version. Overridden by goreleaser ldflags at release time. -var Version = "0.6.0" +var Version = "0.6.1"