ratchjob 0.2.1

一个rust实现的分布式任务调度平台服务。计划完全兼容xxl-job协议,然后再增强一些任务调度平台能力。
Documentation
// 用于生成 data_object.rs
// pb-rs data_object.proto

syntax = "proto3";

package data_object;

message JobDo {
    uint64 id = 1;
    bool enable = 2;
    string app_name = 3;
    string namespace = 4;
    string description = 5;
    string schedule_type = 6;
    string cron_value = 7;
    uint32 delay_second = 8;
    uint32 interval_second = 9;
    string run_mode = 10;
    string handle_name = 11;
    string trigger_param = 12;
    string router_strategy = 13;
    string past_due_strategy = 14;
    string blocking_strategy = 15;
    uint32 timeout_second = 16;
    uint32 try_times = 17;
    uint64 version_id = 18;
    uint64 last_modified_millis = 19;
    uint64 create_time = 20;
    uint32 retry_interval = 21;
    string job_key = 22;
}

message TaskTryLogDo {
    uint32 execution_time = 1;
    string addr = 2;
}

message JobTaskDo {
    uint64 task_id = 1;
    uint64 job_id = 2;
    uint32 trigger_time = 3;
    string instance_addr = 4;
    string trigger_message = 5;
    string status = 6;
    uint32 finish_time = 7;
    string callback_message = 8;
    uint32 execution_time = 9;
    string trigger_from = 10;
    uint32 try_times = 11;
    repeated TaskTryLogDo try_logs = 12;
    uint32 retry_interval = 13;
    uint32 retry_count = 14;
    uint32 timeout_second = 15;
    bool from_outside = 16;
    string trigger_user = 17;
    string namespace = 18;
    string app_name = 19;
}


message AppInstanceDo {
    string addr = 1;
    uint32 last_modified_time= 2;
    string token= 3;
}

message AppInfoDo {
    string app_name = 1;
    string namespace = 2;
    string label = 3;
    string register_type = 4;
    bool tmp = 5;
    repeated AppInstanceDo instances= 6;
}

message CacheItemDo {
    uint32 cache_type = 1;
    string key = 2;
    bytes data = 3;
    int32 timeout = 4;
}

message PrivilegeGroupDo {
    bool enabled = 1;
    bool whitelist_is_all = 2;
    repeated string whitelist = 3;
    bool blacklist_is_all = 4;
    repeated string blacklist = 5;
}

message UserInfoDo {
    string username = 1;
    string nickname = 2;
    //string password = 3;
    string password_hash = 4;
    int64 gmt_create = 5;
    int64 gmt_modified = 6;
    bool enable = 7;
    repeated string roles = 8;
    map<string, string> extend_info = 9;
    PrivilegeGroupDo namespace_privilege = 10;
    PrivilegeGroupDo app_privilege = 11;
}

message NamespaceDo {
    string id = 1;
    string name = 2;
    string type = 3;
}