Skip to content

Commit 4abc68c

Browse files
Copilotjaviercn
andcommitted
Restore ComponentServer's access to internal types in Components
Co-authored-by: javiercn <6995051+javiercn@users.noreply.github.com>
1 parent f0af6ba commit 4abc68c

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/Components/Components/src/Microsoft.AspNetCore.Components.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@
7979

8080
<ItemGroup>
8181
<InternalsVisibleTo Include="Microsoft.AspNetCore.Components.Web" />
82+
<InternalsVisibleTo Include="Microsoft.AspNetCore.Components.Server" />
8283
<InternalsVisibleTo Include="Microsoft.AspNetCore.Blazor.Build.Tests" />
8384
<InternalsVisibleTo Include="Microsoft.AspNetCore.Components.Authorization.Tests" />
8485
<InternalsVisibleTo Include="Microsoft.AspNetCore.Components.Forms.Tests" />

src/Components/Server/src/DependencyInjection/ComponentServiceCollectionExtensions.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
using Microsoft.AspNetCore.Components;
66
using Microsoft.AspNetCore.Components.Authorization;
77
using Microsoft.AspNetCore.Components.Forms;
8+
using Microsoft.AspNetCore.Components.Infrastructure;
89
using Microsoft.AspNetCore.Components.Routing;
910
using Microsoft.AspNetCore.Components.Server;
1011
using Microsoft.AspNetCore.Components.Server.BlazorPack;
@@ -64,7 +65,7 @@ public static IServerSideBlazorBuilder AddServerSideBlazor(this IServiceCollecti
6465
services.TryAddSingleton<CircuitMetrics>();
6566
services.TryAddSingleton<ICircuitFactory, CircuitFactory>();
6667
services.TryAddSingleton<ICircuitHandleRegistry, CircuitHandleRegistry>();
67-
services.TryAddSingleton<RootTypeCache>();
68+
services.TryAddSingleton<Microsoft.AspNetCore.Components.RootTypeCache>();
6869
services.TryAddSingleton<ComponentParameterDeserializer>();
6970
services.TryAddSingleton<ComponentParametersTypeCache>();
7071
services.TryAddSingleton<CircuitIdFactory>();
@@ -77,6 +78,9 @@ public static IServerSideBlazorBuilder AddServerSideBlazor(this IServiceCollecti
7778

7879
services.TryAddSingleton<CircuitRegistry>();
7980

81+
// Add ComponentsActivitySource for tracing
82+
ComponentsMetricsServiceCollectionExtensions.AddComponentsTracing(services);
83+
8084
// Standard blazor hosting services implementations
8185
//
8286
// These intentionally replace the non-interactive versions included in MVC.

0 commit comments

Comments
 (0)