From 261fc69ef865e93a095f861fb16a60b50ba02eb6 Mon Sep 17 00:00:00 2001 From: tommasodotnet Date: Tue, 10 Feb 2026 14:20:09 +0100 Subject: [PATCH] Refactor project files to use TargetFrameworks instead of TargetFramework for multi-targeting support; add optional port property to DevUIResource class. --- .../Aspire.Hosting.AgentFramework.DevUI/DevUIResource.cs | 6 ++++++ .../DevUIIntegration.AppHost.csproj | 2 +- .../DevUIIntegration.ServiceDefaults.csproj | 3 +-- .../samples/DevUIIntegration/EditorAgent/EditorAgent.csproj | 3 +-- .../samples/DevUIIntegration/WriterAgent/WriterAgent.csproj | 3 +-- .../Aspire.Hosting.AgentFramework.DevUI.UnitTests.csproj | 2 +- 6 files changed, 11 insertions(+), 8 deletions(-) diff --git a/dotnet/aspire-integration/Aspire.Hosting.AgentFramework.DevUI/DevUIResource.cs b/dotnet/aspire-integration/Aspire.Hosting.AgentFramework.DevUI/DevUIResource.cs index 1af2f5a1a0..9cf85dff07 100644 --- a/dotnet/aspire-integration/Aspire.Hosting.AgentFramework.DevUI/DevUIResource.cs +++ b/dotnet/aspire-integration/Aspire.Hosting.AgentFramework.DevUI/DevUIResource.cs @@ -25,6 +25,7 @@ public class DevUIResource(string name) : Resource(name), IResourceWithEndpoints /// An optional fixed port. If null, a dynamic port is assigned. internal DevUIResource(string name, int? port) : this(name) { + this.Port = port; this.Annotations.Add(new EndpointAnnotation( ProtocolType.Tcp, uriScheme: "http", @@ -36,6 +37,11 @@ public class DevUIResource(string name) : Resource(name), IResourceWithEndpoints }); } + /// + /// Gets the optional fixed port for the DevUI web interface. + /// + internal int? Port { get; } + /// /// Gets the primary HTTP endpoint for the DevUI web interface. /// diff --git a/dotnet/samples/DevUIIntegration/DevUIIntegration.AppHost/DevUIIntegration.AppHost.csproj b/dotnet/samples/DevUIIntegration/DevUIIntegration.AppHost/DevUIIntegration.AppHost.csproj index b0b9fb4fc3..b060a2860e 100644 --- a/dotnet/samples/DevUIIntegration/DevUIIntegration.AppHost/DevUIIntegration.AppHost.csproj +++ b/dotnet/samples/DevUIIntegration/DevUIIntegration.AppHost/DevUIIntegration.AppHost.csproj @@ -4,7 +4,7 @@ Exe - net10.0 + net10.0 enable enable diff --git a/dotnet/samples/DevUIIntegration/DevUIIntegration.ServiceDefaults/DevUIIntegration.ServiceDefaults.csproj b/dotnet/samples/DevUIIntegration/DevUIIntegration.ServiceDefaults/DevUIIntegration.ServiceDefaults.csproj index 0ba7cf1e7d..0c5573beac 100644 --- a/dotnet/samples/DevUIIntegration/DevUIIntegration.ServiceDefaults/DevUIIntegration.ServiceDefaults.csproj +++ b/dotnet/samples/DevUIIntegration/DevUIIntegration.ServiceDefaults/DevUIIntegration.ServiceDefaults.csproj @@ -1,8 +1,7 @@ - net10.0 - + net10.0 enable enable true diff --git a/dotnet/samples/DevUIIntegration/EditorAgent/EditorAgent.csproj b/dotnet/samples/DevUIIntegration/EditorAgent/EditorAgent.csproj index ed726520a3..ace52399c5 100644 --- a/dotnet/samples/DevUIIntegration/EditorAgent/EditorAgent.csproj +++ b/dotnet/samples/DevUIIntegration/EditorAgent/EditorAgent.csproj @@ -1,8 +1,7 @@ - net10.0 - + net10.0 enable enable b2c3d4e5-f6a7-8901-bcde-f12345678901 diff --git a/dotnet/samples/DevUIIntegration/WriterAgent/WriterAgent.csproj b/dotnet/samples/DevUIIntegration/WriterAgent/WriterAgent.csproj index f149138ce0..e596b972fe 100644 --- a/dotnet/samples/DevUIIntegration/WriterAgent/WriterAgent.csproj +++ b/dotnet/samples/DevUIIntegration/WriterAgent/WriterAgent.csproj @@ -1,8 +1,7 @@ - net10.0 - + net10.0 enable enable a1b2c3d4-e5f6-7890-abcd-ef1234567890 diff --git a/dotnet/tests/Aspire.Hosting.AgentFramework.DevUI.UnitTests/Aspire.Hosting.AgentFramework.DevUI.UnitTests.csproj b/dotnet/tests/Aspire.Hosting.AgentFramework.DevUI.UnitTests/Aspire.Hosting.AgentFramework.DevUI.UnitTests.csproj index 84b1dfd9c8..9c1036160c 100644 --- a/dotnet/tests/Aspire.Hosting.AgentFramework.DevUI.UnitTests/Aspire.Hosting.AgentFramework.DevUI.UnitTests.csproj +++ b/dotnet/tests/Aspire.Hosting.AgentFramework.DevUI.UnitTests/Aspire.Hosting.AgentFramework.DevUI.UnitTests.csproj @@ -1,7 +1,7 @@ - net10.0 + net10.0