I\'m with a problem to configure the GZip in my Wildfly server used the following configuration on the server:
Expanding on Alexander's answer I did some tests. Strangely enough the predicate to only compress files larger then 500 bytes is not min-content-size[500]
.
To configure it using jboss-cli.sh
run this script:
/subsystem=undertow/configuration=filter/gzip=gzipFilter:add()
/subsystem=undertow/server=default-server/host=default-host/\
filter-ref=gzipFilter:add(predicate="not min-content-size[500]")
Note that the gzip filter will start to work after server reload. You can do this using cli's command :reload
.
To test if the filter is enabled I used:
wget $MY_URL -S --header="accept-encoding: gzip" \
-O /dev/null 2>&1| grep Content-Encoding