# xiaoapi-redis
[xiaoapi](https://github.com/xiaojinlii/xiaoapi)的redis扩展包
## 安装
```
pip install xiaoapi-redis
```
## 配置
需要在 application/settings 中 添加以下配置:
```python
# Redis 数据库配置
# 格式:"redis://:密码@地址:端口/数据库名称"
REDIS_DB_ENABLE = False
REDIS_DB_URL = "redis://:123456@177.8.0.5:6379/1"
```
然后在 application/settings 中的 EVENTS 里引入 xiaoapi_redis
```python
EVENTS = [
"xiaoapi_redis.connect_redis",
]
```
Raw data
{
"_id": null,
"home_page": null,
"name": "xiaoapi-redis",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": "xiaoapi, fastapi, web-framework, redis",
"author": null,
"author_email": "xiaojinli <553555614@qq.com>",
"download_url": "https://files.pythonhosted.org/packages/a4/71/b94970c750267fdfaf1d15669dba15b5cc0d67409afddefeaa73d60c195f/xiaoapi-redis-0.0.3.tar.gz",
"platform": null,
"description": "# xiaoapi-redis\r\n[xiaoapi](https://github.com/xiaojinlii/xiaoapi)\u7684redis\u6269\u5c55\u5305\r\n\r\n\r\n## \u5b89\u88c5\r\n```\r\npip install xiaoapi-redis\r\n```\r\n\r\n\r\n## \u914d\u7f6e\r\n\u9700\u8981\u5728 application/settings \u4e2d \u6dfb\u52a0\u4ee5\u4e0b\u914d\u7f6e\uff1a\r\n```python\r\n# Redis \u6570\u636e\u5e93\u914d\u7f6e\r\n# \u683c\u5f0f\uff1a\"redis://:\u5bc6\u7801@\u5730\u5740:\u7aef\u53e3/\u6570\u636e\u5e93\u540d\u79f0\"\r\nREDIS_DB_ENABLE = False\r\nREDIS_DB_URL = \"redis://:123456@177.8.0.5:6379/1\"\r\n```\r\n\r\n\u7136\u540e\u5728 application/settings \u4e2d\u7684 EVENTS \u91cc\u5f15\u5165 xiaoapi_redis\r\n```python\r\nEVENTS = [\r\n \"xiaoapi_redis.connect_redis\",\r\n]\r\n```\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "xiaoapi redis",
"version": "0.0.3",
"project_urls": {
"Documentation": "https://github.com/xiaojinlii/xiaoapi/blob/main/libs/redis/README.md",
"Repository": "https://github.com/xiaojinlii/xiaoapi",
"Source Code": "https://github.com/xiaojinlii/xiaoapi/tree/main/libs/redis"
},
"split_keywords": [
"xiaoapi",
" fastapi",
" web-framework",
" redis"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "222f4705d7400708fcc0dbfc327e0c66564b63aef56564a1b23dc8336fd899fc",
"md5": "bdbce54335548fb91f46ec0011633726",
"sha256": "25c6f72bf6f09910bb58023eddb8be7eca52c06b0603f0e7d96f37fb1d46fee0"
},
"downloads": -1,
"filename": "xiaoapi_redis-0.0.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "bdbce54335548fb91f46ec0011633726",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 4611,
"upload_time": "2024-03-29T01:55:47",
"upload_time_iso_8601": "2024-03-29T01:55:47.634189Z",
"url": "https://files.pythonhosted.org/packages/22/2f/4705d7400708fcc0dbfc327e0c66564b63aef56564a1b23dc8336fd899fc/xiaoapi_redis-0.0.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "a471b94970c750267fdfaf1d15669dba15b5cc0d67409afddefeaa73d60c195f",
"md5": "25cda8380175d2ffdc33172e35f8e92d",
"sha256": "6514afbb40dd3a4a17299b0de7d2aa5fb9823fb30327936d916f19ca866e8cb4"
},
"downloads": -1,
"filename": "xiaoapi-redis-0.0.3.tar.gz",
"has_sig": false,
"md5_digest": "25cda8380175d2ffdc33172e35f8e92d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 5866,
"upload_time": "2024-03-29T01:55:50",
"upload_time_iso_8601": "2024-03-29T01:55:50.868451Z",
"url": "https://files.pythonhosted.org/packages/a4/71/b94970c750267fdfaf1d15669dba15b5cc0d67409afddefeaa73d60c195f/xiaoapi-redis-0.0.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-03-29 01:55:50",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "xiaojinlii",
"github_project": "xiaoapi",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "fastapi",
"specs": [
[
"==",
"0.110.0"
]
]
},
{
"name": "uvicorn",
"specs": [
[
"==",
"0.25.0"
]
]
},
{
"name": "typer",
"specs": [
[
"==",
"0.10.0"
]
]
},
{
"name": "loguru",
"specs": [
[
"==",
"0.7.2"
]
]
},
{
"name": "orjson",
"specs": [
[
"==",
"3.9.15"
]
]
},
{
"name": "SQLAlchemy",
"specs": [
[
"==",
"2.0.25"
]
]
},
{
"name": "asyncmy",
"specs": [
[
"==",
"0.2.9"
]
]
},
{
"name": "aiosqlite",
"specs": [
[
"==",
"0.20.0"
]
]
}
],
"lcname": "xiaoapi-redis"
}