chore(m2): 保存功能验收及后续清理前检查点
This commit is contained in:
@@ -58,7 +58,7 @@ namespace game.PlayerDataStorage
|
||||
internal PlayerKVAccountDescriptor AccountDescriptor =>
|
||||
Volatile.Read(ref prepared) != 0 && IsCurrent ? accountDescriptor : null;
|
||||
|
||||
// Only the coordinator may publish this original handle after Apply and Guard release.
|
||||
// Only the coordinator may publish this original handle after preparation and Guard release.
|
||||
internal bool TryAcquireGameHandle(long expectedEpoch, out PlayerKVGameSessionHandle gameHandle)
|
||||
{
|
||||
gameHandle = null;
|
||||
@@ -351,7 +351,13 @@ namespace game.PlayerDataStorage
|
||||
|
||||
internal HttpMessageHandler CreateHandler(CookieContainer cookies)
|
||||
{
|
||||
var handler = leaseHandler(cookies) ?? throw new InvalidOperationException("Transport handler required.");
|
||||
return CreateHandler(leaseHandler, cookies, formal);
|
||||
}
|
||||
|
||||
internal static HttpMessageHandler CreateHandler(Func<CookieContainer, HttpMessageHandler> factory,
|
||||
CookieContainer cookies, bool formal)
|
||||
{
|
||||
var handler = factory(cookies) ?? throw new InvalidOperationException("Transport handler required.");
|
||||
var seen = new HashSet<HttpMessageHandler>();
|
||||
var node = handler;
|
||||
while (node != null)
|
||||
@@ -359,7 +365,9 @@ namespace game.PlayerDataStorage
|
||||
// Disposing a cyclic DelegatingHandler graph recursively would overflow the stack.
|
||||
// It never becomes a lease; the rejecting factory retains responsibility for that graph.
|
||||
if (!seen.Add(node))
|
||||
{
|
||||
throw new InvalidOperationException("Cyclic transport is not a validation handler.");
|
||||
}
|
||||
if (!formal && (node is HttpClientHandler ||
|
||||
node.GetType().FullName == "System.Net.Http.SocketsHttpHandler"))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user