4 ms·
Not nice of Java to block the queues. Especially since we're talking about concurrency beginners. It's hard enough for them as it is.
by erokar 9y ago
Not nice of Java to block the queues. Especially since we're talking about concurrency beginners. It's hard enough for them as it is.
- virmundi 9y agoNice thing about Java's verbose naming is the name tells you the behavior. It also has a lot of internal documentation in the Java. Such documentation is easily accessible from their IDe or the web. As the article points out, you can block the producers or consumers. So while queues and threading are advanced for an entirely new concurrency programmer, the are the most fundamental block of the concurrence developer.
- sorokod 9y agoThat is up to the developer - there are non blocking implementations of the Queue interface: https://docs.oracle.com/javase/8/docs/api/java/util/Queue.html https://docs.oracle.com/javase/8/docs/api/java/util/Queue.ht... , LinkedList for example.