胶料快检添加离线模式

This commit is contained in:
2026-06-30 11:28:04 +08:00
parent efcd73a565
commit 840e68a450
19 changed files with 1053 additions and 343 deletions

View File

@@ -62,10 +62,10 @@ public class NetworkMonitor : INetworkMonitor
private async Task MonitorLoopAsync(CancellationToken cancellationToken)
{
// 启动后立即探活一次,避免首屏 10 秒内 IsOnline 恒为 false
// 启动后立即探活一次,避免首屏秒内 IsOnline 恒为 false
await RunHttpProbeAndRecomputeAsync(cancellationToken).ConfigureAwait(false);
using var timer = new PeriodicTimer(TimeSpan.FromSeconds(10));
using var timer = new PeriodicTimer(TimeSpan.FromSeconds(5));
while (await timer.WaitForNextTickAsync(cancellationToken).ConfigureAwait(false))
{
await RunHttpProbeAndRecomputeAsync(cancellationToken).ConfigureAwait(false);