Refactor: Web Consolidation and Identity Stabilization #40
Reference in New Issue
Block a user
Delete Branch "feature/issue-33"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Overview
This PR completes the architectural consolidation of the web project and stabilizes the Identity-based authentication flow for the NexusReader application. It also refines the UI aesthetic for the Book Ingestion Modal as requested in #33.
Key Changes
NexusReader.Web.NewintoNexusReader.Web. This includes updating all namespace references, VS Code launch/task configurations, and CI/CD (Dockerfile).IIdentityServiceon the server usingSignInManager<NexusUser>andUserManager<NexusUser>.SubscriptionPlanId,TenantId).Login.razorto force a page reload on successful login, ensuring proper synchronization of authentication cookies between SignalR and the browser.BookIngestionModalstyling to follow the Nexus Neon design system.Verification
dotnet build NexusReader.slnx --no-restoreFixes #33
NexusReader Code Review for PR #40
Overall Summary
Checklist Findings (based on
nexus-code-reviewstandards)AppDbContext,IHubContext). Use SignalR or API endpoints to route commands.Result<T>(FluentResults). I noticed a few async methods returning plainTask<T>without wrapping the outcome.async voidshould appear in production code. Replace withasync Taskand proper exception handling.UserIdentifierexplicitly rather than relying onIHttpContextAccessorinside handlers.IDisposable/IAsyncDisposable).Specific Recommendations
async voidlogin handlers withasync Task. Wrap the result inResultto follow the pattern.Result<T>and avoid throwing exceptions for expected flow.Please address the above items. Once updated, I can perform a follow‑up review.
Reviewed by NexusArchitect AI.
NexusReader Code Review for PR #40
Overall Summary
Checklist Findings (based on
nexus-code-reviewstandards)AppDbContext,IHubContext). Use SignalR or API endpoints to route commands.Result<T>(FluentResults). I noticed a few async methods returning plainTask<T>without wrapping the outcome.async voidshould appear in production code. Replace withasync Taskand proper exception handling.UserIdentifierexplicitly rather than relying onIHttpContextAccessorinside handlers.IDisposable/IAsyncDisposable).Specific Recommendations
async voidlogin handlers withasync Task. Wrap the result inResultto follow the pattern.Result<T>and avoid throwing exceptions for expected flow.Please address the above items. Once updated, I can perform a follow‑up review.
Reviewed by NexusArchitect AI.
Update: Architectural Stabilization Completed
The following architectural fixes have been implemented and verified:
INativeStorageServiceis now 100% async across all platforms (Web, WASM, MAUI). This ensures stable JS Interop in Blazor Server and prevents race conditions.ReaderNavigationServiceto eliminate fire-and-forget tasks. All navigation events and metadata updates are now properly awaited.IBillingServiceandKnowledgeCoordinatorto returnResult<T>, aligning with the project's Clean Architecture standards.These changes resolve the remaining stability concerns from the previous review.