修改结构
This commit is contained in:
parent
11d4f984b6
commit
b0bb0591bb
|
@ -121,7 +121,7 @@ celerybeat.pid
|
|||
*.sage.py
|
||||
|
||||
# Environments
|
||||
.env
|
||||
*.env
|
||||
.venv
|
||||
env/
|
||||
venv/
|
||||
|
|
32
README.md
32
README.md
|
@ -6,8 +6,16 @@ chassis <ˈʃæsi> n. 底盘,底架
|
|||
|
||||
## 包含的特性
|
||||
|
||||
1. 微服务模板代码
|
||||
2. 可观测 Observability
|
||||
1. 模板代码
|
||||
- nameko 微服务
|
||||
- apiflask Web 服务
|
||||
- rocketry 定时任务服务
|
||||
2. 事务
|
||||
- 实现 Saga 模式
|
||||
3. 查询
|
||||
4. 高可用
|
||||
1.
|
||||
5. 可观测 Observability
|
||||
1. Metrics
|
||||
- Statsd + Prometheus + Grafana)
|
||||
2. Logging
|
||||
|
@ -16,25 +24,27 @@ chassis <ˈʃæsi> n. 底盘,底架
|
|||
- TODO, Maybe OpenTelemetry
|
||||
4. Error Reporting
|
||||
- Sentry
|
||||
3. 数据存储相关 utils
|
||||
6. 数据存储相关 utils
|
||||
1. Sqlalchemy
|
||||
- 连接池
|
||||
- 读写分离
|
||||
2. Redis
|
||||
- 连接池
|
||||
3. ElasticSearch
|
||||
4. 服务注册和发现 (RabbitMQ)
|
||||
5. 健康检查 (TODO)
|
||||
6. 配置获取 (TODO)
|
||||
4. 数据库迁移
|
||||
- Alembic
|
||||
7. 服务注册和发现 (RabbitMQ)
|
||||
8. 配置获取 (TODO)
|
||||
|
||||
|
||||
## 实现的功能
|
||||
|
||||
- 服务注册和发现
|
||||
- 可观测
|
||||
- 同步/异步传输
|
||||
- 负载均衡
|
||||
- 限流降级(消息确认+熔断)
|
||||
- 服务注册和发现(RabbitMQ)
|
||||
- 同步/异步传输(RabbitMQ)
|
||||
- 负载均衡(RabbitMQ)
|
||||
- 限流降级(消息确认+断路器)
|
||||
- 健康检查
|
||||
- 通过可观测实现(Metrics + Logging + Tracing + Error Reporting)
|
||||
|
||||
|
||||
## 安装方法
|
||||
|
|
|
@ -1,9 +1,12 @@
|
|||
nameko==2.14.1
|
||||
nameko-tracer==1.4.0
|
||||
logstash_formatter==0.5.17
|
||||
circuitbreaker==2.0.0
|
||||
statsd==4.0.1
|
||||
gutter==0.5.0
|
||||
request-id==1.0.1
|
||||
nameko-sentry==1.0.0
|
||||
pyopenssl==23.1.1
|
||||
tenacity==8.2.2
|
||||
cachetools==5.3.0
|
||||
circuitbreaker==2.0.0
|
||||
|
||||
|
||||
# pyopenssl==23.1.1
|
19
setup.py
19
setup.py
|
@ -43,14 +43,19 @@ setup(
|
|||
include_package_data=True,
|
||||
|
||||
install_requires=[
|
||||
'nameko==2.14.1',
|
||||
'nameko-tracer==1.3.0',
|
||||
'python-dotenv==1.0.0',
|
||||
'logstash_formatter==0.5.17',
|
||||
'circuitbreaker==2.0.0',
|
||||
'statsd==4.0.1',
|
||||
'gutter==0.5.0',
|
||||
'nameko-sentry==1.0.0',
|
||||
'pyopenssl==23.1.1',
|
||||
'rocketry==2.4.0'
|
||||
'tenacity==8.2.2',
|
||||
'cachetools==5.3.0',
|
||||
'circuitbreaker==2.0.0',
|
||||
],
|
||||
extras_require={
|
||||
'nameko': ['nameko==2.14.1',
|
||||
'nameko-tracer==1.3.0',
|
||||
'nameko-sentry==1.0.0'],
|
||||
'apiflask': ['apiflask>=1.3.1'],
|
||||
'rocketry': ['rocketry==2.4.0'],
|
||||
'gutter': ['gutter==0.5.0'],
|
||||
},
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue