~/talk

Beyond lambdas, the aftermath

Talkat Jfokus 2016 · 2016-02-08..02-10· [java]
links:none on file
slides:none on file

Shows concrete pitfalls and fixes when adopting Java 8: orElse vs orElseGet causes eagerly-evaluated side effects so swap to Supplier-based orElseGet; never expose Optional as a public input parameter because it hides invariants; a flat stream can hide a nullpointer in intermediate ops so inspect the intermediate stack frames; use reduce to assert a single result instead of findFirst when duplicates break assumptions; parallelStream+ThreadLocal fails (use explicit parameters); prefer stateless lambdas for huge performance gains; streams are late-binding — copy mutable sources.

AI-written summary · about

  1. 0:00Start
  2. 6:42Avoid a Nullpointerexception
  3. 9:53Stack Traces
  4. 23:50Functional Interface
  5. 31:57How Would You Simulate Normal Ordering
~/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.