如何在Wildfly 10上禁用GZIP压缩?

时间:2017-09-09 17:43:07

标签: gzip wildfly wildfly-10 http-compression

为了能够在java应用程序中显示下载状态,我需要在wildfly 10服务器上禁用GZIP压缩。它似乎默认启用。我发现了很多关于如何启用它的页面,没有什么可以禁用它。任何线索?

修改

我尝试从配置中删除完全gzip过滤器,如下所示。我下载的文件(3 MB)在传输过程中仍然被压缩

    <subsystem xmlns="urn:jboss:domain:undertow:3.1" statistics-enabled="true">
        <buffer-cache name="default"/>
        <server name="default-server">
            <http-listener name="default" socket-binding="http" redirect-socket="https" enable-http2="true"/>
            <https-listener name="https" socket-binding="https" security-realm="ApplicationRealm" enable-http2="true"/>
            <host name="default-host" alias="localhost">
                <location name="/" handler="welcome-content"/>
                <filter-ref name="server-header"/>
                <filter-ref name="x-powered-by-header"/>
            </host>
        </server>
        <servlet-container name="default">
            <jsp-config/>
            <websockets/>
        </servlet-container>
        <handlers>
            <file name="welcome-content" path="${jboss.home.dir}/welcome-content"/>
        </handlers>
        <filters>
            <response-header name="server-header" header-name="Server" header-value="WildFly/10"/>
            <response-header name="x-powered-by-header" header-name="X-Powered-By" header-value="Undertow/1"/>
        </filters>
    </subsystem>

0 个答案:

没有答案