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

Mark AzurePublisherOptions as Experimental #8240

Merged
merged 1 commit into from
Mar 22, 2025
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
4 changes: 3 additions & 1 deletion src/Aspire.Hosting.Azure/AzurePublisher.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System.Diagnostics.CodeAnalysis;
using Aspire.Hosting.ApplicationModel;
using Aspire.Hosting.Publishing;
using Azure.Provisioning;
Expand All @@ -13,6 +14,7 @@

namespace Aspire.Hosting.Azure;

[Experimental("ASPIREAZURE001", UrlFormat = "https://aka.ms/dotnet/aspire/diagnostics#{0}")]
Copy link
Member

Choose a reason for hiding this comment

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

I know this is just following precedent of other experimental attributes, but in hindsight, I wonder if it would've been better to just have these attributes be all ASPIRE0xxx and just increment the number. That seems to be the pattern that some of the other repos using experimental do anyway.

Copy link
Member Author

@eerhardt eerhardt Mar 21, 2025

Choose a reason for hiding this comment

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

@mitchdenny - thoughts on this? I think you set the precedent as you were the first to make experimental APIs.

See Uses new Azure.Provisioning packages which have been split by resource (dotnet/aspire#3383)

9f499db

internal sealed class AzurePublisher(
[ServiceKey] string name,
IOptionsMonitor<AzurePublisherOptions> options,
Expand Down Expand Up @@ -287,4 +289,4 @@ private void SaveToDisk(string outputDirectoryPath, Infrastructure infrastructur
var bicepPath = Path.Combine(outputDirectoryPath, $"{infrastructure.BicepName}.bicep");
File.WriteAllText(bicepPath, compiledBicep.Value);
}
}
}
4 changes: 3 additions & 1 deletion src/Aspire.Hosting.Azure/AzurePublisherOptions.cs
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System.Diagnostics.CodeAnalysis;
using Aspire.Hosting.Publishing;

namespace Aspire.Hosting.Azure;

/// <summary>
/// Options which control generation of artifacts for deploying to Azure.
/// </summary>
[Experimental("ASPIREAZURE001", UrlFormat = "https://aka.ms/dotnet/aspire/diagnostics#{0}")]
public sealed class AzurePublisherOptions : PublishingOptions
{
}
}
2 changes: 2 additions & 0 deletions tests/Aspire.Hosting.Azure.Tests/AzurePublisherTests.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

#pragma warning disable ASPIREAZURE001 // Type is for evaluation purposes only and is subject to change or removal in future updates. Suppress this diagnostic to proceed.

using System.Runtime.CompilerServices;
using Aspire.Hosting.ApplicationModel;
using Aspire.Hosting.Utils;
Expand Down