# rpc 错误：代码 = 不可用，描述 = grpc：服务器已停止

- **ID:** `go/grpc-server-shutdown`
- **领域:** go
- **类别:** network_error
- **验证级别:** ai_generated
- **修复率:** 80%

## 根因

客户端尝试与已优雅停止或正在关闭的 gRPC 服务器通信。

## 版本兼容性

| 版本 | 状态 | 引入 | 弃用 |
|------|------|------|------|
| 1.60.0 | active | — | — |

## 解决方案

1. **** (85% 成功率)
   ```
   Implement client-side health checks to detect server availability and reconnect when it comes back.
   ```
2. **** (90% 成功率)
   ```
   Use a connection pool that can re-establish connections after server restart.
   ```

## 无效尝试

- **** —  (80% 失败率)
- **** —  (60% 失败率)
