Skip to content
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
35 changes: 33 additions & 2 deletions Microsoft.AspNetCore.SystemWebAdapters.sln
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.1.32127.271
# Visual Studio Version 18
VisualStudioVersion = 18.3.11122.13 main
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.SystemWebAdapters", "src\Microsoft.AspNetCore.SystemWebAdapters\Microsoft.AspNetCore.SystemWebAdapters.csproj", "{55C1BBE0-B922-46B0-8F2C-8472BC9A5F33}"
EndProject
Expand Down Expand Up @@ -124,6 +124,16 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AppConfigFramework", "sampl
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AppConfigCore", "samples\AppConfig\AppConfigCore\AppConfigCore.csproj", "{6ECA1F1C-214B-BB97-27D7-319C7F1AD90F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AspNetCore.SystemWebAdapters.Analyzers", "src\Microsoft.AspNetCore.SystemWebAdapters.Analyzers\Microsoft.AspNetCore.SystemWebAdapters.Analyzers.csproj", "{7A244BE9-B12E-424F-A1F1-E386C43BF0A9}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AspNetCore.SystemWebAdapters.Analyzers.CSharp", "src\Microsoft.AspNetCore.SystemWebAdapters.Analyzers.CSharp\Microsoft.AspNetCore.SystemWebAdapters.Analyzers.CSharp.csproj", "{904FF6F2-0322-9B85-7FBA-C512196D72C2}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "DependencyInjection", "DependencyInjection", "{BCEFA0EE-4AC7-417E-A861-368DB3D661B1}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DependencyInjectionAppHost", "samples\DependencyInjection\DependencyInjectionAppHost\DependencyInjectionAppHost.csproj", "{B447F0F6-B232-D326-334B-0095BA74F988}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DependencyInjectionFramework", "samples\DependencyInjection\DependencyInjectionFramework\DependencyInjectionFramework.csproj", "{4A2022AB-1ECE-E630-FD48-DD045DB4DD9F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -278,6 +288,22 @@ Global
{6ECA1F1C-214B-BB97-27D7-319C7F1AD90F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6ECA1F1C-214B-BB97-27D7-319C7F1AD90F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6ECA1F1C-214B-BB97-27D7-319C7F1AD90F}.Release|Any CPU.Build.0 = Release|Any CPU
{7A244BE9-B12E-424F-A1F1-E386C43BF0A9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7A244BE9-B12E-424F-A1F1-E386C43BF0A9}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7A244BE9-B12E-424F-A1F1-E386C43BF0A9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7A244BE9-B12E-424F-A1F1-E386C43BF0A9}.Release|Any CPU.Build.0 = Release|Any CPU
{904FF6F2-0322-9B85-7FBA-C512196D72C2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{904FF6F2-0322-9B85-7FBA-C512196D72C2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{904FF6F2-0322-9B85-7FBA-C512196D72C2}.Release|Any CPU.ActiveCfg = Release|Any CPU
{904FF6F2-0322-9B85-7FBA-C512196D72C2}.Release|Any CPU.Build.0 = Release|Any CPU
{B447F0F6-B232-D326-334B-0095BA74F988}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B447F0F6-B232-D326-334B-0095BA74F988}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B447F0F6-B232-D326-334B-0095BA74F988}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B447F0F6-B232-D326-334B-0095BA74F988}.Release|Any CPU.Build.0 = Release|Any CPU
{4A2022AB-1ECE-E630-FD48-DD045DB4DD9F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{4A2022AB-1ECE-E630-FD48-DD045DB4DD9F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4A2022AB-1ECE-E630-FD48-DD045DB4DD9F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4A2022AB-1ECE-E630-FD48-DD045DB4DD9F}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down Expand Up @@ -328,6 +354,11 @@ Global
{16A9239C-ADC1-B9FA-8C50-081E2A420B5B} = {012BEA62-0FF1-472E-AD5F-0D2029336701}
{90FE21BE-F292-A973-D281-9D4DC81CEB6F} = {012BEA62-0FF1-472E-AD5F-0D2029336701}
{6ECA1F1C-214B-BB97-27D7-319C7F1AD90F} = {012BEA62-0FF1-472E-AD5F-0D2029336701}
{7A244BE9-B12E-424F-A1F1-E386C43BF0A9} = {F9DB9323-C919-49E8-8F96-B923D2F42E60}
{904FF6F2-0322-9B85-7FBA-C512196D72C2} = {F9DB9323-C919-49E8-8F96-B923D2F42E60}
{BCEFA0EE-4AC7-417E-A861-368DB3D661B1} = {95915611-30BF-4AFF-AE41-5CDC6F57DCF7}
{B447F0F6-B232-D326-334B-0095BA74F988} = {BCEFA0EE-4AC7-417E-A861-368DB3D661B1}
{4A2022AB-1ECE-E630-FD48-DD045DB4DD9F} = {BCEFA0EE-4AC7-417E-A861-368DB3D661B1}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {DABA3C65-9D74-4EB6-9B1C-730328710EAD}
Expand Down
4 changes: 2 additions & 2 deletions samples/AppConfig/AppConfigAppHost/AppConfigAppHost.csproj
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<Sdk Name="Aspire.AppHost.Sdk" />

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net10.0-windows</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)-windows</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsAspireHost>true</IsAspireHost>
Expand Down
6 changes: 3 additions & 3 deletions samples/AppConfig/AppConfigCore/AppConfigCore.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
Expand All @@ -15,4 +15,4 @@
<ItemGroup>
<ProjectReference Include="..\..\ServiceDefaults\Samples.ServiceDefaults.csproj" />
</ItemGroup>
</Project>
</Project>
2 changes: 0 additions & 2 deletions samples/AppConfig/AppConfigCore/Program.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using Microsoft.AspNetCore.Http.Features;
using Microsoft.AspNetCore.SystemWebAdapters;
using Microsoft.AspNetCore.SystemWebAdapters.Features;

var builder = WebApplication.CreateBuilder(args);

Expand Down
2 changes: 1 addition & 1 deletion samples/AppConfig/AppConfigFramework/Global.asax.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ protected void Application_Start()
HttpApplicationHost.RegisterHost(builder =>
{
builder.AddServiceDefaults();
builder.RegisterWebObjectActivator();
builder.AddSystemWebDependencyInjection();
});
}
}
Expand Down
10 changes: 8 additions & 2 deletions samples/AppConfig/AppConfigFramework/Web.config
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<connectionStrings>
<add name="ConnStr1" connectionString="web.config" />
<add name="ConnStr2" connectionString="web.config" />
</connectionStrings>
<appSettings>
<add key="Setting1" value="web.config" />
<add key="Setting2" value="web.config"/>
<add key="Setting2" value="web.config" />
</appSettings>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true">
Expand Down Expand Up @@ -154,4 +154,10 @@
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" compilerOptions="/langversion:default /nowarn:1659;1699;1701;612;618" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" warningLevel="4" compilerOptions="/langversion:default /nowarn:41008,40000,40008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</compilers>
</system.codedom>
</configuration>
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<Sdk Name="Aspire.AppHost.Sdk" />

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net10.0-windows</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)-windows</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsAspireHost>true</IsAspireHost>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\..\ServiceDefaults\Samples.ServiceDefaults.csproj" />
</ItemGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ protected void Application_Start()
HttpApplicationHost.RegisterHost(builder =>
{
builder.AddServiceDefaults();
builder.RegisterWebObjectActivator();
builder.AddSystemWebDependencyInjection();

builder.AddSystemWebAdapters()
.AddVirtualizedContentDirectories();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<configSections>
<section name="configBuilders" type="System.Configuration.ConfigurationBuildersSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" restartOnExternalChanges="false" requirePermission="false" />
Expand Down Expand Up @@ -189,4 +189,10 @@
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" compilerOptions="/langversion:default /nowarn:1659;1699;1701;612;618" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" warningLevel="4" compilerOptions="/langversion:default /nowarn:41008,40000,40008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</compilers>
</system.codedom>
</configuration>
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<Sdk Name="Aspire.AppHost.Sdk" />

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net10.0-windows</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)-windows</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsAspireHost>true</IsAspireHost>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\..\ServiceDefaults\Samples.ServiceDefaults.csproj" />
</ItemGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
<Project Sdk="MSBuild.SDK.SystemWeb">
<PropertyGroup>
<TargetFramework>net481</TargetFramework>

<!-- To validate that the code generation for DI will be compatible with the latest supported version -->
<LangVersion>7.3</LangVersion>
<Nullable>disable</Nullable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Antlr" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
using System.Configuration;
using System.Web;
using System.Web.Http;
using System.Web.Mvc;
using System.Web.Optimization;
using System.Web.Routing;
using Microsoft.AspNetCore.SystemWebAdapters.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.Hosting;

namespace MvcApp
Expand All @@ -17,7 +15,7 @@ protected void Application_Start()
HttpApplicationHost.RegisterHost(builder =>
{
builder.AddServiceDefaults();
builder.RegisterWebObjectActivator();
builder.AddSystemWebDependencyInjection();

builder.AddSystemWebAdapters()
.AddVirtualizedContentDirectories();
Expand All @@ -31,3 +29,4 @@ protected void Application_Start()
}
}
}

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<!--
For more information on how to configure your ASP.NET application, please visit
https://go.microsoft.com/fwlink/?LinkId=301880
Expand Down Expand Up @@ -254,4 +254,10 @@
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" compilerOptions="/langversion:default /nowarn:1659;1699;1701;612;618" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" warningLevel="4" compilerOptions="/langversion:default /nowarn:41008,40000,40008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</compilers>
</system.codedom>
</configuration>
6 changes: 3 additions & 3 deletions samples/AuthWindows/AuthWindowsCore/AuthWindowsCore.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>$(SAMPLES_TFM)</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
Expand All @@ -10,4 +10,4 @@
<ItemGroup>
<ProjectReference Include="..\..\ServiceDefaults\Samples.ServiceDefaults.csproj" />
</ItemGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<Project Sdk="Microsoft.NET.Sdk">

<Sdk Name="Aspire.AppHost.Sdk" />

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>$(SAMPLES_TFM)-windows</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsAspireHost>true</IsAspireHost>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Aspire.Hosting.AppHost" />
<PackageReference Include="Aspire.Hosting.SqlServer" />
<PackageReference Include="C3D.Extensions.Aspire.IISExpress" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\..\..\src\Aspire.Hosting.IncrementalMigration\Aspire.Hosting.IncrementalMigration.csproj" IsAspireProjectResource="false" />
<ProjectReference Include="..\DependencyInjectionFramework\DependencyInjectionFramework.csproj" />

</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
var builder = DistributedApplication.CreateBuilder(args);

var frameworkApp = builder.AddIISExpress("iis")
.AddSiteProject<Projects.DependencyInjectionFramework>("framework")
.WithDefaultIISExpressEndpoints()
.WithOtlpExporter()
.WithHttpHealthCheck("/health");

builder.Build().Run();
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"$schema": "https://json.schemastore.org/launchsettings.json",
"profiles": {
"https": {
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": true,
"applicationUrl": "https://localhost:17095;http://localhost:15283",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development",
"DOTNET_ENVIRONMENT": "Development",
"ASPIRE_DASHBOARD_OTLP_HTTP_ENDPOINT_URL": "https://localhost:21002",
"DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "https://localhost:22119"
}
},
"http": {
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": true,
"applicationUrl": "http://localhost:15283",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development",
"DOTNET_ENVIRONMENT": "Development",
"ASPIRE_DASHBOARD_OTLP_HTTP_ENDPOINT_URL": "http://localhost:19075",
"DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "http://localhost:20035"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning",
"Aspire.Hosting.Dcp": "Warning"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
using System.Web.Mvc;

namespace MvcApp
{
public class FilterConfig
{
public static void RegisterGlobalFilters(GlobalFilterCollection filters)
{
filters.Add(new HandleErrorAttribute());
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
using System.Web.Mvc;
using System.Web.Routing;

namespace MvcApp
{
public class RouteConfig
{
public static void RegisterRoutes(RouteCollection routes)
{
// routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
// routes.IgnoreRoute("handler");
routes.MapMvcAttributeRoutes();
}
}
}
Loading