方法列表
创建任务
admin
user
RPC
createHTTPCacheTask (CreateHTTPCacheTaskRequest) returns (CreateHTTPCacheTaskResponse)
HTTP
POST /HTTPCacheTaskService/createHTTPCacheTask
输入对象:CreateHTTPCacheTaskRequest:
{ // 任务类型,值为 purge 或者 fetch;purge:删除缓存,fetch:预热缓存 string type; // Key类型,值为 key 或者 prefix;如果是 key 表示处理的是URL,如果是 prefix 表示处理的是目录;预热的时候只能为 key string keyType; // 要清理的Key,根据Key类型(keyType)来输入不同的内容 []string keys; }
输出对象:CreateHTTPCacheTaskResponse:
{ // 生成的任务ID int64 httpCacheTaskId; // 任务中包含的Key int64 countKeys; }
计算任务总数量
admin
user
RPC
countHTTPCacheTasks (CountHTTPCacheTasksRequest) returns (RPCCountResponse)
HTTP
POST /HTTPCacheTaskService/countHTTPCacheTasks
输入对象:CountHTTPCacheTasksRequest:
{ }
输出对象:RPCCountResponse:
{ // 数量 int64 count; }
计算正在执行的任务数量
admin
user
RPC
countDoingHTTPCacheTasks (CountDoingHTTPCacheTasksRequest) returns (RPCCountResponse)
HTTP
POST /HTTPCacheTaskService/countDoingHTTPCacheTasks
输入对象:CountDoingHTTPCacheTasksRequest:
{ }
输出对象:RPCCountResponse:
{ // 数量 int64 count; }
列出单页任务
admin
user
RPC
listHTTPCacheTasks (ListHTTPCacheTasksRequest) returns (ListHTTPCacheTasksResponse)
HTTP
POST /HTTPCacheTaskService/listHTTPCacheTasks
输入对象:ListHTTPCacheTasksRequest:
{ // 查询起始位置 int64 offset; // 查询条数 int64 size; }
输出对象:ListHTTPCacheTasksResponse:
{ // 一组任务信息 []HTTPCacheTask httpCacheTasks; }
查找单个任务
admin
user
RPC
findEnabledHTTPCacheTask (FindEnabledHTTPCacheTaskRequest) returns (FindEnabledHTTPCacheTaskResponse)
HTTP
POST /HTTPCacheTaskService/findEnabledHTTPCacheTask
输入对象:FindEnabledHTTPCacheTaskRequest:
{ // 任务ID int64 httpCacheTaskId; }
输出对象:FindEnabledHTTPCacheTaskResponse:
{ // 任务信息 HTTPCacheTask httpCacheTask; }
删除任务
admin
user
RPC
deleteHTTPCacheTask (DeleteHTTPCacheTaskRequest) returns (RPCSuccess)
HTTP
POST /HTTPCacheTaskService/deleteHTTPCacheTask
输入对象:DeleteHTTPCacheTaskRequest:
{ // 任务ID int64 httpCacheTaskId; }
输出对象:RPCSuccess:
{ }
重置任务状态
admin
RPC
resetHTTPCacheTask (ResetHTTPCacheTaskRequest) returns (RPCSuccess)
HTTP
POST /HTTPCacheTaskService/resetHTTPCacheTask
输入对象:ResetHTTPCacheTaskRequest:
{ // 任务ID int64 httpCacheTaskId; }
输出对象:RPCSuccess:
{ }