Skip to content

armgit / dbx

Public Imported from GitHub
0

25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。

fix(etcd): bound member status probe timeout

Taraa9ec07e65107
diff --git a/agents/drivers/etcd-go/main.go b/agents/drivers/etcd-go/main.go
index 1e4a5f4494..cf5dc8fffb 100644
--- a/agents/drivers/etcd-go/main.go
+++ b/agents/drivers/etcd-go/main.go
@@ -21,6 +21,7 @@ const (
legacyAgentSessionID = "__legacy__"
maxAgentSessions = 256
rpcTimeoutSeconds = 30
+ statusProbeSeconds = 10
readAccessCacheTTL = 15 * time.Second
)
diff --git a/agents/drivers/etcd-go/status.go b/agents/drivers/etcd-go/status.go
index 0634f68286..207d131d69 100644
--- a/agents/drivers/etcd-go/status.go
+++ b/agents/drivers/etcd-go/status.go
@@ -72,7 +72,7 @@ func (s *etcdSession) status(params map[string]json.RawMessage) (any, error) {
statusRequests[index] = channel
go func(endpoint string, channel chan *statusResult) {
started := time.Now()
- ctx, cancel := context.WithTimeout(context.Background(), rpcTimeoutSeconds*time.Second)
+ ctx, cancel := context.WithTimeout(context.Background(), statusProbeSeconds*time.Second)
response, err := client.Maintenance.Status(ctx, endpoint)
cancel()
channel <- &statusResult{response: response, err: err, started: started}