wanshenmean
2026-03-13 0dbc8273bdfbcabcc4b770546245f6b17d787de9
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_RedisService/Cache/CacheSyncBackgroundService.cs
@@ -132,6 +132,15 @@
                    try
                    {
                        var keyStr = redisKey.ToString();
                        // 跳过排除的key前缀(如设备状态等频繁变动的数据)
                        if (_options.SyncExcludePrefixes.Any(prefix => keyStr.StartsWith(prefix, StringComparison.Ordinal)))
                        {
                            _logger.LogTrace("跳过排除的key: {Key}", keyStr);
                            skippedCount++;
                            continue;
                        }
                        _trackedKeys.AddOrUpdate(keyStr, true, (_, _) => true);
                        // 获取Redis中的值