Skip to content

Commit

Permalink
Update to 9.0.200 preview and it complained about unused private memb…
Browse files Browse the repository at this point in the history
…ers (#7114)
  • Loading branch information
davidfowl authored Jan 15, 2025
1 parent 9cbe012 commit 2780cdc
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 43 deletions.
13 changes: 0 additions & 13 deletions src/Aspire.Hosting/Dcp/ApplicationExecutor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,6 @@ DcpNameGenerator nameGenerator
{
private const string DebugSessionPortVar = "DEBUG_SESSION_PORT";

// A random suffix added to every DCP object name ensures that those names (and derived object names, for example container names)
// are unique machine-wide with a high level of probability.
// The length of 8 achieves that while keeping the names relatively short and readable.
// The second purpose of the suffix is to play a role of a unique OpenTelemetry service instance ID.
private const int RandomNameSuffixLength = 8;

private const string DefaultAspireNetworkName = "default-aspire-network";

private readonly ILogger<ApplicationExecutor> _logger = logger;
Expand Down Expand Up @@ -2006,13 +2000,6 @@ private static string GenerateUniqueServiceName(HashSet<string> serviceNames, st
return uniqueName;
}

private static string GetRandomNameSuffix()
{
// RandomNameSuffixLength of lowercase characters
var suffix = PasswordGenerator.Generate(RandomNameSuffixLength, true, false, false, false, RandomNameSuffixLength, 0, 0, 0);
return suffix;
}

/// <summary>
/// Create a patch update using the specified resource.
/// A copy is taken of the resource to avoid permanently changing it.
Expand Down
30 changes: 0 additions & 30 deletions tests/Aspire.Playground.Tests/AppHostTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -262,29 +262,6 @@ public static IList<TestEndpoints> GetAllTestEndpoints()
return candidates;
}

private static async Task TestEventHubsAppHost(DistributedApplication app, string appHostPath, ITestOutputHelper testOutput)
{
using var client = CreateHttpClientWithResilience(app, "api");

var path = "/test";
testOutput.WriteLine($"*** TestEventHubsAppHost calling {path} endpoint");

var response = await client.GetAsync(path);
Assert.True(HttpStatusCode.OK == response.StatusCode, $"Endpoint '{client.BaseAddress}{path.TrimStart('/')}' for resource 'consumer' in app '{Path.GetFileNameWithoutExtension(appHostPath)}' returned status code {response.StatusCode}");

var consumerMessage = "Hello, from /test sent via producerClient";
try
{
await app.WaitForTextAsync(log => log.Contains(consumerMessage), resourceName: "consumer")
.WaitAsync(TimeSpan.FromMinutes(2))
.ConfigureAwait(false);
}
catch (TimeoutException te)
{
throw new XunitException($"Timed out waiting for the consumer message to be logged: '{consumerMessage}'", te);
}
}

public static TheoryData<TestEndpoints> TestEndpoints()
{
TheoryData<TestEndpoints> theoryData = new();
Expand All @@ -303,13 +280,6 @@ public static TheoryData<TestEndpoints> TestEndpoints()

return theoryData;
}

private static IEnumerable<string> GetPlaygroundAppHostAssemblyPaths()
{
// All the AppHost projects are referenced by this project so we can find them by looking for all their assemblies in the base directory
return Directory.GetFiles(AppContext.BaseDirectory, "*.AppHost.dll")
.Where(fileName => !fileName.EndsWith("Aspire.Hosting.AppHost.dll", StringComparison.OrdinalIgnoreCase));
}
}

public class TestEndpoints
Expand Down

0 comments on commit 2780cdc

Please sign in to comment.