From 4459b648e9fb53c34abbf52a00e63ad384fb9ee2 Mon Sep 17 00:00:00 2001 From: Vladimir Lavor Date: Thu, 18 Feb 2021 16:05:30 +0100 Subject: Added asynchronous connection for stats socket The stats socket now allows an option to connect asynchronously in the same manner as the api socket connection. New method AsyncConnectStats returns a channel where notificaitons of type ConnectionEvent will be sent. Fixed the stats reconnect procedure which sometimes failed to re-eneable the connection. Change-Id: I0bdb19f0d57e3a1ea259b8b1ba0a5e5fa49a09db Signed-off-by: Vladimir Lavor --- adapter/stats_api.go | 1 + 1 file changed, 1 insertion(+) (limited to 'adapter/stats_api.go') diff --git a/adapter/stats_api.go b/adapter/stats_api.go index 90dbeb3..15c3789 100644 --- a/adapter/stats_api.go +++ b/adapter/stats_api.go @@ -27,6 +27,7 @@ const ( var ( ErrStatsDataBusy = errors.New("stats data busy") ErrStatsDirStale = errors.New("stats dir stale") + ErrStatsDisconnected = errors.New("stats disconnected") ErrStatsAccessFailed = errors.New("stats access failed") ) -- cgit 1.2.3-korg