private Task UpdateTriggerCode(int logId, OPStatus triggerCode, string triggerMessage)
        {
            _taskExecutor.Execute(async(state) =>
            {
                AixScheduleTaskLog log = new AixScheduleTaskLog
                {
                    Id             = logId,
                    TriggerCode    = (int)triggerCode,
                    TriggerMessage = StringUtils.SubString(triggerMessage, _options.LogResultMessageMaxLength > 0 ? _options.LogResultMessageMaxLength : 500),
                    ModifyTime     = DateTime.Now
                };
                await _aixScheduleTaskLogRepository.UpdateAsync(log);
            }, null);

            return(Task.CompletedTask);
        }
        /// <summary>
        ///  保存执行结果
        /// </summary>
        /// <param name="resultDTO"></param>
        /// <returns></returns>
        public Task SaveExecuteResult(ExecuteResult resultDTO)
        {
            _taskExecutor.Execute(async(state) =>
            {
                AixScheduleTaskLog log = new AixScheduleTaskLog
                {
                    Id            = resultDTO.LogId,
                    ResultCode    = resultDTO.Code == 0 ? (int)OPStatus.Success : (int)OPStatus.Fail, //状态 0=初始化 /*1=执行中*/ 2=执行成功 9=执行失败
                    ResultMessage = StringUtils.SubString($"{resultDTO.Code},{resultDTO.Message}", _options.LogResultMessageMaxLength > 0 ? _options.LogResultMessageMaxLength : 500),
                    ResultTime    = DateTime.Now,
                    ModifyTime    = DateTime.Now
                };
                await _aixScheduleTaskLogRepository.UpdateAsync(log);
            }, null);

            return(Task.CompletedTask);
        }