feat(upserver): 接入认证与KV存档并完成限定钓鱼闭环

This commit is contained in:
Liubing\LB
2026-09-28 18:14:01 +08:00
parent f40a816cc4
commit 0eb43b2b40
129 changed files with 11612 additions and 573 deletions

View File

@@ -10,6 +10,15 @@ namespace Activity
public class ActivitySentryManager
{
private static Dictionary<(int, int), Type> _activitySentryTypes;
private static object _registrationContainer;
private static void EnsureCurrentContainer()
{
if (ReferenceEquals(_registrationContainer, GContext.container)) return;
_registrationContainer = GContext.container;
_activitySentryTypes = null;
TypeKeyCache.Clear();
}
/// <summary>
/// 类型键缓存:Sentry 类型 → (EventType, EventSubType)
@@ -21,6 +30,7 @@ namespace Activity
{
get
{
EnsureCurrentContainer();
if (_activitySentryTypes != null) return _activitySentryTypes;
InitActivitySentryTypes();
@@ -42,6 +52,7 @@ namespace Activity
}
public static void InitActivitySentryType(Type type)
{
EnsureCurrentContainer();
_activitySentryTypes ??= new Dictionary<(int, int), Type>();
try
{
@@ -82,4 +93,4 @@ namespace Activity
return TypeKeyCache.GetValueOrDefault(sentryType);
}
}
}
}