commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cristian Lorenzetto <>
Subject Re: [javaflow] - how to use continuation in JNI boundary
Date Sat, 20 Jan 2018 23:36:32 GMT
It is absolutely not true. If a coroutine  execute

synchonized(lock){ lock.wait() }

the lock.wait blocks the thread. Why i have to block the thread if thread
can running other corotuines in the while?
lock.wait must supend the coroutine and resuming another coroutine

2018-01-21 0:23 GMT+01:00 Torsten Curdt <>:

> I am sorry but I must be missing something here.
> The code uses synchronization blocks and mutexes to explicitly make sure
> threads don't interfere which each other.
> This restriction will be there because of resource sharing and the java
> memory model.
> Instrumenting wait/notify cannot magically remove that restriction.
> Based on queuing theory you can move your bottleneck to your mutexes - but
> that's about it.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message