Mantis Bugtracker
  

Viewing Issue Advanced Details Jump to Notes ] View Simple ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0005777 [Resin] major always 07-16-14 04:17 09-12-14 13:56
Reporter wxiaoguang View Status public  
Assigned To ferg
Priority normal Resolution fixed Platform
Status closed   OS
Projection none   OS Version
ETA none Fixed in Version 4.0.41 Product Version 4.0.39
  Product Build
Summary 0005777: resin + gzip hangs with Content-Length header in response
Description package com.springapp.mvc;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

@Controller
@RequestMapping("/")
public class TestController {


/*
in resin.xml:
    <filter filter-name="gzip" filter-class="com.caucho.filters.GzipFilter"/>
    <filter-mapping url-pattern="*.api" filter-name="gzip"/>

resin + gzip hangs forever
caused by "Content-Length" in response header
*/

    @RequestMapping(value = "test.api", method = RequestMethod.GET)
    public void test(HttpServletResponse response) throws IOException {
        String s = "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa";

        //if this line is commented out, resin won't hang
        response.setIntHeader("Content-Length", s.length());

        response.getOutputStream().write(s.getBytes());

        System.out.println("response done");
    }
}
Steps To Reproduce
Additional Information
Attached Files  resin-gzip-hang-test.zip [^] (3,475 bytes) 07-16-14 04:17

- Relationships

- Notes
(0006529)
ferg
09-12-14 13:56

server/183w
 

- Issue History
Date Modified Username Field Change
07-16-14 04:17 wxiaoguang New Issue
07-16-14 04:17 wxiaoguang File Added: resin-gzip-hang-test.zip
09-12-14 13:56 ferg Note Added: 0006529
09-12-14 13:56 ferg Assigned To  => ferg
09-12-14 13:56 ferg Status new => closed
09-12-14 13:56 ferg Resolution open => fixed
09-12-14 13:56 ferg Fixed in Version  => 4.0.41


Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
30 total queries executed.
26 unique queries executed.
Powered by Mantis Bugtracker