Files
zhub-go-client/LICENSE
绝尘 dcfb735a2d 初始化 zhub Go 客户端项目
新增 zhub 客户端完整实现,包括配置加载、TCP通信、消息发布/订阅、
RPC 调用、分布式锁等功能。支持从项目配置文件、环境变量等多种方式初始化客户端,并提供便捷的全局调用接口。- 添加 `.gitignore` 忽略 IDE 和临时文件
- 实现 `api.go` 提供全局便捷方法封装客户端调用
- 实现 `client.go` 核心客户端逻辑,包含网络通信、消息处理等
- 添加 `client_test.go` 单元测试和集成测试示例
- 实现 `config.go` 支持灵活的配置加载机制
- 添加示例配置文件 `example-config.yml`
- 初始化 Go 模块依赖 `go.mod` 和 `go.sum`
- 实现 `init.go` 提供多种初始化方式
- 添加 MIT 许可证文件 `LICENSE`
- 新增使用示例 `example/main.go` 展示基本功能调用
- 实现 `manager.go` 管理默认客户端实例及初始化逻辑
2025-09-24 00:54:26 +08:00

22 lines
1.0 KiB
Plaintext

MIT License
Copyright (c) 2024 zhub-go-client
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.