2017-05-10 16:20:38 +02:00
|
|
|
|
# The Obligatory Hello World
|
2013-04-24 22:46:39 +02:00
|
|
|
|
|
2013-11-15 11:53:21 +01:00
|
|
|
|
The actor based version of the tough problem of printing a
|
2017-05-10 16:20:38 +02:00
|
|
|
|
well-known greeting to the console is introduced in a ready to run [Akka Main sample](@exampleCodeService@/akka-samples-main-java)
|
2017-03-31 13:52:05 +03:00
|
|
|
|
together with a tutorial. The source code of this sample can be found in the
|
2017-05-10 16:20:38 +02:00
|
|
|
|
[Akka Samples Repository](@samples@/akka-sample-main-java).
|
2013-04-24 22:46:39 +02:00
|
|
|
|
|
2017-05-10 16:20:38 +02:00
|
|
|
|
The tutorial illustrates the generic launcher class `akka.Main` which expects only
|
2013-04-24 22:46:39 +02:00
|
|
|
|
one command line argument: the class name of the application’s main actor. This
|
|
|
|
|
|
main method will then create the infrastructure needed for running the actors,
|
|
|
|
|
|
start the given main actor and arrange for the whole application to shut down
|
2013-11-15 11:53:21 +01:00
|
|
|
|
once the main actor terminates.
|
2013-04-24 22:46:39 +02:00
|
|
|
|
|
2017-05-10 16:20:38 +02:00
|
|
|
|
There is also a [Gitter8](http://www.foundweekends.org/giter8/) template in the same problem domain
|
|
|
|
|
|
that is named [Hello Akka!](https://github.com/akka/hello-akka.g8).
|
|
|
|
|
|
It describes the basics of Akka in more depth. If you have *sbt* already installed, you can create a project
|
|
|
|
|
|
from this template by running:
|
2013-04-24 22:46:39 +02:00
|
|
|
|
|
2017-05-10 16:20:38 +02:00
|
|
|
|
```
|
|
|
|
|
|
sbt new akka/hello-akka.g8
|
|
|
|
|
|
```
|