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

🔥 Feature: Add support for zstd compression #3041

Merged
merged 6 commits into from
Jun 26, 2024
Merged

Conversation

gaby
Copy link
Member

@gaby gaby commented Jun 24, 2024

Description

  • Add support for using zstd compression in core Fiber, static middleware, and compression middleware
  • Added case for running long tests using Makefile
  • Added unit-tests for compression algorithms in Bind body.
  • Added unit-tests for compression algorithms in Static Middleware.
  • Added unit-test for CompressedFileSuffixes
  • Removed CompressedFileSuffix, added CompressedFileSuffixes, setting both of these values causes issues with fasthttp.FS naming of compressed files.
  • Made CompressBrotli=True when Compress is set to True, else it won't use brotli compression.
  • Added unit-test in Static middleware for files below and above 200 bytes.
  • Added Benchmarks for all compression algorithms and all levels of Compress middleware

Fixes #3001

Type of change

  • New feature (non-breaking change which adds functionality)
  • Enhancement (improvement to existing features and functionality)
  • Documentation update (changes to documentation)

@gaby gaby requested a review from a team as a code owner June 24, 2024 14:01
@gaby gaby requested review from sixcolors, ReneWerner87 and efectn and removed request for a team June 24, 2024 14:01
Copy link
Contributor

coderabbitai bot commented Jun 24, 2024

Warning

Review failed

The pull request is closed.

Walkthrough

The updates introduce support for zstd compression in the Fiber framework, enhancing the existing compress middleware which already supports deflate, gzip, and brotli algorithms. Significant changes include modifications to the Config struct, new testing paradigms for various compression types, and adjustments across documentation to accurately reflect the new functionality.

Changes

File Change Summary
.github/README.md Added support for zstd compression in summary section.
.gitignore Updated to include .zst and .br file extensions for ignored compressed files.
Makefile Introduced longtest target to run all tests 10 times.
app.go Replaced CompressedFileSuffix string with CompressedFileSuffixes map in Config struct and default initialization.
bind_test.go Expanded tests to include scenarios for different compressed body formats, including zstd, and added relevant helper functions.
constants.go Added new constant StrZstd for zstd string identifier.
ctx.go Enhanced tryDecodeBodyInOrder function to handle zstd encoding and updated SendFile function for Brotli and file suffixes.
docs/api/fiber.md Updated references from CompressedFileSuffix to CompressedFileSuffixes, defaulting to multiple compression suffixes.
docs/middleware/compress.md Expanded compress middleware description to include zstd compression.
docs/middleware/static.md Updated static compression feature to include zstd alongside gzip and brotli for minimizing CPU usage.
docs/whats_new.md Mentioned addition of zstd compression support and updated header-related configuration documentation.
helpers_test.go Updated benchmark test inputs and expected output to include zstd.
middleware/compress/compress_test.go Added zstd compression cases and adjusted existing tests to handle various compression types more thoroughly.
middleware/static/static.go Adjusted static file serving logic to handle compressed file suffixes and support Brotli compression.
middleware/static/static_test.go Introduced tests for static file compression with various algorithms, ensuring correct handling of compressed responses.

Sequence Diagram(s)

sequenceDiagram
  participant Client
  participant FiberServer
  participant CompressionMiddleware

  Client->>FiberServer: Request with Accept-Encoding header
  FiberServer->>CompressionMiddleware: Process request
  CompressionMiddleware->>FiberServer: Return compressed response with zstd/gzip/deflate/brotli
  FiberServer->>Client: Response with Content-Encoding header
Loading

Assessment against linked issues

Objective (Issue #3001) Addressed Explanation
Add support for zstd compression
Ensure compatibility with fasthttp v1.53.0

Poem

In Fiber's code, a change so grand,
Zstd now lends a helping hand.
With speeds so fast, it flies sky-high,
Compressing files like a rabbit spry.
Gzip, Deflate, Brotli in the past,
Rejoice in zstd, a move so vast.
The app now dances in compressed sigh.


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?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

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 as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

codecov bot commented Jun 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 82.87%. Comparing base (ba6ea67) to head (ab24e62).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3041      +/-   ##
==========================================
+ Coverage   82.78%   82.87%   +0.08%     
==========================================
  Files         115      115              
  Lines        8227     8234       +7     
==========================================
+ Hits         6811     6824      +13     
+ Misses       1086     1081       -5     
+ Partials      330      329       -1     
Flag Coverage Δ
unittests 82.87% <100.00%> (+0.08%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ReneWerner87 ReneWerner87 added this to the v3 milestone Jun 24, 2024
@gaby
Copy link
Member Author

gaby commented Jun 25, 2024

@coderabbitai review

Copy link
Contributor

coderabbitai bot commented Jun 25, 2024

Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between ba6ea67 and 3295225.

Files selected for processing (15)
  • .github/README.md (1 hunks)
  • .gitignore (1 hunks)
  • Makefile (1 hunks)
  • app.go (3 hunks)
  • bind_test.go (2 hunks)
  • constants.go (1 hunks)
  • ctx.go (2 hunks)
  • docs/api/fiber.md (1 hunks)
  • docs/middleware/compress.md (1 hunks)
  • docs/middleware/static.md (1 hunks)
  • docs/whats_new.md (1 hunks)
  • helpers_test.go (1 hunks)
  • middleware/compress/compress_test.go (5 hunks)
  • middleware/static/static.go (2 hunks)
  • middleware/static/static_test.go (2 hunks)
Files skipped from review due to trivial changes (3)
  • .gitignore
  • Makefile
  • constants.go
Additional context used
LanguageTool
docs/middleware/compress.md

[uncategorized] ~61-~61: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ...evel" field are: - LevelDisabled (-1): Compression is disabled. - `LevelDefaul...


[uncategorized] ~62-~62: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ...ession is disabled. - LevelDefault (0): Default compression level. - `LevelBest...


[uncategorized] ~63-~63: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ...ompression level. - LevelBestSpeed (1): Best compression speed. - `LevelBestCom...


[uncategorized] ~64-~64: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ...sion speed. - LevelBestCompression (2): Best compression. ## Default Config `...

docs/whats_new.md

[grammar] ~51-~51: It looks like there is a word missing here. Did you mean “listen to config”? (LISTEN_TO_ME)
Context: ...ic.md) * app.Config properties moved to listen config * DisableStartupMessage * EnablePre...


[style] ~55-~55: This adverb was used twice in the sentence. Consider removing one of them or replacing them with a synonym. (ADVERB_REPETITION_PREMIUM)
Context: ...nablePrintRoutes * ListenerNetwork -> previously Network ### new methods * RegisterCus...


[uncategorized] ~192-~192: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ... ::: ### new methods * AutoFormat -> ExpressJs like * Host -> ExpressJs like * Port ->...


[uncategorized] ~193-~193: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ... AutoFormat -> ExpressJs like * Host -> ExpressJs like * Port -> ExpressJs like * IsProxy...


[uncategorized] ~194-~194: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ...like * Host -> ExpressJs like * Port -> ExpressJs like * IsProxyTrusted * Reset * Schema ...


[uncategorized] ~197-~197: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ...ke * IsProxyTrusted * Reset * Schema -> ExpressJs like * SendStream -> ExpressJs like * S...


[uncategorized] ~198-~198: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ...chema -> ExpressJs like * SendStream -> ExpressJs like * SendString -> ExpressJs like * S...


[uncategorized] ~199-~199: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ...tream -> ExpressJs like * SendString -> ExpressJs like * String -> ExpressJs like * ViewB...


[uncategorized] ~200-~200: The official spelling of this programming framework is “Express.js”. (NODE_JS)
Context: ...endString -> ExpressJs like * String -> ExpressJs like * ViewBind -> instead of Bind ###...


[style] ~253-~253: Consider rephrasing this to strengthen your wording. (MAKE_CHANGES)
Context: ...::: ## 🧬 Middlewares ### CORS We've made some changes to the CORS middleware to improve its f...


[uncategorized] ~261-~261: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ...updated fields: - Config.AllowOrigins: Now accepts a slice of strings, each re...


[uncategorized] ~262-~262: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ... allowed origin. - Config.AllowMethods: Now accepts a slice of strings, each re...


[uncategorized] ~263-~263: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ... allowed method. - Config.AllowHeaders: Now accepts a slice of strings, each re...


[uncategorized] ~264-~264: Loose punctuation mark. (UNLIKELY_OPENING_PUNCTUATION)
Context: ...allowed header. - Config.ExposeHeaders: Now accepts a slice of strings, each re...

docs/api/fiber.md

[grammar] ~47-~47: The word “setup” is a noun. The verb is spelled with a space. (NOUN_VERB_CONFUSION)
Context: ... | This allows to setup app name for the app ...


[uncategorized] ~61-~61: The preposition ‘to’ seems more likely in this position. (AI_HYDRA_LEO_REPLACE_ON_TO)
Context: ...tained by the top-level app and applied on prefix associated requests. ...


[uncategorized] ~68-~68: Did you mean: “By default,”? (BY_DEFAULT_COMMA)
Context: ...turn the value of the given header key. By default c.IP()will return the Remote IP from ...


[typographical] ~78-~78: The conjunction “so that” does not require a comma. (SO_THAT_UNNECESSARY_COMMA)
Context: ... before setting the path for the context, so that the routing can also work with URL enco...


[style] ~106-~106: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing. (REP_WANT_TO_VB)
Context: ... | Path of the certificate file. If you want to use TLS, you must enter this field. ...


[style] ~107-~107: You have already used this phrasing in nearby sentences. Consider replacing it to add variety to your writing. (REP_WANT_TO_VB)
Context: ...f the certificate's private key. If you want to use TLS, you must enter this field. ...


[grammar] ~115-~115: Did you mean “customizing”? Or maybe you should add a pronoun? In active voice, ‘allow’ + ‘to’ takes an object, usually a pronoun. (ALLOW_TO)
Context: ... func() | Allows to customize success behavior when gracefully shutti...


[style] ~156-~156: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym. (ENGLISH_WORD_REPEAT_BEGINNING_RULE)
Context: ..., CertKeyFile: "./cert.key"}) #### TLS with certificate go title="Examples...

Markdownlint
docs/middleware/static.md

22-22: null (MD031, blanks-around-fences)
Fenced code blocks should be surrounded by blank lines

docs/whats_new.md

49-49: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


50-50: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


51-51: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


52-52: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


53-53: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


54-54: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


55-55: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


59-59: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


60-60: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


61-61: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


65-65: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


66-66: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


67-67: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


68-68: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


69-69: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


73-73: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


74-74: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


75-75: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


192-192: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


193-193: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


194-194: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


195-195: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


196-196: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


197-197: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


198-198: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


199-199: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


200-200: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


201-201: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


205-205: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


206-206: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


207-207: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


208-208: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


209-209: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


210-210: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


211-211: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


212-212: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


213-213: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


214-214: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


215-215: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


219-219: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


220-220: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


221-221: Expected: dash; Actual: asterisk (MD004, ul-style)
Unordered list style


229-229: Expected: 0 or 2; Actual: 1 (MD009, no-trailing-spaces)
Trailing spaces


278-278: Expected: 0 or 2; Actual: 1 (MD009, no-trailing-spaces)
Trailing spaces


189-189: Expected: 1; Actual: 2 (MD012, no-multiple-blanks)
Multiple consecutive blank lines


242-242: Expected: 1; Actual: 2 (MD012, no-multiple-blanks)
Multiple consecutive blank lines


299-299: Expected: 1; Actual: 2 (MD012, no-multiple-blanks)
Multiple consecutive blank lines


255-255: Expected: 1; Actual: 0; Below (MD022, blanks-around-headings)
Headings should be surrounded by blank lines


258-258: Expected: 1; Actual: 0; Below (MD022, blanks-around-headings)
Headings should be surrounded by blank lines


143-143: null (MD031, blanks-around-fences)
Fenced code blocks should be surrounded by blank lines


171-171: null (MD031, blanks-around-fences)
Fenced code blocks should be surrounded by blank lines


23-23: null (MD032, blanks-around-lists)
Lists should be surrounded by blank lines


256-256: null (MD032, blanks-around-lists)
Lists should be surrounded by blank lines

docs/api/fiber.md

85-85: Expected: 1; Actual: 2 (MD012, no-multiple-blanks)
Multiple consecutive blank lines


118-118: Expected: 1; Actual: 2 (MD012, no-multiple-blanks)
Multiple consecutive blank lines


218-218: Expected: 1; Actual: 2 (MD012, no-multiple-blanks)
Multiple consecutive blank lines

Additional comments not posted (13)
docs/middleware/compress.md (1)

7-7: Updated Compression Middleware Documentation

The documentation now correctly lists zstd as a supported compression algorithm alongside gzip, deflate, and brotli. This update aligns with the new feature implementation in the middleware.

middleware/static/static.go (1)

62-72: Updated Configuration for Static Middleware

The fasthttp.FS struct has been updated to include new fields such as CompressBrotli and CompressedFileSuffixes, enhancing the middleware's flexibility in handling compressed files. This update is crucial for supporting multiple compression formats and is consistent with the PR's objective to support zstd compression.

docs/middleware/static.md (1)

151-151: Updated Documentation for Static Middleware

The documentation now reflects the new capability of the static middleware to use gzip, brotli, or zstd for compression, based on the Accept-Encoding header. This update is well-explained and aligns with the functionality changes in the middleware.

middleware/compress/compress_test.go (1)

138-160: New Unit Tests for zstd Compression

The added tests for zstd compression are comprehensive, testing the basic functionality to ensure that the compressed output is smaller than the original data. This is crucial for validating the correct implementation of the new compression algorithm.

docs/whats_new.md (1)

268-268: Documentation on New Compression Support

The section on compression correctly highlights the addition of zstd alongside existing methods like gzip, deflate, and brotli. This inclusion is essential for informing users about the new capabilities of the framework.

helpers_test.go (1)

319-323: Updated benchmark to include zstd compression type.

The benchmark test now includes zstd alongside other compression types (deflate, gzip, br, brotli). This aligns well with the PR's objective to introduce support for zstd compression. The test is designed to ensure that the utility function can handle the new compression type effectively.

middleware/static/static_test.go (1)

762-807: Consider improving test isolation and robustness.

  • Test Isolation: Using time.Sleep to wait for cache expiration is not reliable and can lead to flaky tests. Consider using a mock or a setup teardown method that can more reliably control the environment.
  • File Existence Checks: The test checks for the existence of compressed files. It would be beneficial to also check that the contents are correct and not just the existence.

[REFACTOR_SUGGESTion]

.github/README.md (1)

584-584: Update to compression middleware documentation is accurate.

The addition of zstd to the supported compression methods in the compress middleware is correctly documented. This change aligns with the PR's objective to enhance compression capabilities.

app.go (1)

479-484: Approved the initialization of CompressedFileSuffixes.

The initialization logic for CompressedFileSuffixes in the New() function is correctly implemented. It checks if the map is nil and sets the default values appropriately. This approach prevents nil map panics and ensures that the configuration is correctly initialized.

bind_test.go (1)

Line range hint 827-951: Comprehensive testing for new compression support and improved bind functionalities

The additions to Test_Bind_Body and related helper functions (testCompressedBody, testDecodeParser, testDecodeParserError) are well-implemented. These functions effectively extend the testing to cover the new zstd compression along with existing ones, and they introduce tests for different content types which is crucial for ensuring robustness in data handling.

  • The use of helper functions to modularize the testing of compressed bodies (testCompressedBody) and content type parsing (testDecodeParser and testDecodeParserError) enhances the readability and maintainability of the test suite.
  • The parallel execution setup in sub-tests ensures that tests do not interfere with each other, which is good practice in concurrent environments.

However, I noticed a potential area for enhancement:

  • Error Handling: In the testDecodeParserError function, the use of require.Error is appropriate, but it might be beneficial to also check the type or message of the error to ensure that it's failing for the right reasons, not just any error.

Overall, the test coverage looks solid, and these tests should effectively validate the functionality of the bindings with various compression and content types. Great job on making sure the new features are well-tested!

docs/api/fiber.md (1)

51-51: Update documentation to reflect the new configuration for compressed file suffixes.

The documentation now correctly describes the CompressedFileSuffixes configuration, which uses a map to handle multiple compression types. This is an important update for clarity and functionality, ensuring that users are aware of how to configure different file suffixes for various compression types.

ctx.go (2)

221-222: Addition of zstd compression support in tryDecodeBodyInOrder function.

The addition of a case for StrZstd in the tryDecodeBodyInOrder function is aligned with the PR's objective to support zstd compression. This change allows the function to handle zstd encoded bodies by calling c.fasthttp.Request.BodyUnzstd(). This is a necessary update to ensure that the application can decode requests compressed with zstd.


1434-1442: Configuration of sendFileFS with zstd compression support.

The modifications to the sendFileFS initialization block to include CompressBrotli and CompressedFileSuffixes are crucial for handling static files compressed with zstd. This configuration ensures that the server can serve static files efficiently by utilizing the appropriate compression based on the client's Accept-Encoding header. This change aligns with the PR's enhancements to the static file middleware.

app.go Show resolved Hide resolved
middleware/static/static_test.go Show resolved Hide resolved
middleware/static/static_test.go Show resolved Hide resolved
@gaby gaby changed the title feat: Add support for zstd compression Add support for zstd compression Jun 25, 2024
@gaby gaby changed the title Add support for zstd compression 🔥 Feature: Add support for zstd compression Jun 25, 2024
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 3295225 and ab24e62.

Files selected for processing (1)
  • middleware/compress/compress_test.go (7 hunks)
Files skipped from review as they are similar to previous changes (1)
  • middleware/compress/compress_test.go

@ReneWerner87 ReneWerner87 merged commit b9936a3 into main Jun 26, 2024
7 checks passed
@efectn efectn deleted the zstd-support branch June 28, 2024 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

📝 [Proposal]: Add support for zstd compression
2 participants