You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wink.apache.org by "Bryant Luk (JIRA)" <ji...@apache.org> on 2010/06/03 22:57:57 UTC
[jira] Resolved: (WINK-152) Automatic content encoding
[ https://issues.apache.org/jira/browse/WINK-152?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Bryant Luk resolved WINK-152.
-----------------------------
Fix Version/s: 1.1.1
Resolution: Fixed
I added two filters that you can add in your web.xml to enable "automatic" Content-Encoding processing in the inbound request and outbound response.
{code}
<filter>
<filter-name>ContentEncodingRequestFilter</filter-name>
<filter-class>org.apache.wink.server.internal.servlet.contentencode.ContentEncodingRequestFilter</filter-class>
</filter>
<filter>
<filter-name>ContentEncodingResponseFilter</filter-name>
<filter-class>org.apache.wink.server.internal.servlet.contentencode.ContentEncodingResponseFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>ContentEncodingRequestFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>ContentEncodingResponseFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
{code}
Note that some servlet/web containers have automatic decoding (such as WebSphere 6.1 and 7.0 and you can disable it via http://www-01.ibm.com/support/docview.wss?uid=swg1PK41619 ) but you may want to add the automatic ContentEncodingResponseFilter for outbound responses. Also, some other products such as Apache httpd/Tomcat have different ways to handle content encoding so you may want to investigate their server documentation.
> Automatic content encoding
> --------------------------
>
> Key: WINK-152
> URL: https://issues.apache.org/jira/browse/WINK-152
> Project: Wink
> Issue Type: New Feature
> Components: Common
> Reporter: Bryant Luk
> Assignee: Bryant Luk
> Fix For: 1.1.1
>
> Attachments: WINK-152.patch
>
>
> It would be neat to have an automatic content encoding feature. In particular, gzipping content for clients that support it (via Accept-Encoding header) can improve response times.
> A property for automatically compressing/decompressing content available in Wink or an annotation specified on a resource or resource method.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.