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

[Feat] .NET9 Support #774

Merged
merged 49 commits into from
Nov 13, 2024
Merged
Changes from 2 commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
60c5d81
migration to dotnet 9 rc.2
neozhu Oct 9, 2024
7666415
fix workflows
neozhu Oct 9, 2024
9020405
Update Domain.csproj
neozhu Oct 9, 2024
c8f88f5
Update dotnet.yml
neozhu Oct 9, 2024
1dbf7e7
commit
neozhu Oct 10, 2024
f592b62
Merge branch 'main' into dotnet9rc2
neozhu Oct 10, 2024
b8b732e
Updated: Development Requirements in the README
Bram1903 Oct 11, 2024
85f36d7
Merge branch 'main' into dotnet9rc2
neozhu Oct 11, 2024
2b0302f
Merge branch 'main' into dotnet9rc2
Bram1903 Oct 17, 2024
e0f8a8a
Updated: Dependencies
Bram1903 Oct 17, 2024
2122764
Merge branch 'main' into dotnet9rc2
neozhu Oct 19, 2024
751f7f6
merge from main
neozhu Oct 19, 2024
e89773a
Merge branch 'main' into dotnet9rc2
neozhu Oct 19, 2024
8c42aec
Merge branch 'main' into dotnet9rc2
neozhu Oct 20, 2024
2f3359a
Merge branch 'main' into dotnet9rc2
Bram1903 Oct 28, 2024
fdb93f0
Fixed: Merge Issue
Bram1903 Oct 28, 2024
bb0635d
Fixed: Build Error
Bram1903 Oct 28, 2024
fe3402d
Fixed: MudBlazor v8.0.0-preview.2 compatibility
Bram1903 Oct 28, 2024
ea3f11e
Merge branch 'main' into dotnet9rc2
neozhu Nov 1, 2024
ae92c20
clear
neozhu Nov 1, 2024
d00b4f4
Merge branch 'main' into dotnet9rc2
neozhu Nov 1, 2024
cf7bd6a
Merge branch 'main' into dotnet9rc2
neozhu Nov 2, 2024
40e617d
Merge branch 'main' into dotnet9rc2
neozhu Nov 3, 2024
b3e4d85
Merge branch 'main' into dotnet9rc2
neozhu Nov 3, 2024
c4e2de9
add blazor-error-boundary
neozhu Nov 4, 2024
eb95f34
Merge branch 'main' into dotnet9rc2
neozhu Nov 6, 2024
b5dcd53
migration
neozhu Nov 6, 2024
e15e36f
Merge branch 'dotnet9rc2' of https://github.com/neozhu/CleanArchitect…
neozhu Nov 6, 2024
edf2552
Merge branch 'main' into dotnet9rc2
neozhu Nov 8, 2024
ab04c6e
Merge branch 'main' into dotnet9rc2
neozhu Nov 9, 2024
8d668ea
Update Application.csproj
neozhu Nov 9, 2024
5612cf4
"TargetFramework": "net9"
neozhu Nov 9, 2024
69cafa9
fixed input font-size
neozhu Nov 9, 2024
ac90f37
Update SerilogExtensions.cs
neozhu Nov 9, 2024
a24d9b0
Update UserSessionCircuitHandler.cs
neozhu Nov 9, 2024
1f5df04
Update SerilogExtensions.cs
neozhu Nov 9, 2024
fdac12f
Update Infrastructure.csproj
neozhu Nov 10, 2024
a48285d
Update DependencyInjection.cs
neozhu Nov 10, 2024
278b6dc
clean
neozhu Nov 11, 2024
1fb4910
remove LazyCache replace with FusionCache
neozhu Nov 11, 2024
a7789ee
Update Application.csproj
neozhu Nov 11, 2024
f0a1a64
recreate migration for SQLite
neozhu Nov 11, 2024
baf732b
fix
neozhu Nov 11, 2024
9275e50
Update Logs.razor
neozhu Nov 11, 2024
b5611d4
Circuit handler to capture users
neozhu Nov 12, 2024
d7c64b1
clear code
neozhu Nov 12, 2024
54a3e58
test code generate
neozhu Nov 12, 2024
789d6b7
@Assets
neozhu Nov 12, 2024
0a9662e
upgrade to dotnet 9
neozhu Nov 12, 2024
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
1 change: 1 addition & 0 deletions src/Server.UI/Components/App.razor
Original file line number Diff line number Diff line change
@@ -9,6 +9,7 @@
<link href="_content/MudBlazor/MudBlazor.min.css" rel="stylesheet"/>
<link href="css/app.css" rel="stylesheet"/>
<HeadOutlet @rendermode="RenderModeForPage"/>
<ImportMap />
<!-- SEO Meta Tags -->
<meta name="description" content="Blazor Server project template with Clean Architecture principles. A demo showcasing fast and easy web app creation using .NET Blazor." />
<meta name="keywords" content="Blazor Server Project Template, Clean Architecture, Demo, .NET, Web Applications" />
45 changes: 12 additions & 33 deletions src/Server.UI/wwwroot/css/app.css
Original file line number Diff line number Diff line change
@@ -59,38 +59,6 @@
padding-bottom:2px;
}

#blazor-error-ui {
background: lightyellow;
background-color: var(--mud-palette-error);
color: var(--mud-palette-error-text);
bottom: 0;
box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
display: none;
left: 0;
padding: 0.6rem 1.25rem 0.7rem 1.25rem;
padding: 0.6rem 1.75rem 0.7rem 1.25rem;
position: fixed;
width: 100%;
z-index: 9999;
}

#reconnect-modal {
background: lightyellow;
background-color: var(--mud-palette-warning-hover);
color: var(--mud-palette-warning-darken);
top: 0;
box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
display: none;
left: 0;
padding: 0.6rem 1.25rem 0.7rem 1.25rem;
padding: 0.6rem 1.75rem 0.7rem 1.25rem;
margin: 0px;
position: fixed;
width: 100%;
z-index: 9999;
}


.mud-nav-link {
white-space: normal !important;
}
@@ -103,4 +71,15 @@
.side-menu .mud-chip.mud-chip-size-small {
font-size: 0.625rem;
height: 1.125rem;
}
}


.blazor-error-boundary {
background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtc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ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
padding: 1rem 1rem 1rem 3.7rem;
color: white;
}

.blazor-error-boundary::after {
content: "An error has occurred."
}

Unchanged files with check annotations Beta

ImmutableInterlocked.AddOrUpdate(
ref _pageUserSessions,

Check warning on line 35 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / build

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile

Check warning on line 35 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / Analyze

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile
pageComponent,
ImmutableHashSet.Create(sessionInfo),
(key, existingSessions) => existingSessions.Add(sessionInfo));
// Use atomic update to prevent concurrency issues
if (updatedUsers.IsEmpty)
{
ImmutableInterlocked.TryRemove(ref _pageUserSessions, pageComponent, out _);

Check warning on line 79 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / build

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile

Check warning on line 79 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / Analyze

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile
}
else
{
ImmutableInterlocked.AddOrUpdate(
ref _pageUserSessions,

Check warning on line 84 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / build

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile

Check warning on line 84 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / Analyze

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile
pageComponent,
updatedUsers,
(key, existingUsers) => updatedUsers);
// Use atomic update to prevent concurrency issues
if (updatedUsers.IsEmpty)
{
ImmutableInterlocked.TryRemove(ref _pageUserSessions, pageComponent, out _);

Check warning on line 113 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / build

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile

Check warning on line 113 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / Analyze

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile
}
else
{
ImmutableInterlocked.AddOrUpdate(
ref _pageUserSessions,

Check warning on line 118 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / build

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile

Check warning on line 118 in src/Application/Features/Fusion/UserSessionTracker.cs

GitHub Actions / Analyze

'UserSessionTracker._pageUserSessions': a reference to a volatile field will not be treated as volatile
pageComponent,
updatedUsers,
(key, existingUsers) => updatedUsers);
{
var sessionInfo = new SessionInfo
(
context.User.GetUserId(),

Check warning on line 43 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / build

Possible null reference argument for parameter 'UserId' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.

Check warning on line 43 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / Analyze

Possible null reference argument for parameter 'UserId' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.
context.User.GetUserName(),

Check warning on line 44 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / build

Possible null reference argument for parameter 'UserName' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.

Check warning on line 44 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / Analyze

Possible null reference argument for parameter 'UserName' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.
context.User.GetDisplayName(),

Check warning on line 45 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / build

Possible null reference argument for parameter 'DisplayName' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.

Check warning on line 45 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / Analyze

Possible null reference argument for parameter 'DisplayName' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.
context.Connection.RemoteIpAddress?.ToString(),

Check warning on line 46 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / build

Possible null reference argument for parameter 'IPAddress' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.

Check warning on line 46 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / Analyze

Possible null reference argument for parameter 'IPAddress' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.
context.User.GetTenantId(),

Check warning on line 47 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / build

Possible null reference argument for parameter 'TenantId' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.

Check warning on line 47 in src/Infrastructure/Services/Circuits/UserSessionCircuitHandler.cs

GitHub Actions / Analyze

Possible null reference argument for parameter 'TenantId' in 'SessionInfo.SessionInfo(string UserId, string UserName, string DisplayName, string IPAddress, string TenantId, string ProfilePictureDataUrl, UserPresence Status)'.
context.User.GetProfilePictureDataUrl(),
UserPresence.Available
);