Skip to content

[Automated] Update API Surface Area#17700

Merged
joperezr merged 1 commit into
release/13.4from
update-api-diffs
Jun 1, 2026
Merged

[Automated] Update API Surface Area#17700
joperezr merged 1 commit into
release/13.4from
update-api-diffs

Conversation

@aspire-repo-bot
Copy link
Copy Markdown
Contributor

Auto-generated update to the API surface to compare current surface vs latest release. This should only be merged once this surface area ships in a new release.

Copilot AI review requested due to automatic review settings May 29, 2026 22:12
@aspire-repo-bot aspire-repo-bot Bot requested a review from JamesNK as a code owner May 29, 2026 22:12
@aspire-repo-bot aspire-repo-bot Bot added the NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) label May 29, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@github-actions
Copy link
Copy Markdown
Contributor

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 17700

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 17700"

Copy link
Copy Markdown
Member

@joperezr joperezr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API review for the 13.4 surface — questions / suggestions inline. Findings on APIs already marked [Experimental] were de-prioritized.

Comment thread src/Aspire.Hosting/api/Aspire.Hosting.cs

[AspireExport]
public static ApplicationModel.IResourceBuilder<T> WithEndpoint<T>(this ApplicationModel.IResourceBuilder<T> builder, int? port = null, int? targetPort = null, string? scheme = null, string? name = null, string? env = null, bool? isProxied = null, bool? isExternal = null, System.Net.Sockets.ProtocolType? protocol = null)
where T : ApplicationModel.IResourceWithEndpoints { throw null; }
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default for isProxied changed from true to null. Is that intentional? A binary-compat shim is added, but source callers relying on the implicit true will silently get the new default — worth a release-note callout if the runtime semantics differ.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is! @danegsta

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, we intentionally kept binary compatibility (with the old default) if you built against an old Aspire.Hosting, while changing the defaults going forward when building against 13.4 and later. Seemed like the best trade-off.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not addressed in the fix PR — flagging for the owner to confirm whether the default change to null is intentional.


[AspireExport]
public static ApplicationModel.IResourceBuilder<T> WithHttpEndpoint<T>(this ApplicationModel.IResourceBuilder<T> builder, int? port = null, int? targetPort = null, string? name = null, string? env = null, bool? isProxied = null)
where T : ApplicationModel.IResourceWithEndpoints { throw null; }
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same isProxied default change here (truenull) — intentional?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, it's so that going forward we can differentiate between explicitly true and default. Allows us to disable proxies for persistent resources by default (assuming the integration is built against Aspire.Hosting 13.4).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above — not addressed in the fix PR; owner should confirm intent.

Comment thread src/Aspire.Hosting/api/Aspire.Hosting.cs
Comment thread src/Aspire.Hosting/api/Aspire.Hosting.cs
Comment thread src/Aspire.Hosting.Kubernetes/api/Aspire.Hosting.Kubernetes.cs
}

public enum GatewayPathMatchType
{
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Heads-up: GatewayPathMatchType.PathPrefix vs IngressPathType.Prefix (line ~283 below) name the same concept differently. Worth aligning unless we're deliberately mirroring the K8s Gateway / Ingress spec naming.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not addressed in the fix PR — naming consistency question deferred to the owner.

Comment thread src/Aspire.Hosting.Blazor/api/Aspire.Hosting.Blazor.cs Outdated
Comment thread src/Aspire.Hosting.Azure/api/Aspire.Hosting.Azure.cs
Comment thread src/Aspire.Hosting.JavaScript/api/Aspire.Hosting.JavaScript.cs
@joperezr joperezr marked this pull request as draft May 29, 2026 22:55
@github-actions github-actions Bot force-pushed the update-api-diffs branch from 38f05e4 to d837395 Compare May 30, 2026 16:50
joperezr added a commit that referenced this pull request May 30, 2026
* API review fixes for 13.4 (PR #17700)

Addresses several issues found during API surface review:

1. Rename NetworkID -> NetworkId (and networkID -> networkId) on
   AllocatedEndpoint, EndpointAnnotation, EndpointReference,
   EndpointReferenceAnnotation, NetworkEndpointSnapshot,
   NetworkEndpointSnapshotList, and related methods/parameters.
2. Add [Experimental("ASPIREAZURE003")] to AzureRoleAssignmentResource.
3. Change EndpointReferenceAnnotation.EndpointNames from HashSet<string>
   to ISet<string> (backing field stays HashSet).
4. Add 'sealed' to new public resource classes that are not subclassed
   in the repo: KubernetesHelmChartResource, BlazorWasmAppResource,
   BunAppResource, NextJsAppResource, ViteAppResource,
   AzureNatGatewayResource, AzureNetworkSecurityGroupResource,
   AzureNetworkSecurityPerimeterResource, AzurePrivateEndpointResource,
   AzurePublicIPAddressResource, AzureSubnetResource,
   AzureVirtualNetworkResource. (GoAppResource and NodeAppResource left
   non-sealed because they are used as generic type constraints in the
   same assembly.)
5. Disambiguate WithHiddenOnCompletion overloads by removing the
   '= 0' default from the int overload, so calls with no argument
   resolve to the params overload.

api/*.cs and api/*.ats.txt are intentionally not updated here - the API
surface PR will regenerate them.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Revert breaking API changes; bump baseline to 13.3.5

Reverts the subset of API changes from the previous commit that would be
binary-breaking against 13.3.5, and bumps PackageValidationBaselineVersion
from 13.2.2 to 13.3.5 so pack validation runs against the latest shipped
release.

Reverts (binary-breaking against 13.3.5):
- AllocatedEndpoint.NetworkID (kept ctor param 'networkId' - not breaking)
- EndpointAnnotation.DefaultNetworkID (kept ctor param 'networkId')
- EndpointReference.ContextNetworkID (kept ctor param 'contextNetworkId')
- NetworkEndpointSnapshot.NetworkID record positional param
- Removed 'sealed' from 9 shipped resource classes:
  - NextJsAppResource, ViteAppResource
  - AzureNatGatewayResource, AzureNetworkSecurityGroupResource,
    AzureNetworkSecurityPerimeterResource, AzurePrivateEndpointResource,
    AzurePublicIPAddressResource, AzureSubnetResource, AzureVirtualNetworkResource

Kept (not binary-breaking):
- All constructor/method parameter renames (networkID->networkId, etc.)
- EndpointReferenceAnnotation.ContextNetworkId (new in 13.4)
- EndpointNames type change (HashSet -> ISet)
- WithHiddenOnCompletion overload disambiguation
- [Experimental("ASPIREAZURE003")] on AzureRoleAssignmentResource
- 'sealed' on KubernetesHelmChartResource, BlazorWasmAppResource, BunAppResource (new in 13.4)

Package validation:
- Bumped PackageValidationBaselineVersion 13.2.2 -> 13.3.5
- Regenerated CompatibilitySuppressions.xml in 4 projects: most legacy
  entries against 13.2.2 are no longer needed because those APIs already
  shipped in 13.3.x. The remaining suppression is PublishAsNpmScript in
  Aspire.Hosting.JavaScript (documented removal from PR #17382).

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions github-actions Bot force-pushed the update-api-diffs branch from d837395 to 86ec705 Compare May 31, 2026 16:54
@github-actions github-actions Bot force-pushed the update-api-diffs branch from 86ec705 to 4596801 Compare June 1, 2026 18:30
@joperezr joperezr marked this pull request as ready for review June 1, 2026 23:18
Copy link
Copy Markdown
Member

@joperezr joperezr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

13.4.0 shipped today. This is good to go.

@joperezr joperezr merged commit 3cbbeb2 into release/13.4 Jun 1, 2026
1 check passed
@joperezr joperezr deleted the update-api-diffs branch June 1, 2026 23:20
@microsoft-github-policy-service microsoft-github-policy-service Bot added this to the 13.4 milestone Jun 1, 2026
@github-actions github-actions Bot modified the milestones: 13.4, 13.4.x Jun 1, 2026
aspire-repo-bot Bot added a commit to microsoft/aspire.dev that referenced this pull request Jun 1, 2026
…Script support

- Update bun-apps.mdx to reference Aspire.Hosting.JavaScript (BunAppResource)
  instead of the deprecated CommunityToolkit.Aspire.Hosting.Bun package
- Add TypeScript AppHost examples alongside C# examples
- Add BunAppResource to the resource types list in javascript.mdx

Documents API surface changes from microsoft/aspire#17700

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@aspire-repo-bot
Copy link
Copy Markdown
Contributor Author

Pull request created: #1153

Generated by PR Documentation Check

@aspire-repo-bot
Copy link
Copy Markdown
Contributor Author

📝 Documentation has been drafted in microsoft/aspire.dev#1153 targeting release/13.4.

Updated bun-apps.mdx to reflect that BunAppResource is now a first-party type in Aspire.Hosting.JavaScript (no longer Community Toolkit), with TypeScript examples added. Added BunAppResource to the resource-type list in javascript.mdx.

Files modified:

  • src/frontend/src/content/docs/integrations/frameworks/bun-apps.mdx
  • src/frontend/src/content/docs/integrations/frameworks/javascript.mdx

Note

This draft PR needs human review before merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants