Talking about Akka, Scala and life with Jonas Bonér

DZone 's Guide to

Talking about Akka, Scala and life with Jonas Bonér

· Cloud Zone ·
Free Resource

Welcome to the fifth in a series of interviews dedicated to learning more about JetBrains Development Academy Experts. This time we will interview Jonas Bonér. Jonas is a Java Champion, an owner of Scalable Solutions and an author of the Akka framework. He specializes in distributed computing, concurrency and knows a lot about many programming languages, including Scala, Clojure, Erlang and of course Java.

Members of the JetBrains Academy are recognized experts in various areas of software development. They contribute to Java and .Net communities by advocating development best practices through formal and informal publications and meetings, and serve as a versatile source of expertise.

JonasQ: Hello Jonas, can you tell us who you are, what you do, where you are from and what is your passion?

I'm a programmer living in Sweden with my wife, two kids and a cat. I run a product company called Scalable Solutions the company behind the Akka project. One of my passions is to write concurrent code and distributed systems, other passions is skiing, playing music and spending time with my family.


Q: Most people probably know you as the brain behind Akka. Undoubtedly, Akka has been gaining in popularity over the past couple of months. Can you give us a brief introduction into Akka?

Akka is a toolkit and runtime for building highly concurrent, distributed and fault tolerance systems on the JVM. It is written in Scala but has a Scala and Java API. Akka is using Actors together with Software Transactional Memory (STM) to create a unified runtime and programming model for scaling both UP (utilizing multi-core processors) and OUT (utilizing the grid/cloud). Akka provides location and network transparency by abstracting away both these tangents of scalability by turning them into an operations and configuration task. This gives the Akka runtime freedom to do adaptive automatic load-balancing, cluster rebalancing, replication and partitioning. Akka is available at http://akka.io under an Apache 2 license.

Q: I see Akka has arrived at an important milestone with its 1.0 release. How do you view the project evolution so far? Where do you plan to lead Akka next?

Currently we are doing most of the work in the distributed computing side of Akka; the remote actors. We have just started a refactoring and redesigning that will take you to the next level and this will be available in Akka 2.0 in the summer. We are also working hard on a the Cloudy Akka commercial add-on modules which is embracing the cloud and adding things like adaptive automatic load-balancing, cluster rebalancing, replication for fail-over and partitioning. This product suite will also include monitoring/management, provisioning and excellent Amazon EC2 integration.

Q: Why did you choose Scala as the implementation language for Akka? Does Scala meet your needs for a general-purpose programming language? Where do you think Scala will or should evolve?

Scala is the perfect systems language to build high throughput and low latency systems. It runs on the JVM, which is by far the best managed runtime there is. It is a statically typed language which for me mainly means two things;

  • I get excellent performance comparable to Java (sometimes even better)
  • I get solid help from the compiler which helps catching bugs and design errors early in the development process and makes it easier to do refactorings and have the code evolve over time without bitrot.

But while being a statically typed language Scala is as expressive and concise as dynamically typed languages like Ruby, Python or Groovy. It has type-inference which in short means that you don’t have to hold the compiler in the hand all the time declaring types all over the place like we are used to in Java, but it can draw its own conclusions from the context allowing you to focus on the essence.

Scala already is an excellent language to build concurrent and parallel systems, yet here is were most of the work currently being done pushing the boundaries even further. For example, the upcoming Scala 2.9 contains parallel collections and 2.10 will include STM (Software Transactional Memory).

Q: Speaking about programming languages, I know Scala is certainly not the only language you have in your tool box. Would you be willing to share your opinion on some of them? Is there any programming language in particular you'd like to point our attention to?

Sure, programming languages and learning new ones is a passion of mine. I'm a big fan of Oz (http://www.mozart-oz.org) which is an amazing multi-paradigm language that I really encourage everyone to take a look at. I'm also a fan of Erlang and the language that is the basis for both of these two languages; Prolog. I'm currently also much in love with Clojure and is trying to learn Haskell in my spare time.

Q: Perhaps it is not a coincidence that most of the languages you mentioned all have a good concurrency story. With dual and quad-core chips finding their way into our customers' laptops, concurrency is becoming a hot topic. Now, if we played a game of visionaries, how do you think mainstream programmers will write code for multi-core chips, lets say 5 years from now?

I think that everyone will write concurrent code, we will have to either we like it or not. However, I don't think that everyone needs to think about concurrency all the time but it will be abstracted away to a large extent by tools and higher-level abstractions. We are already started going down on that path; Actors, STM and Dataflow Concurrency that we have in Akka all three makes it much easier to write and reason about concurrent code. In Scala we already have parallel collections, which completely abstracts away the parallelism.

Q: A project on the scale of Akka could hardly be created without you having deep and broad previous experience with concurrent and distributed systems. Can you tell us what projects you worked on before and how it influenced the way you approach distributed systems today?

I learned a lot about concurrency and distributed computing while working at Terracotta writing JVM clustering products and also while working with the JRockit JVM at BEA Systems. I also learned a lot developing the AspectWerkz Aspect-Oriented Programming (AOP) framework and as a committer to the AspectJ compiler, both how to write performant Java code but also how to build and manage an open-source community, bringing great people together making people enthusiastic about your project.

Q: I guess this all helped you make the right decisions when creating your current company - Scalable Solutions. How would you characterize its mission?

Make it simpler for developers to write correct scalable and fault tolerant systems, provide a suite of products that gets the job done faster so they can go home to their friends and family instead of spending late nights debugging concurrency and distributed computing problems.

Q: These are very attractive goals, indeed. Since you are a member of the JetBrains Academy, I was wondering whether any of our tools have helped along the way to creating Akka.

I'm a happy user of IntelliJ IDEA and have been for the last 7-8 years. I almost exclusively program in Scala nowadays and the IntelliJ Scala plugin is really good.

Q: Do you have a favorite IDEA feature?

I'd say its IntelliSense, it's amazing. Still much better in Java, but the Scala plugin is catching up fast. I also used to like its excellent Maven integration, but I don't use Maven any longer, I use SBT, which could need some more love :-)

Q: OK, I'm taking notes. JetBrains also works on a workbench for DSLs, called Meta Programming System (MPS). Have you had a chance to look at it?

I have been following it from a distance. It looks very interesting but I have not had time to really dig in and use it.

Q: You are a frequent and popular speaker at programming conferences. How busy is your schedule for 2011? Where can people see you presenting this year?

So far this year I've been doing conferences in Stockholm, London and New York. Now I’m looking forward to speaking at Emerging Languages in Philadelphia, GOTO in Copenhagen, What's Next in Paris and Scala Days at Stanford.

Q: Is there a conference, a place or an on-line site you'd recommend to people interested in concurrency and distributed architectures? A secret source of relevant, thought-provoking, deep material for the domains?

I read a lot of books on the topic and follow some interesting people in this space on Twitter. Besides that I like reading the case-studies at http://highscalability.com. http://dancres.org/reading_list.html is a great resource for good reading in the distributed systems space. http://nosqltapes.com is a great resource for learning more about scalable databases.

Q: Great list of on-line resources. Have you recently read a book that you'd suggest to our readers?

I'm currently reading The Art of Multiprocessor Programming by Herlihy, Drive by Pink and Land of Lisp by Barski. One book that I recommend all engineers to read is Concepts, Techniques and Models of Computer Programming by PeterVan Roy and Seif Haridi, it will change the way you think about software. Another great book is Release It by Nygaard and you can't miss the classic Pragmatic Programmer by the Prags. Programming Pearls by Bentley is another classic and if you are into concurrency then you have to read Patterns for Parallel Programming by Mattson. Hacker's Delight by Warren is fun if you are into bit-twiddling and Pragmatic Thinking and Learning by Hunt if you want to improve how you think and learn. I have so many great books, hard to pick a few.

Q: Seeing your agenda, I doubt you have any free time. If you do spare a minute for yourself, what do you typically do?

I read books, watch movies, play with my kids and spend time with my wife. I also really enjoy skiing and playing music; I’m playing saxophone, a bit of piano and harmonica and I just started playing guitar.

Q: As our final question, can you tell us something about yourself that most people wouldn’t know?

I started programming pretty late; after I turned 25 and my kids like to tell everyone that I ate a living frog when I was a kid in some stupid “I’m more brave than you” game.

Excellent! Thank you very much Jonas for taking the time. It was well worth it!

Links to find out more:






Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}