🔋 Battery Optimization for Idle Connections
This release significantly reduces battery drain when connected to a server but not actively playing audio.
What Changed
Before: Connecting to a server immediately acquired CPU and WiFi wake locks, keeping your device fully awake even when no music was playing.
After: Wake locks are now only acquired when audio actually starts streaming. When you're connected but idle (paused or stopped), your device can sleep normally between WebSocket keepalive pings.
Details
- Foreground service starts on connect (keeps the app alive)
- CPU/WiFi wake locks only activate during audio playback
- Notification now shows context: "Connected to [server]" vs "Streaming audio..."
- No change to audio quality or sync performance