diff --git a/src/Aspire.Hosting/ApplicationModel/EndpointAnnotation.cs b/src/Aspire.Hosting/ApplicationModel/EndpointAnnotation.cs index 179f0e6e3e0..058acf53458 100644 --- a/src/Aspire.Hosting/ApplicationModel/EndpointAnnotation.cs +++ b/src/Aspire.Hosting/ApplicationModel/EndpointAnnotation.cs @@ -288,7 +288,7 @@ public bool TryAdd(NetworkIdentifier networkID, ValueSnapshot } /// - /// Adds and AllocatedEndpoint value associated with a specific network to the snapshot list. + /// Adds or updates an AllocatedEndpoint value associated with a specific network to the snapshot list. /// public void AddOrUpdateAllocatedEndpoint(NetworkIdentifier networkID, AllocatedEndpoint endpoint) { diff --git a/src/Aspire.Hosting/api/Aspire.Hosting.cs b/src/Aspire.Hosting/api/Aspire.Hosting.cs index e5b71318cee..fbca093d5cc 100644 --- a/src/Aspire.Hosting/api/Aspire.Hosting.cs +++ b/src/Aspire.Hosting/api/Aspire.Hosting.cs @@ -2604,10 +2604,15 @@ public partial record NetworkEndpointSnapshot(ValueSnapshot S public partial class NetworkEndpointSnapshotList : System.Collections.Generic.IEnumerable, System.Collections.IEnumerable { + public void AddOrUpdateAllocatedEndpoint(NetworkIdentifier networkID, AllocatedEndpoint endpoint) { } + + public System.Threading.Tasks.Task GetAllocatedEndpointAsync(NetworkIdentifier networkID, System.Threading.CancellationToken cancellationToken = default) { throw null; } + public System.Collections.Generic.IEnumerator GetEnumerator() { throw null; } System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + [System.Obsolete("This method is for internal use only and will be marked internal in a future Aspire release. Use AddOrUpdateAllocatedEndpoint instead.")] public bool TryAdd(NetworkIdentifier networkID, ValueSnapshot snapshot) { throw null; } }