Improve Boilerplate diagnostic utilities (#10001)#10009
Improve Boilerplate diagnostic utilities (#10001)#10009msynk merged 40 commits intobitfoundation:developfrom yasmoradi:10001
Conversation
Signed-off-by: Yaser Moradi <ysmoradi@outlook.com>
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the WalkthroughThis pull request updates both diagnostic and logging components. In the diagnostic modal, additional system namespaces are imported and the API call now collects and compiles diagnostic information using a StringBuilder, including error handling. In the logging handler, the HTTP version is captured conditionally and variable declarations were streamlined. Finally, the diagnostics controller now formats the HTTP headers output by inserting a new line and sorting them alphabetically. No exported or public entity declarations were altered. Changes
Sequence Diagram(s)sequenceDiagram
participant DM as Diagnostic Modal
participant DC as DiagnosticsController
DM->>DC: Call PerformDiagnostics API
DC-->>DM: Return diagnostics data (headers, statuses, etc.)
DM->>DM: Build detailed report (using StringBuilder) with environment & runtime data
DM->>User: Display report in message box
sequenceDiagram
participant Client as HTTP Client
participant Handler as LoggingDelegatingHandler
participant Service as HTTP Service
Client->>Handler: Send HTTP Request
Handler->>Service: Forward request (base.SendAsync)
Service-->>Handler: Return HTTP Response
Handler->>Handler: Capture and add HTTP version to log scope (if applicable)
Handler-->>Client: Return response with updated logging data
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
src/Templates/Boilerplate/Bit.Boilerplate/src/Client/Boilerplate.Client.Core/Components/Layout/DiagnosticModal.razor.cs(2 hunks)src/Templates/Boilerplate/Bit.Boilerplate/src/Client/Boilerplate.Client.Core/Services/HttpMessageHandlers/LoggingDelegatingHandler.cs(1 hunks)src/Templates/Boilerplate/Bit.Boilerplate/src/Server/Boilerplate.Server.Api/Controllers/Diagnostics/DiagnosticsController.cs(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: build and test
🔇 Additional comments (3)
src/Templates/Boilerplate/Bit.Boilerplate/src/Client/Boilerplate.Client.Core/Services/HttpMessageHandlers/LoggingDelegatingHandler.cs (1)
14-14: LGTM! Improved logging with conditional HTTP version tracking.The changes enhance logging by conditionally including HTTP version information for non-browser platforms while maintaining clean code structure.
Also applies to: 19-24
src/Templates/Boilerplate/Bit.Boilerplate/src/Server/Boilerplate.Server.Api/Controllers/Diagnostics/DiagnosticsController.cs (1)
67-69: LGTM! Enhanced header formatting for better readability.The changes improve the diagnostic output by:
- Adding visual separation before headers
- Sorting headers alphabetically for consistent presentation
src/Templates/Boilerplate/Bit.Boilerplate/src/Client/Boilerplate.Client.Core/Components/Layout/DiagnosticModal.razor.cs (1)
1-7: LGTM! Added necessary system namespaces.The additional namespaces support the enhanced diagnostic capabilities.
closes #10001
Summary by CodeRabbit