jeasse
jeasse copied to clipboard
Need way to propagate completion
Unless I'm missing something, there doesn't seem to be a way to propagate that an event stream is being closed, either from client or error/timeout.
I can see multiple ways to resolve this:
- take an
AsyncContext
instead ofHttpServletRequest
inServletEventTarget
constructor. - provide access to
ServletEventTarget
'sasyncContext
. - expose method to register an
AsyncListener
onServletEventTarget
Or is there another way?
Funny that you ask. If you checkout https://github.com/arkanovicz/jeasse.git you'll see an implementation proposal for your third suggestion (I don't understand why I can't see those commits on github web interface, it's probably because I commited them on the same branch I used to make the pending pull request).
Sorry @arkanovicz I didn't noticed there was a pull request on this repository. Thank you very much!
Just let me some time to review and merge it.
@mariomac Any progress? It would be nice with a fresh release.