8000 GitHub - mrhuyuanchao/go-gin-api: [Go 项目实战] 实现一个开箱即用的 API 框架的轮子,这个轮子是基于 Gin 框架的基础上开发的,便于进行快速的业务开发。
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[Go 项目实战] 实现一个开箱即用的 API 框架的轮子,这个轮子是基于 Gin 框架的基础上开发的,便于进行快速的业务开发。

Notifications You must be signed in to change notification settings

mrhuyuanchao/go-gin-api

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go-gin-api

[Go 项目实战] 实现一个开箱即用的 API 框架的轮子,这个轮子是基于 Gin 框架的基础上开发的。

持续更新...

Features

  • 使用 go modules 初始化项目
  • 安装 Gin 框架
  • 规划项目目录
  • 参数验证
    • 模型绑定和验证
    • 自定义验证器
  • 路由中间件
    • 签名验证
      • MD5 组合拳
      • AES 对称加密
      • RSA 非对称加密
    • 日志记录
    • 异常捕获
    • Jaeger 链路追踪
  • 自定义告警
    • 邮件
    • 微信
    • 短信
    • 钉钉
  • gRPC
  • ...

Download

git clone https://github.com/xinliangnote/go-gin-api.git

Quick start

Requirements

  • Go version >= 1.12
  • Global environment configure (Linux/Mac)
export GO111MODULE=on
export GOPROXY=https://goproxy.io

Build & Run

cd go-gin-api

go run main.go

Test demo

curl -X POST http://127.0.0.1:9999/product

Documents

Learning together

About

[Go 项目实战] 实现一个开箱即用的 API 框架的轮子,这个轮子是基于 Gin 框架的基础上开发的,便于进行快速的业务开发。

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%
0