jsr369-experts@servlet-spec.java.net

[jsr369-experts] Re: [servlet-spec users] Re: Reactive Streams and Servlet 4: synergy or no?

From: Edward Burns <edward.burns_at_oracle.com>
Date: Fri, 11 Sep 2015 06:20:56 -0700

>> >>>>> On Fri, 7 Aug 2015 08:41:36 +1000, Greg Wilkins <gregw_at_webtide.com> said:

GW> Here is Doug Lea's proposal to include Flows (aka Reactive Streams) in
GW> Java-9:
GW>
GW> http://cs.oswego.edu/pipermail/concurrency-interest/2015-January/013641.html
GW> I've not seen much discussion on its inclusion or not, so currently I'm
GW> assuming it is going in.

On Fri, Aug 7, 2015 at 5:07 AM, Edward Burns <edward.burns_at_oracle.com> wrote:

EB> At this point all we can say is that the idea has not yet been rejected
EB> out of hand. Also, we have to remember that the idea's inclusion or
EB> absence in JDK 9 only impacts our design regarding how we resolve our
EB> design with it when we get to Java EE 9 running on Java SE 9. In other
EB> words, we can't use this work directly, but we darn well better play
EB> nice and consistent with it when we get to EE/SE 9.

>>>>> On Thu, 27 Aug 2015 15:57:54 -0700, Wenbo Zhu <wenboz_at_google.com> said:

WZ> +1

WZ> Also on a) congestion control v.s. b) back-pressures ... IMO

WZ> a) protects the network too, and it's almost always hop-by-hop, to avoid
WZ> pushing too much data into the "network"
WZ> b) back-pressure, which I often refer to as (end-to-end) flow control is to
WZ> allow the receiver to notify the send to slow down or stop

WZ> HTTP relies on a) to propagate back-pressures b) as a result of "transport
WZ> coupling" ... but this would be another topic, and we are only concerned by
WZ> the API surface of enabling b).

Right, do you have any concrete ideas of how best to do this, Wenbo?

WZ> The time-performance aspect of blocking APIs (for enabling back-pressures)
WZ> is interesting, but I am not entirely sure how an async API may help,
WZ> without exposing transport-level detail, e.g. .. or is this the idea on
WZ> leveraging HTTP/2 specific facilities?

My understanding of Greg's idea was to actually allow the HTTP/2 flow
control to be the conduit for this kind of information. In high level
terms I see it as, "Hey, HTTP/2 has flow control built into the
protocol. Reactive Streams is all about back-pressure, which is really
very similar to flow control. I wonder if these two facts can be
brought together to deliver some novel value to users of Servlet 4.0."

Ed

-- 
| edward.burns_at_oracle.com | office: +1 407 458 0017
| 39 Business days til JavaOne 2015
| 54 Business days til DOAG 2015