为task增加sourcepath,便于处理

This commit is contained in:
algotao
2025-07-25 12:04:16 +08:00
parent d1ad148725
commit a2bf3c853e
5 changed files with 303 additions and 63 deletions

View File

@@ -16,6 +16,8 @@ message SaasReq {
TaskRun task_run = 22; // 执行任务
TaskDelete task_delete = 23; // 删除任务
TaskInfo task_info = 24; // 任务详情
Debug debug = 30; // 试运行lua脚本
}
}
@@ -90,6 +92,8 @@ message Task {
string task_description = 4; // 任务描述
repeated FileInfo task_file_infos = 5; // 文件列表
uint64 task_block_size = 6; // 文件块字节大小推荐200M
string source_path = 7; // 任务数据源路径
uint64 task_size = 8; // 任务所有文件的总大小
// 以下字段只在返回时填写,用于提供服务端的任务状态。在请求时填写会被忽略
string create_time = 10; // 创建时间
@@ -131,6 +135,16 @@ message FileBlock {
bool uploaded = 3; // 是否已上传在TaskCreate/TaskInfo请求返回
}
message Debug {
string lua_script = 1; // 要调试的lua脚本
bool use_server_data = 2; // 是否使用服务端用户数据
string server_did = 3; // 将从服务端读取该DID下的数据
string appid = 4; // 小程序/小游戏/公众号/视频号的appid
string server_openid = 5; // 将从服务端读取该openid下的数据需与appid配对使用
WriteItem local_did_data = 6; // 客户自定义DID用户数据
WriteItem local_openid_data = 7; // 客户定定义OpenID用户数据
}
// SaasRes 命令返回
message SaasRes {
ErrorCode code = 1; // 返回码
@@ -173,6 +187,12 @@ message TaskListRes {
repeated Task tasks = 1; // 任务列表
}
message DebugRes {
string PrintOutput = 1; // print输出
string Error = 2; // 错误信息
string TargetsOutput = 3; // 策略输出
}
// ErrorCode 返回码
enum ErrorCode {
SUCC = 0; // 成功