wanshenmean
昨天 627371d0ffdf50239313f2c86d022a0c5c69550d
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotStateManager.cs
@@ -1,6 +1,5 @@
using Microsoft.Extensions.Logging;
using Newtonsoft.Json;
using WIDESEAWCS_Core.LogHelper;
using Serilog;
using WIDESEAWCS_ITaskInfoRepository;
using WIDESEAWCS_Model.Models;
@@ -94,8 +93,7 @@
            if (currentEntity == null)
            {
                _repository.GetOrCreate(newState.IPAddress, newState.RobotCrane ?? new RobotCraneDevice());
                _logger.LogDebug("TryUpdateStateSafely:创建新状态,IP: {IpAddress}", ipAddress);
                QuartzLogger.Debug($"创建新状态,IP: {ipAddress}", ipAddress);
                QuartzLogHelper.LogDebug(_logger, $"创建新状态,IP: {ipAddress}", ipAddress);
                return true;
            }
@@ -112,8 +110,7 @@
            if (!success)
            {
                _logger.LogWarning("TryUpdateStateSafely:版本冲突,更新失败,IP: {IpAddress},期望版本: {ExpectedVersion}", ipAddress, expectedVersion);
                QuartzLogger.Warn($"版本冲突,更新失败,IP: {ipAddress}", ipAddress);
                QuartzLogHelper.LogWarn(_logger, $"TryUpdateStateSafely:版本冲突,更新失败,IP: {ipAddress},期望版本: {expectedVersion}", ipAddress);
            }
            return success;
@@ -161,4 +158,4 @@
            return _repository.ToSocketState(entity);
        }
    }
}
}