文档
测试

7 本地接口-刷新缓存-/openresty/flush/cache

GET
/openresty/flush/cache

接口描述

刷新或者清空缓存重新加载

请求参数

参数名
类型
描述
必填
option
string
(必填)flush/clean 刷新/清空刷新
必填
type
string
user/code 当option=flush时,user:刷新user表到redis,code:刷新code表到redis
必填
token
string
(必填)密钥,在serviceFlushCache.lua配置
必填

说明 / 示例

- 数据库有新增用户 ```sh curl 'http://localhost:5000/openresty/flush/cache?token=sjDJ23lDsPsq9v0mJkdi&type=user&option=flush' ``` - 数据库有新增邀请码 ```sh curl 'http://localhost:5000/openresty/flush/cache?token=sjDJ23lDsPsq9v0mJkdi&type=code&option=flush' ``` - 数据库有删除用户或邀请码 ```sh curl 'http://localhost:5000/openresty/flush/cache?token=sjDJ23lDsPsq9v0mJkdi&option=clean' ```