Skip to content

Enable gzip compression#520

Merged
philmcmahon merged 2 commits intomainfrom
enable-gzip
Jan 28, 2026
Merged

Enable gzip compression#520
philmcmahon merged 2 commits intomainfrom
enable-gzip

Conversation

@philmcmahon
Copy link
Contributor

@philmcmahon philmcmahon commented Jan 28, 2026

What does this change?

On @twrichards suggestion here, I did some basic performance testing of nothing vs gzip vs brotli compression in giant.

For a worskspace with a json blob that's 11.63MB, I got the following timings before the server started serving content (after several refreshes to reduce any first load perfomance impact):

Nothing: 3.8s
Brotli: 4.5s
Gzip: 4s

Compression wise, the results were:
Brotli: 76% (2.83MB)
Gzip: 75% (2.96MB)

With the above in mind, I think gzip compression is the sweet spot. From some basic research, brotli is also generally recommended for dynamically generated files - brotli is more for stuff that is getting cached so you don't pay the higher compression cost on every request.

How to test

Tested on playground!

@philmcmahon philmcmahon self-assigned this Jan 28, 2026
@philmcmahon philmcmahon requested a review from a team as a code owner January 28, 2026 12:32
@philmcmahon philmcmahon added the feature Departmental tracking: work on a new feature label Jan 28, 2026
Copy link
Contributor

@twrichards twrichards left a comment

Choose a reason for hiding this comment

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

brill!!

@philmcmahon philmcmahon merged commit 2b70ba6 into main Jan 28, 2026
9 checks passed
@philmcmahon philmcmahon deleted the enable-gzip branch January 28, 2026 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Departmental tracking: work on a new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants