treasure island
DESCRIPTION
Treasure Island - Railsberry 2012 - Krakow. Talk about concurrency in Ruby and JRuby in particular. Ruby is pretty unique among scripting languages in having not only one but six (!) fairly mature runtime environments -- MRI, Rubinius, JRuby, MacRuby, IronRuby and MagLev -- each of them with specific strengths. In this talk I will first give a brief overview of planet Ruby and its continents. Then we will embark together on a journey into the deepest concurrency jungles on Java island, where strange beasts like Kilim, Jetlang and Akka roam. With a little luck, we might even encounter the legendary Disruptor! Using examples taken from actual production JRuby code, I will demonstrate how the power of the JVM plus the rich ecosystem around it are an ideal complement to the expressiveness of Ruby -- and how this killer combination can be used to fully exploit modern multicore hardware. Speakers: Tim Lossen, Patrick HueslerTRANSCRIPT
Treasure Island
Tour Guides
@tlossen
@phuesler
“The Free Lunch is Over.”— Herb Sutter (!""#)
Concurrency
Fin?
Concurrency
Multi Core
Thread Concurrency
!fork()
Rubies!!!
GIL
http://igvita.com/2008/11/13/concurrency-is-a-myth-in-ruby/
Ruby MRI 1.8 X
REE 1.8 X
Ruby MRI 1.9 X
IronRuby (✔)
Maglev ?
Rubinius ✔
JRuby ✔
MacRuby ✔
JRuby
Java Island
Multi-Threading
Evil?
java.util.concurrent
AtomicBoolean
CountDownLatch
Cyclic Barrier
Executor
Future
Actors
Bad Actors
and the nominees are...
MRI
Better Actors
Erlang
Scala
Rubinius
JRuby
Frameworks
Akka
Scala
Heavily Inspired by Erlang
Simple Concurrency
Distributed
Fault Tolerant
Supervisors
Fast
Can it be used with JRuby?
Yes*
Moarrrrr!!!!
STM
Evented
Disruptor
http://martinfowler.com/articles/lmax.html
Q & A
“There ain’t no such thing as a free lunch.”— Robert A. Heinlein
❦
• “The Free Lunch Is Over” (Herb Sutter, !""#)• “Real-World Concurrency” (Bryan Cantrill, Jeff
Bonwick, !""$)• “Don't Fear the Threads” (David Copeland, !"%!)• “Concurrency is not Parallelism” (Rob Pike, !"%!)• “The LMAX Architecture” (Martin Fowler, !"%%)
Links
CreditsAjith Kumar (Flickr)
tontoncopt (Flickr)
Hatem Riahi (Flickr)
Stefanie (Flickr)
CreditsBarry Skeates (Flickr)
Hillary White (Flickr)
David Thompson (Flickr)
“Dope Zebra”, Rhett & Link