I forgot to mention that the amount of data transferred to UI varies from one browser to the other.ThanksOn Thu, May 22, 2014 at 12:34 AM, Amine Essaouis <amine.e...@gmail.com> wrote:
Hello fellow Play/Scala developers.I have a Play app that serves search results by calling another service using multiple requests. The responses to the different requests are sent as chunks. Basically the requests are all fired and as soon as a request is finished, the result is sent back using Comet: I use the iframe method described by Play's doc.However, I noticed that in some cases, the iframe call finishes before all data has been sent back to the end user. I debugged a little and found that the requests eventually all finish and my browser shows a net::ERR_INCOMPLETE_CHUNKED_ENCODING.Here is how my result looks like:
Ok.chunked(
(stringEnumerator1 &> Comet(callback = "script1")) >-
(stringEnumerator2 &> Comet(callback = "script2")) >-
(stringEnumerator3 &> Comet(callback = "script3"))
).as(HTML)As far as I read in Play's doc, this should the trick but it doesn't and I have no idea how to solve this. Does anyone have a slight idea or tip on this?
Thanks
--Amine--Amine Essaouis
Computer Science Engineering Student | ENSEEIHT Toulouse
T +33-695-176-567
--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
The app is hosted on heroku, so the connection pass by the heroku router, but no proxy. Because heroku close idle connection after 30s, we send heartbeat message every 25s to keep the SSE open.
We tried with Ok.chunked and Ok.feed methods. Feed seems to trigger less errors, but the documentation seems to say that chunked is more standard.
The play doc is lacking to explain which one to use in real cases.
--
Jean Maynier
Co-founder / CTO
@jmaynier
The app is hosted on heroku, so the connection pass by the heroku router, but no proxy. Because heroku close idle connection after 30s, we send heartbeat message every 25s to keep the SSE open.
We tried with Ok.chunked and Ok.feed methods. Feed seems to trigger less errors, but the documentation seems to say that chunked is more standard.
The play doc is lacking to explain which one to use in real cases.