Discovered while upgrading plugin to be compatibilie with 5.1.
When makeRequest (/plugins/servlet/gadgets/makeRequest) is asked to get response from REST action which returns only status code, and gzip feature is enabled in JIRA we get java.io.EOFException.
Example REST method body:
When changed to:
then it works fine.
I suppose that problem is in gadgets - there was dependency version change in JIRA 5.1 to com.atlassian.gadgets.atlassian-gadgets-opensocial-plugin.
If gzip JIRA feature is disabled then everything works fine too.
Problem was introduced in JIRA 5.1 - tested with 5.0 and works fine with gzip enabled.