The SubmissionPublisher class

The SubmissionPublisher class is an implementation of the Publisher interface whose role is to emit the data. The SubmissionPublisher class uses the supplied Executor, which delivers to the Subscriber. The developers are free to use any Executor depending upon the scenario in which they are working.

Executors.newFixedThreadPool (int num_of_threads) and ForkJoinPool.commonPool are some favorites of developers. Executors.newFixedThreadPool facilitates the creation of a thread pool with a fixed number of threads for the operation. Each thread in the pool will exist unless it has not been shut down explicitly. ForkJoinPool.commonPool is the default Executor used by SubsmissionPublisher. ForkJoinPool.commonPool returns ...

Get Reactive Programming With Java 9 now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.