tiktok-lite

command module
v0.0.0-...-4cd4f3f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

README

tiktok-lite

一个简易版本的抖音server,使用gin+gorm+gen+mysql开发

接口文件在api/目录下

数据库连接可根据自己配置做修改,配置文件在conf/db.go文件

数据库表结构在conf/dump.sql文件

测试数据在conf/data/目录下

gen生成model文件在util.mysql.go文件

重构ing

go version: 1.21

微服务重构day1

因为gorm+gen太麻烦,不好用,因此考虑使用python实现微服务层

使用peewee作为orm

规划好微服务项目目录

├── src: 项目源代码
│   ├── config: 配置文件
│   ├── extra: 外部服务依赖
│   ├── idl: proto文件
│   ├── model: 数据模型
│   ├── rpc: Rpc代码
│   ├── service: 微服务实例
│   ├── storage: 存储相关
│   ├── util: 辅助代码
│   └── web: API网关代码

数据库表重构完成

定义user.proto

day2 TODO:

因为config/strings中的常量在py和go中都需要用到,所以要将config/strings中的文件变成yaml文件供py和go读取

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
dal
src

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL