8222774: (ch) Replace uses of stateLock and blockingLock with explicit locks
Alan Bateman
Alan.Bateman at oracle.com
Tue Apr 23 20:23:06 UTC 2019
On 23/04/2019 20:59, Martin Buchholz wrote:
> default void park(int event,
>
> I would not have named a wait-for-network operation "park" - it's not
> really related to LockSupport.park; there's no unpark operation. The
> phrase "unless the permit is available" looks like it was copied from
> the park spec - does it really make sense here? Is "event" really a
> single event, or an "event set"?
Once all the pieces are in place then it will work like park/unpark. I
didn't mean to bring over the complete comment so I'll fix that.
Blocking operations on channels wait for a single event. It would be
possible to poll for multiple events but there isn't anything in the API
that supports that (this is all for blocking operations so there are no
Selectors in the picture).
> :
>
> I'm a little surprised at the pervasive conversion from builtin
> locks. For loom to succeed, you'll have to make builtin locks work
> eventually, eh?
>
I expect so but maybe not initially.
-Alan
More information about the nio-dev
mailing list