Home > Uncategorized > Head First Akka with Scala

Head First Akka with Scala

Howdy

Have you enjoy Scala yet ? Have you love this language and its actor model yet ?

Probably you have. I will now explore a really cool framework for building distributed system with actor model. It’s Akka Framework. It’s a reactive framework.

 

image

 

If you haven’t heard about the term reactive you need to check out this one first.

image

 

First we will need to install SBT first. If you have already familiar with java. Managing dependency, installing library, setting up structure is really painful if you are not using tools or IDE. SBT is a simple build tools that doesn’t sucks like Ant (with XML hell). You need to download that first from here.

image

Now we can start by creating SBT project  for this lesson. Create a file build.sbt and insert the following content into the file.

 

image

Run sbt compile for the first time for initializing sbt and your project. It will download the required library for Akka. Your output might be different with me. At the first time it will take awhile. Just be patience.

image

 

Create directory src/main/scala

 

image

Create file HelloActors.scala. Insert the following code

image

Run the project by executing sbt run from the directory where build.sbt created.

 

image

 

Now you can continue exploring by download the following chapter and write some code !!.

Cheers

 

References :

http://www.reactive.io/tips/2014/03/28/getting-started-with-actor-based-programming-using-scala-and-akka/

http://doc.akka.io/docs/akka/2.3.4/intro/getting-started.html

http://doc.akka.io/docs/akka/2.0/intro/getting-started-first-scala.html

http://doc.akka.io/docs/akka/2.0/index.html

http://doc.akka.io/docs/akka/2.3.4/scala/index-network.html/

http://doc.akka.io/docs/akka/2.3.4/scala/cluster-usage.html#preparing-your-project-for-clustering

Tools :

http://www.jetbrains.com/idea/features/scala.html

http://confluence.jetbrains.com/display/IntelliJIDEA/Scala?_ga=1.109172037.1933020012.1406117705

Categories: Uncategorized
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: