Bugzilla – Attachment 164137 Details for
Bug 36463
We should compress our JSON responses (gzip deflate mod_deflate application/json)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 36463: Compress application/json
Bug-36463-Compress-applicationjson.patch (text/plain), 2.18 KB, created by
Phil Ringnalda
on 2024-03-29 15:48:06 UTC
(
hide
)
Description:
Bug 36463: Compress application/json
Filename:
MIME Type:
Creator:
Phil Ringnalda
Created:
2024-03-29 15:48:06 UTC
Size:
2.18 KB
patch
obsolete
>From aea7e71445cae80c80c8de6f92437125b1bd74a8 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 29 Mar 2024 12:54:30 +0000 >Subject: [PATCH] Bug 36463: Compress application/json > >This patch simply adds application/json to the mod_deflate configuration > >To test: >1 - Open the netowrk tab in firefox >2 - Load http://localhost:8081/api/v1/libraries >3 - Not the transferred size, and note no 'Content-Encoding: gzip" header >4 - Apply patch, reset_all (or edit /etc/koha/apache-shared.conf) >5 - Reload >6 - Note smaller size, note gzip header > >Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org> >--- > debian/templates/apache-shared.conf | 3 ++- > etc/koha-httpd.conf | 3 ++- > 2 files changed, 4 insertions(+), 2 deletions(-) > >diff --git a/debian/templates/apache-shared.conf b/debian/templates/apache-shared.conf >index b923578e0b..e3ad79cc04 100644 >--- a/debian/templates/apache-shared.conf >+++ b/debian/templates/apache-shared.conf >@@ -36,7 +36,8 @@ SetEnv PERL5LIB "/usr/share/koha/lib" > <IfModule mod_deflate.c> > # Compress content with type html, text, and css, ... > AddOutputFilterByType DEFLATE text/plain text/html text/xml text/css >- AddOutputFilterByType DEFLATE application/xml application/xhtml+xml application/rss+xml application/javascript application/x-javascript >+ AddOutputFilterByType DEFLATE application/xml application/xhtml+xml application/rss+xml >+ AddOutputFilterByType DEFLATE application/javascript application/x-javascript application/json > > DeflateCompressionLevel 9 > >diff --git a/etc/koha-httpd.conf b/etc/koha-httpd.conf >index 867d309977..3c68189f2f 100644 >--- a/etc/koha-httpd.conf >+++ b/etc/koha-httpd.conf >@@ -61,7 +61,8 @@ > > # Compress content with type html, text, and css, ... > AddOutputFilterByType DEFLATE text/plain text/html text/xml text/css >- AddOutputFilterByType DEFLATE application/xml application/xhtml+xml application/rss+xml application/javascript application/x-javascript >+ AddOutputFilterByType DEFLATE application/xml application/xhtml+xml application/rss+xml >+ AddOutputFilterByType DEFLATE application/javascript application/x-javascript application/json > > DeflateCompressionLevel 9 > >-- >2.44.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 36463
:
164128
|
164137
|
164138
|
164139
|
164496
|
164497