https://github.com/fengjx/luchen
基于go-kit二次封装的微服务框架。开箱即用,封装了工程实践中常用的组件和工具
https://github.com/fengjx/luchen
go gokit grpc-server http-server microservice
Last synced: 2 months ago
JSON representation
基于go-kit二次封装的微服务框架。开箱即用,封装了工程实践中常用的组件和工具
- Host: GitHub
- URL: https://github.com/fengjx/luchen
- Owner: fengjx
- License: mit
- Created: 2023-12-11T02:53:06.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2025-08-02T12:53:05.000Z (8 months ago)
- Last Synced: 2025-08-02T14:37:41.290Z (8 months ago)
- Topics: go, gokit, grpc-server, http-server, microservice
- Language: Go
- Homepage: https://luchen.fun
- Size: 2.16 MB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# luchen 基于 go-kit 封装的微服务框架
luchen 是一个基于 [go-kit](https://github.com/go-kit/kit) 封装的微服务框架。秉承 go-kit 的分层设计思想,同时集成了丰富的工程实践设计。它提供了一套完整的解决方案,旨在简化服务开发、提高开发效率,让开发者更专注于业务逻辑的实现。
无论是构建复杂的微服务系统还是简单的单体应用,[luchen](https://github.com/fengjx/luchen) 都能满足你的需求。
> 开始这个项目的时候,我女儿刚出生,取名【路辰】,所以将项目名命名为`luchen`。
## 特性
- 快速开发: 封装了工程实践中常用的组件和工具,可以快速构建和部署服务。
- 多协议支持: 支持 HTTP、gRPC 传输协议,适用于不同的场景和需求,轻松扩展更多协议支持,无需改动业务层代码。
- 分层设计: 保留 go-kit 的分层设计思想,包括端点(Endpoints)、传输(Transport)、服务(Service)等层次,保证了代码的可维护性和可扩展性。
- 微服务支持: 使用 go-kit 实现微服务化架构,支持服务注册、发现、负载均衡、限流、熔断等功能。
- 完善的工具链支持,一键生成 crud 和接口实现代码。
## 快速体验
启动 helloworld 服务
```bash
$ cd _example/helloworld
$ go run main.go
```
请求服务接口
```bash
$ curl 'http://localhost:8080/say-hello' \
--header 'Content-Type: application/json' \
--data '{
"name": "fengjx"
}'
{"Msg":"hello fengjx"}
```
### 示例
- [helloworld](_example/helloworld) 简单示例
- [pbdemo](_example/pbdemo) 基于 proto 协议开发接口示例
- [registrar](_example/registrar) 服务注册与发现示例
## 文档
详细的文档请查阅:
## 相关项目
- [lucky](https://github.com/fengjx/lucky) 基于`luchen`实现的快速开发平台-后端工程
- [lucky-web](https://github.com/fengjx/lucky-web) `lucky`前端工程
- [lc](https://github.com/fengjx/lc) cli 工具
- [daox](https://github.com/fengjx/daox) 数据库访问辅助类库
## 技术交流
加我微信拉你进群,请备注:`luchen`

## 版权声明
你可以自由使用本项目用于个人、商业用途及二次开发,但请注明源码出处。