Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update SDK #4162

Merged
merged 3 commits into from
Jul 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
<!-- This is false for local development, but set to true in the CI system -->
<TreatWarningsAsErrors Condition=" '$(TreatWarningsAsErrors)' == '' ">false</TreatWarningsAsErrors>

<!-- TODO: remove once https://github.com/dotnet/extensions/issues/4161 is resolved -->
<NoWarn>$(NoWarn);TBD</NoWarn>

<!--
TODO: to be resolved (https://github.com/dotnet/extensions/issues/4128)

Expand Down
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"sdk": {
"version": "8.0.100-preview.7.23328.2"
"version": "8.0.100-preview.7.23360.1"
},
"tools": {
"dotnet": "8.0.100-preview.7.23328.2",
"dotnet": "8.0.100-preview.7.23360.1",
"runtimes": {
"dotnet/x64": [
"3.1.32",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ internal sealed class TcpEndpointHealthCheckService : BackgroundService
private readonly ILogger<TcpEndpointHealthCheckService> _logger;
private readonly HealthCheckService _healthCheckService;
private readonly KubernetesProbesOptions.EndpointOptions _options;
#pragma warning disable CA2213 // 'TcpEndpointHealthCheckService' contains field '_listener' that is of IDisposable type 'TcpListener'
private readonly TcpListener _listener;
#pragma warning restore CA2213

public TcpEndpointHealthCheckService(ILogger<TcpEndpointHealthCheckService> logger, HealthCheckService healthCheckService, KubernetesProbesOptions.EndpointOptions options)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,9 @@ private static bool IsTcpOpened(int port)

private static int GetFreeTcpPort()
{
#pragma warning disable CA2000 // Dispose objects before losing scope
var listener = new TcpListener(IPAddress.Loopback, 0);
#pragma warning restore CA2000 // Dispose objects before losing scope
listener.Start();
int port = ((IPEndPoint)listener.LocalEndpoint).Port;
listener.Stop();
Expand Down