Tech and Media Labs
This site uses cookies to improve the user experience.
JCTools
  1. JCTools




JCTools

Jakob Jenkov
Last update: 2016-01-30

JCTools (Java Concurrency Tools) provides a set of commonly used non-blocking concurrent data structures missing in standard Java. Non-blocking concurrent data structures can provide much better concurrency than blocking concurrent data structures when the data structure is contended (accessed a lot by multiple threads at the same time).

JCTools is an open source toolkit and is released under the Apache License 2.0.

JCTools GitHub Repository

JCTools has a public GitHub repository here:

https://github.com/JCTools/JCTools

JCTools Components

The primary components in JCTools is a set of non-blocking queues. Non-blocking queues is a useful way to pass data between threads in a multithreaded system. Different use cases enable different queue implementations. Some queue implementations perform better than others, so you should choose the right queue implementation for your use case.

The queues in JCTools are:

  • SPSC - Single Producer Single Consumer
  • MPSC - Multi Producer Single Consumer
  • SPMC - Single Producer Multi Consumer
  • MPMC - Multi Producer Multi Consumer

By "producer" and "consumer" are meant "producing thread" and "consuming thread". Multiple components can read from a "single consumer" a queue as long as all reading components are executed by the same thread. The same is true for writing components.

JCTools - Lead by Nitsan Warkart

The development of JCTools is lead by Nitsan Warkart, the owner of the well-known blog Psychosomatic, Lobotomy, Saw, about Java performance related topics.

Jakob Jenkov




Copyright  Jenkov Aps
Close TOC