tomcat - apache2 does not flushes response data while uploading file -
tomcat - apache2 does not flushes response data while uploading file -
before question i'll seek give context.
the setup
i have apache2 (v2.4) server proxying requests simple proxypass local apache tomcat (v6).
proxy / http://localhost:8080/
the service
our service process 1 file , when finishes, sends status client. even, little files, process file slow (intended). so, single 30kb request can take 5m or so.
the goal
to avoid connections dropped because idle, send every 10s blank line client. far, good, amazon elbs.
so, in implementation run task using callable , polling future every 10s. when polling timed out, send blank line client , forcing flush on outputstream.
the problem
but stuff works when file uploads before backend sends first '\n'.
when send big files (200mb), takes few minutes upload , client never sees blank lines, , connection dropped when finishes (because of idle drop). tested requesting straight tomcat or elb->tomcat instead of elb->apache->tomcat or apache->tomcat , client receives blank lines successfully.
tomcat apache2 amazon-elb
Comments
Post a Comment