Skip to content

Commit ffd35e4

Browse files
authored
Merge pull request #54010 from vseanreesermsft/internal-merge-7.0-2024-02-13-1019
Merging internal commits for release/7.0
2 parents c3ff66e + 199362a commit ffd35e4

File tree

10 files changed

+407
-381
lines changed

10 files changed

+407
-381
lines changed

NuGet.config

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@
44
<clear />
55
<!--Begin: Package sources managed by Dependency Flow automation. Do not edit the sources below.-->
66
<!-- Begin: Package sources from dotnet-efcore -->
7+
<add key="darc-int-dotnet-efcore-819a61e" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-efcore-819a61e6/nuget/v3/index.json" />
78
<!-- End: Package sources from dotnet-efcore -->
89
<!-- Begin: Package sources from dotnet-runtime -->
10+
<add key="darc-int-dotnet-runtime-567edaf" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-567edafe/nuget/v3/index.json" />
911
<!-- End: Package sources from dotnet-runtime -->
1012
<!--End: Package sources managed by Dependency Flow automation. Do not edit the sources above.-->
1113
<add key="dotnet-eng" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-eng/nuget/v3/index.json" />
@@ -24,8 +26,10 @@
2426
<clear />
2527
<!--Begin: Package sources managed by Dependency Flow automation. Do not edit the sources below.-->
2628
<!-- Begin: Package sources from dotnet-efcore -->
29+
<add key="darc-int-dotnet-efcore-819a61e" value="true" />
2730
<!-- End: Package sources from dotnet-efcore -->
2831
<!-- Begin: Package sources from dotnet-runtime -->
32+
<add key="darc-int-dotnet-runtime-567edaf" value="true" />
2933
<!-- End: Package sources from dotnet-runtime -->
3034
<!--End: Package sources managed by Dependency Flow automation. Do not edit the sources above.-->
3135
</disabledPackageSources>

eng/Baseline.Designer.props

Lines changed: 210 additions & 210 deletions
Large diffs are not rendered by default.

eng/Baseline.xml

Lines changed: 104 additions & 104 deletions
Large diffs are not rendered by default.

eng/Version.Details.xml

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -9,37 +9,37 @@
99
-->
1010
<Dependencies>
1111
<ProductDependencies>
12-
<Dependency Name="dotnet-ef" Version="7.0.15">
12+
<Dependency Name="dotnet-ef" Version="7.0.16">
1313
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
14-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
14+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
1515
</Dependency>
16-
<Dependency Name="Microsoft.EntityFrameworkCore.InMemory" Version="7.0.15">
16+
<Dependency Name="Microsoft.EntityFrameworkCore.InMemory" Version="7.0.16">
1717
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
18-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
18+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
1919
</Dependency>
20-
<Dependency Name="Microsoft.EntityFrameworkCore.Relational" Version="7.0.15">
20+
<Dependency Name="Microsoft.EntityFrameworkCore.Relational" Version="7.0.16">
2121
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
22-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
22+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
2323
</Dependency>
24-
<Dependency Name="Microsoft.EntityFrameworkCore.Sqlite" Version="7.0.15">
24+
<Dependency Name="Microsoft.EntityFrameworkCore.Sqlite" Version="7.0.16">
2525
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
26-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
26+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
2727
</Dependency>
28-
<Dependency Name="Microsoft.EntityFrameworkCore.SqlServer" Version="7.0.15">
28+
<Dependency Name="Microsoft.EntityFrameworkCore.SqlServer" Version="7.0.16">
2929
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
30-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
30+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
3131
</Dependency>
32-
<Dependency Name="Microsoft.EntityFrameworkCore.Tools" Version="7.0.15">
32+
<Dependency Name="Microsoft.EntityFrameworkCore.Tools" Version="7.0.16">
3333
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
34-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
34+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
3535
</Dependency>
36-
<Dependency Name="Microsoft.EntityFrameworkCore" Version="7.0.15">
36+
<Dependency Name="Microsoft.EntityFrameworkCore" Version="7.0.16">
3737
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
38-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
38+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
3939
</Dependency>
40-
<Dependency Name="Microsoft.EntityFrameworkCore.Design" Version="7.0.15">
40+
<Dependency Name="Microsoft.EntityFrameworkCore.Design" Version="7.0.16">
4141
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-efcore</Uri>
42-
<Sha>ec0d745b900c6007fc93d16fbc70ab59729e6b1e</Sha>
42+
<Sha>819a61e6a4687309ad410167d488010192a27abc</Sha>
4343
</Dependency>
4444
<Dependency Name="Microsoft.Extensions.Caching.Abstractions" Version="7.0.0">
4545
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
@@ -177,9 +177,9 @@
177177
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
178178
<Sha>d099f075e45d2aa6007a22b71b45a08758559f80</Sha>
179179
</Dependency>
180-
<Dependency Name="Microsoft.Internal.Runtime.AspNetCore.Transport" Version="7.0.15-servicing.23572.26">
180+
<Dependency Name="Microsoft.Internal.Runtime.AspNetCore.Transport" Version="7.0.16-servicing.24066.29">
181181
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
182-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
182+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
183183
</Dependency>
184184
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-externals" Version="7.0.0-alpha.1.24059.2">
185185
<Uri>https://github.com/dotnet/source-build-externals</Uri>
@@ -262,33 +262,33 @@
262262
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
263263
<Sha>d099f075e45d2aa6007a22b71b45a08758559f80</Sha>
264264
</Dependency>
265-
<Dependency Name="Microsoft.NETCore.App.Ref" Version="7.0.15">
265+
<Dependency Name="Microsoft.NETCore.App.Ref" Version="7.0.16">
266266
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
267-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
267+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
268268
</Dependency>
269-
<Dependency Name="Microsoft.NET.Runtime.MonoAOTCompiler.Task" Version="7.0.15">
269+
<Dependency Name="Microsoft.NET.Runtime.MonoAOTCompiler.Task" Version="7.0.16">
270270
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
271-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
271+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
272272
</Dependency>
273-
<Dependency Name="Microsoft.NET.Runtime.WebAssembly.Sdk" Version="7.0.15">
273+
<Dependency Name="Microsoft.NET.Runtime.WebAssembly.Sdk" Version="7.0.16">
274274
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
275-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
275+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
276276
</Dependency>
277277
<!--
278278
Win-x64 is used here because we have picked an arbitrary runtime identifier to flow the version of the latest NETCore.App runtime.
279279
All Runtime.$rid packages should have the same version.
280280
-->
281-
<Dependency Name="Microsoft.NETCore.App.Runtime.win-x64" Version="7.0.15">
281+
<Dependency Name="Microsoft.NETCore.App.Runtime.win-x64" Version="7.0.16">
282282
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
283-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
283+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
284284
</Dependency>
285-
<Dependency Name="Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.browser-wasm" Version="7.0.15">
285+
<Dependency Name="Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.browser-wasm" Version="7.0.16">
286286
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
287-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
287+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
288288
</Dependency>
289-
<Dependency Name="Microsoft.NETCore.BrowserDebugHost.Transport" Version="7.0.15-servicing.23572.26">
289+
<Dependency Name="Microsoft.NETCore.BrowserDebugHost.Transport" Version="7.0.16-servicing.24066.29">
290290
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
291-
<Sha>8f4568cdaa2f9654fd133a17cd2dcc55b5f42455</Sha>
291+
<Sha>567edafe6106e6b769c64f6a2ed876190baa642a</Sha>
292292
</Dependency>
293293
<Dependency Name="Microsoft.Web.Xdt" Version="7.0.0-preview.22423.2">
294294
<Uri>https://github.com/dotnet/xdt</Uri>

eng/Versions.props

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<AspNetCoreMajorVersion>7</AspNetCoreMajorVersion>
1010
<AspNetCoreMinorVersion>0</AspNetCoreMinorVersion>
1111
<AspNetCorePatchVersion>17</AspNetCorePatchVersion>
12-
<ValidateBaseline>false</ValidateBaseline>
12+
<ValidateBaseline>true</ValidateBaseline>
1313
<!--
1414
When StabilizePackageVersion is set to 'true', this branch will produce stable outputs for 'Shipping' packages
1515
-->
@@ -63,12 +63,12 @@
6363
<PropertyGroup Label="Automated">
6464
<!-- Packages from dotnet/runtime -->
6565
<MicrosoftExtensionsDependencyModelVersion>7.0.0</MicrosoftExtensionsDependencyModelVersion>
66-
<MicrosoftNETCoreAppRefVersion>7.0.15</MicrosoftNETCoreAppRefVersion>
67-
<MicrosoftNETCoreAppRuntimewinx64Version>7.0.15</MicrosoftNETCoreAppRuntimewinx64Version>
68-
<MicrosoftNETRuntimeMonoAOTCompilerTaskVersion>7.0.15</MicrosoftNETRuntimeMonoAOTCompilerTaskVersion>
69-
<MicrosoftNETRuntimeWebAssemblySdkVersion>7.0.15</MicrosoftNETRuntimeWebAssemblySdkVersion>
70-
<MicrosoftNETCoreAppRuntimeAOTwinx64CrossbrowserwasmVersion>7.0.15</MicrosoftNETCoreAppRuntimeAOTwinx64CrossbrowserwasmVersion>
71-
<MicrosoftNETCoreBrowserDebugHostTransportVersion>7.0.15-servicing.23572.26</MicrosoftNETCoreBrowserDebugHostTransportVersion>
66+
<MicrosoftNETCoreAppRefVersion>7.0.16</MicrosoftNETCoreAppRefVersion>
67+
<MicrosoftNETCoreAppRuntimewinx64Version>7.0.16</MicrosoftNETCoreAppRuntimewinx64Version>
68+
<MicrosoftNETRuntimeMonoAOTCompilerTaskVersion>7.0.16</MicrosoftNETRuntimeMonoAOTCompilerTaskVersion>
69+
<MicrosoftNETRuntimeWebAssemblySdkVersion>7.0.16</MicrosoftNETRuntimeWebAssemblySdkVersion>
70+
<MicrosoftNETCoreAppRuntimeAOTwinx64CrossbrowserwasmVersion>7.0.16</MicrosoftNETCoreAppRuntimeAOTwinx64CrossbrowserwasmVersion>
71+
<MicrosoftNETCoreBrowserDebugHostTransportVersion>7.0.16-servicing.24066.29</MicrosoftNETCoreBrowserDebugHostTransportVersion>
7272
<MicrosoftExtensionsCachingAbstractionsVersion>7.0.0</MicrosoftExtensionsCachingAbstractionsVersion>
7373
<MicrosoftExtensionsCachingMemoryVersion>7.0.0</MicrosoftExtensionsCachingMemoryVersion>
7474
<MicrosoftExtensionsConfigurationAbstractionsVersion>7.0.0</MicrosoftExtensionsConfigurationAbstractionsVersion>
@@ -103,7 +103,7 @@
103103
<MicrosoftExtensionsOptionsDataAnnotationsVersion>7.0.0</MicrosoftExtensionsOptionsDataAnnotationsVersion>
104104
<MicrosoftExtensionsOptionsVersion>7.0.1</MicrosoftExtensionsOptionsVersion>
105105
<MicrosoftExtensionsPrimitivesVersion>7.0.0</MicrosoftExtensionsPrimitivesVersion>
106-
<MicrosoftInternalRuntimeAspNetCoreTransportVersion>7.0.15-servicing.23572.26</MicrosoftInternalRuntimeAspNetCoreTransportVersion>
106+
<MicrosoftInternalRuntimeAspNetCoreTransportVersion>7.0.16-servicing.24066.29</MicrosoftInternalRuntimeAspNetCoreTransportVersion>
107107
<SystemConfigurationConfigurationManagerVersion>7.0.0</SystemConfigurationConfigurationManagerVersion>
108108
<SystemDiagnosticsDiagnosticSourceVersion>7.0.2</SystemDiagnosticsDiagnosticSourceVersion>
109109
<SystemDiagnosticsEventLogVersion>7.0.0</SystemDiagnosticsEventLogVersion>
@@ -125,14 +125,14 @@
125125
<!-- Only listed explicitly to workaround https://github.com/dotnet/cli/issues/10528 -->
126126
<MicrosoftNETCorePlatformsVersion>7.0.4</MicrosoftNETCorePlatformsVersion>
127127
<!-- Packages from dotnet/efcore -->
128-
<dotnetefVersion>7.0.15</dotnetefVersion>
129-
<MicrosoftEntityFrameworkCoreInMemoryVersion>7.0.15</MicrosoftEntityFrameworkCoreInMemoryVersion>
130-
<MicrosoftEntityFrameworkCoreRelationalVersion>7.0.15</MicrosoftEntityFrameworkCoreRelationalVersion>
131-
<MicrosoftEntityFrameworkCoreSqliteVersion>7.0.15</MicrosoftEntityFrameworkCoreSqliteVersion>
132-
<MicrosoftEntityFrameworkCoreSqlServerVersion>7.0.15</MicrosoftEntityFrameworkCoreSqlServerVersion>
133-
<MicrosoftEntityFrameworkCoreToolsVersion>7.0.15</MicrosoftEntityFrameworkCoreToolsVersion>
134-
<MicrosoftEntityFrameworkCoreVersion>7.0.15</MicrosoftEntityFrameworkCoreVersion>
135-
<MicrosoftEntityFrameworkCoreDesignVersion>7.0.15</MicrosoftEntityFrameworkCoreDesignVersion>
128+
<dotnetefVersion>7.0.16</dotnetefVersion>
129+
<MicrosoftEntityFrameworkCoreInMemoryVersion>7.0.16</MicrosoftEntityFrameworkCoreInMemoryVersion>
130+
<MicrosoftEntityFrameworkCoreRelationalVersion>7.0.16</MicrosoftEntityFrameworkCoreRelationalVersion>
131+
<MicrosoftEntityFrameworkCoreSqliteVersion>7.0.16</MicrosoftEntityFrameworkCoreSqliteVersion>
132+
<MicrosoftEntityFrameworkCoreSqlServerVersion>7.0.16</MicrosoftEntityFrameworkCoreSqlServerVersion>
133+
<MicrosoftEntityFrameworkCoreToolsVersion>7.0.16</MicrosoftEntityFrameworkCoreToolsVersion>
134+
<MicrosoftEntityFrameworkCoreVersion>7.0.16</MicrosoftEntityFrameworkCoreVersion>
135+
<MicrosoftEntityFrameworkCoreDesignVersion>7.0.16</MicrosoftEntityFrameworkCoreDesignVersion>
136136
<!-- Packages from dotnet/arcade -->
137137
<MicrosoftDotNetBuildTasksInstallersVersion>7.0.0-beta.24059.5</MicrosoftDotNetBuildTasksInstallersVersion>
138138
<MicrosoftDotNetBuildTasksTemplatingVersion>7.0.0-beta.24059.5</MicrosoftDotNetBuildTasksTemplatingVersion>

global.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
22
"sdk": {
3-
"version": "7.0.115"
3+
"version": "7.0.116"
44
},
55
"tools": {
6-
"dotnet": "7.0.115",
6+
"dotnet": "7.0.116",
77
"runtimes": {
88
"dotnet/x86": [
99
"$(MicrosoftNETCoreBrowserDebugHostTransportVersion)"

src/SignalR/common/Http.Connections/src/HttpConnectionDispatcherOptions.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,6 @@ public TimeSpan TransportSendTimeout
120120
}
121121

122122
_transportSendTimeout = value;
123-
TransportSendTimeoutTicks = value.Ticks;
124123
}
125124
}
126125

@@ -133,7 +132,6 @@ public TimeSpan TransportSendTimeout
133132
/// </remarks>
134133
public bool CloseOnAuthenticationExpiration { get; set; }
135134

136-
internal long TransportSendTimeoutTicks { get; private set; }
137135
internal bool TransportSendTimeoutEnabled => _transportSendTimeout != Timeout.InfiniteTimeSpan;
138136

139137
// We initialize these lazily based on the state of the options specified here.

src/SignalR/common/Http.Connections/src/Internal/HttpConnectionContext.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ internal sealed partial class HttpConnectionContext : ConnectionContext,
4545

4646
private CancellationTokenSource? _sendCts;
4747
private bool _activeSend;
48-
private long _startedSendTime;
48+
private TimeSpan _startedSendTime;
4949
private readonly object _sendingLock = new object();
5050
internal CancellationToken SendingToken { get; private set; }
5151

@@ -65,7 +65,7 @@ public HttpConnectionContext(string connectionId, string connectionToken, ILogge
6565

6666
ConnectionId = connectionId;
6767
ConnectionToken = connectionToken;
68-
LastSeenTicks = Environment.TickCount64;
68+
LastSeenTicks = TimeSpan.FromMilliseconds(Environment.TickCount64);
6969
_options = options;
7070

7171
// The default behavior is that both formats are supported.
@@ -118,9 +118,9 @@ public HttpConnectionContext(string connectionId, string connectionToken, ILogge
118118

119119
public Task? ApplicationTask { get; set; }
120120

121-
public long LastSeenTicks { get; set; }
121+
public TimeSpan LastSeenTicks { get; set; }
122122

123-
public long? LastSeenTicksIfInactive
123+
public TimeSpan? LastSeenTicksIfInactive
124124
{
125125
get
126126
{
@@ -541,7 +541,7 @@ public void MarkInactive()
541541
if (Status == HttpConnectionStatus.Active)
542542
{
543543
Status = HttpConnectionStatus.Inactive;
544-
LastSeenTicks = Environment.TickCount64;
544+
LastSeenTicks = TimeSpan.FromMilliseconds(Environment.TickCount64);
545545
}
546546
}
547547
}
@@ -573,12 +573,12 @@ internal void StartSendCancellation()
573573
_sendCts = new CancellationTokenSource();
574574
SendingToken = _sendCts.Token;
575575
}
576-
_startedSendTime = Environment.TickCount64;
576+
_startedSendTime = TimeSpan.FromMilliseconds(Environment.TickCount64);
577577
_activeSend = true;
578578
}
579579
}
580580

581-
internal void TryCancelSend(long currentTicks)
581+
internal void TryCancelSend(TimeSpan currentTicks)
582582
{
583583
if (!_options.TransportSendTimeoutEnabled)
584584
{
@@ -589,7 +589,7 @@ internal void TryCancelSend(long currentTicks)
589589
{
590590
if (_activeSend)
591591
{
592-
if (currentTicks - _startedSendTime > _options.TransportSendTimeoutTicks)
592+
if (currentTicks - _startedSendTime > _options.TransportSendTimeout)
593593
{
594594
_sendCts!.Cancel();
595595

src/SignalR/common/Http.Connections/src/Internal/HttpConnectionManager.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@ internal sealed partial class HttpConnectionManager
2424
private readonly PeriodicTimer _nextHeartbeat;
2525
private readonly ILogger<HttpConnectionManager> _logger;
2626
private readonly ILogger<HttpConnectionContext> _connectionLogger;
27-
private readonly long _disconnectTimeoutTicks;
27+
private readonly TimeSpan _disconnectTimeout;
2828

2929
public HttpConnectionManager(ILoggerFactory loggerFactory, IHostApplicationLifetime appLifetime, IOptions<ConnectionOptions> connectionOptions)
3030
{
3131
_logger = loggerFactory.CreateLogger<HttpConnectionManager>();
3232
_connectionLogger = loggerFactory.CreateLogger<HttpConnectionContext>();
3333
_nextHeartbeat = new PeriodicTimer(_heartbeatTickRate);
34-
_disconnectTimeoutTicks = (long)(connectionOptions.Value.DisconnectTimeout ?? ConnectionOptionsSetup.DefaultDisconectTimeout).TotalMilliseconds;
34+
_disconnectTimeout = connectionOptions.Value.DisconnectTimeout ?? ConnectionOptionsSetup.DefaultDisconectTimeout;
3535

3636
// Register these last as the callbacks could run immediately
3737
appLifetime.ApplicationStarted.Register(() => Start());
@@ -134,7 +134,7 @@ private async Task ExecuteTimerLoop()
134134
public void Scan()
135135
{
136136
var now = DateTimeOffset.UtcNow;
137-
var ticks = Environment.TickCount64;
137+
var ticks = TimeSpan.FromMilliseconds(Environment.TickCount64);
138138

139139
// Scan the registered connections looking for ones that have timed out
140140
foreach (var c in _connections)
@@ -145,7 +145,7 @@ public void Scan()
145145

146146
// Once the decision has been made to dispose we don't check the status again
147147
// But don't clean up connections while the debugger is attached.
148-
if (!Debugger.IsAttached && lastSeenTick.HasValue && (ticks - lastSeenTick.Value) > _disconnectTimeoutTicks)
148+
if (!Debugger.IsAttached && lastSeenTick.HasValue && (ticks - lastSeenTick.Value) > _disconnectTimeout)
149149
{
150150
Log.ConnectionTimedOut(_logger, connection.ConnectionId);
151151
HttpConnectionsEventSource.Log.ConnectionTimedOut(connection.ConnectionId);

0 commit comments

Comments
 (0)