The document discusses Akka, a toolkit for building highly concurrent, distributed, and resilient message-driven applications on the JVM. It describes key components of Akka including actors for concurrency, clusters for location-transparent resilient applications, persistence for event sourcing, and HTTP for asynchronous reactive servers. It also discusses the actor model of concurrent computation and related topics like reactive streams and advantages of asynchronous messaging.
3. The concurrent & distributed applications toolkit
Akka is a toolkit and runtime for building highly
concurrent, distributed, and resilient message-driven
applications on the JVM
4. The concurrent & distributed applications toolkit
Akka is a toolkit and runtime for building highly
concurrent, distributed, and resilient message-driven
applications on the JVM
5. Actors – Concurrency / high perf. messaging
Cluster – Location transparent, resilient clusters
Persistence – EventSourcing support (many DBs)
HTTP – Fully Async & Reactive Http Server
and much more (kafka, cassandra, testing, …)
8. ”The actor model in computer science is a
mathematical model of concurrent computation
that treats actors as the universal primitives of
concurrent computation. ”
Wikipedia
The Actor Model
9. An Actor
and acts on them by:
• Sending messages
• Changing its state / behaviour
• Creating more actors
receives messages
10. An Actor
A concurrency and distribution construct.
an addressable, location-transparent, entity
Show diagram showing people interacting with each other.
17. Not Only JSON
“The Internet is running in debug mode.”
— Rüdiger Möller
http://java-is-the-new-c.blogspot.de/2014/10/why-protocols-are-messy-concept.html
18. Not Only JSON: Example data
MediaContent {
media = Media {
uri = "http://javaone.com/keynote.mpg"
title = "Javaone Keynote"
width = 640
height = 480
format = "video/mpg4"
duration = 18000000
size = 58982400
bitrate = 262144
persons = ["Bill Gates", "Steve Jobs"]
player = JAVA
copyright = null
}
}
images = [
Image {
uri = "http://javaone.com/keynote_large.jpg"
title = "Javaone Keynote"
width = 1024
height = 768
size = LARGE
}
Image {
uri = "http://javaone.com/keynote_small.jpg"
title = "Javaone Keynote"
width = 320
height = 240
size = SMALL
}
]
25. Reactive Streams – why it all started
~2013:
Reactive Programming
becoming widely adopted on JVM.
- Play introduced “Iteratees”
- Akka (2009) had Akka-IO (TCP etc.)
- Ben starts work on RxJava
http://blogs.msdn.com/b/rxteam/archive/2009/11/17/announcing-reactive-extensions-rx-for-net-silverlight.aspx
http://infoscience.epfl.ch/record/176887/files/DeprecatingObservers2012.pdf - Ingo Maier, Martin Odersky
https://github.com/ReactiveX/RxJava/graphs/contributors
https://github.com/reactor/reactor/graphs/contributors
https://medium.com/@viktorklang/reactive-streams-1-0-0-interview-faaca2c00bec#.69st3rndy
Teams discuss need for back-pressure
in simple user API.
Play’s Iteratee / Akka’s NACK in IO.
} }A lot more people join
discussions, Reactive Streams
are born.