~/talk

The Power and Perils of Parallel Streams

Talkat Oracle OpenWorld 2017 · 2017-10-01..10-05· [java]
slides:none on file

Explains when parallel streams actually help (many elements and heavy per-item work) and when they hurt (too few items, too many threads), shows that the default uses the ForkJoinPool.commonPool sized to CPU cores (main thread participates so effective threads = cores − 1), demonstrates configuring threads with -Djava.util.concurrent.ForkJoinPool.common.parallelism or a custom ForkJoinPool, warns that pipeline is entirely parallel or sequential, that ordering is a terminal constraint (findAny vs findFirst), and that reduce needs an identity value not initial value or results are wrong.

AI-written summary · about

  1. 0:00Start
  2. 1:28Parallel Arrays
  3. 9:58How Do You Know if a Stream Has Ordering or Not
  4. 14:49Add Method
  5. 26:25Blocking Factor
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.