Reviewing ASP.NET Core hosting gap analysis documentation - #841
Merged
AndreaCuneo merged 2 commits intoAug 5, 2026
Merged
Conversation
Co-authored-by: AndreaCuneo <5227688+AndreaCuneo@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
AndreaCuneo
August 5, 2026 05:14
View session
AndreaCuneo
requested changes
Aug 5, 2026
Co-authored-by: AndreaCuneo <5227688+AndreaCuneo@users.noreply.github.com>
Copilot stopped work on behalf of
AndreaCuneo due to an error
August 5, 2026 05:30
AndreaCuneo
marked this pull request as ready for review
August 5, 2026 05:35
AndreaCuneo
approved these changes
Aug 5, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
Enables Brotli/Gzip response compression over HTTPS by default for the Ark minimal API host, and updates the mediator framework task documentation/tests to reflect the current stance on streaming + compression.
Changes:
- Register
AddResponseCompression(Brotli + Gzip, HTTPS enabled) inAddArkMinimalApiHost. - Add
UseResponseCompressionto the minimal API host middleware pipeline. - Update generator snapshot assertions and the task/acceptance documentation for response compression.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| tests/Ark.Tools.MediatorFramework.Tests/GeneratorSnapshotTests.cs | Updates snapshot expectations for async-enumerable generator output (now asserts no DisableResponseCompression). |
| src/aspnetcore/Ark.Tools.AspNetCore.MinimalApi/ArkMinimalApiHostExtensions.cs | Adds response compression registration + middleware to minimal API hosting defaults. |
| docs/mediator-framework/progress/tasks/aspnetcore/HST-05-response-compression.md | Updates task steps/acceptance criteria to reflect compression enabled by default and current streaming approach. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
115
to
120
| minimal.Should().Contain("ArkStreaming.WithCancellation"); | ||
| minimal.Should().Contain("IEnumerable<string>"); | ||
| minimal.Should().Contain("IAsyncEnumerable<string>"); | ||
| minimal.Should().Contain("WriteStreamingResponseAsync"); | ||
| minimal.Should().NotContain("DisableResponseCompression"); | ||
|
|
Comment on lines
141
to
146
| app.UseRouting(); | ||
| app.UseAuthentication(); | ||
| app.UseAuthorization(); | ||
| app.UseSimpleInjector(container); | ||
| app.UseResponseCompression(); | ||
| return app; |
Comment on lines
+69
to
+74
| services.AddResponseCompression(options => | ||
| { | ||
| options.EnableForHttps = true; | ||
| options.Providers.Add<BrotliCompressionProvider>(); | ||
| options.Providers.Add<GzipCompressionProvider>(); | ||
| }); |
AndreaCuneo
deleted the
copilot/docsmediator-frameworkprogressaspnetcore-hosting-g
branch
August 5, 2026 05:56
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces Brotli and Gzip response compression for HTTPS by default in the minimal API host, while ensuring that streaming endpoints are not negatively impacted by compression buffering. It also adds logic to automatically disable response compression for streaming endpoints to preserve low-latency delivery. The main changes are grouped below.
Response Compression Integration:
AddArkMinimalApiHostandUseArkMinimalApiHostto register and enable response compression middleware. [1] [2] [3]Documentation: