Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Some test code to get my head around Akka Java api

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 AkkawebDemo1.0
Octocat-spinner-32 AkkawebDemoClient
Octocat-spinner-32 common
Octocat-spinner-32 lib
Octocat-spinner-32 .gitignore
Octocat-spinner-32 README
Octocat-spinner-32 build.gradle
Octocat-spinner-32 settings.gradle
README
akka-java-playground

Sample code for testing out and learning the Akka framework's Java API.

AKKA: http://akkasource.org/


1. Project structure and compile

    There are 3 projects in the repository:

    * AkkawebDemo1.0    : this is the 'server' project, where remote typed and untyped actors run.
    * AkkawebDemoClient : 'client' project, where client actors are executed. Client actors normally invoke remote actors deployed in the server.
    * common            : shared code.

    To compile and run the code you need to install Gradle 0.9-rc1 (http://www.gradle.org/) 
    Steps:
    - Download and unzip Gradle (http://dist.codehaus.org/gradle/gradle-0.9-rc-1-all.zip)
    - Follow installation instruction here: http://www.gradle.org/installation.html

    After Gradle installation, run 'gradle clean build' in the project root folder.

2. Generate Intellij Idea project file

    run 'gradle idea' in one of the 3 project folders. The task will generate the .iml project file with all the dependencies set.
    Open Idea, File --> New Module --> Import Existing Module --> Select .iml file

3. Running the tests
    
    At the moment the process for running the tests is quite rudimental. There are two "Stress tests" in the AkkawebDemoClient.
    One is used to test concurrency for Untyped actors, the second for testing concurrency in the Typed Actors.
    
    The current tests are meant for testing remote actors, therefore the Akka server has to be started before launching the tests.
    Open a console, cd to AkkawebDemo1.0 folder and run
        gradle clean jettyRun
        
    This should start the Akka server.
    
    To run the stress test for Untyped actors, cd to the AkkawebDemoClient folder and run:
        gradle clean runUntypedTest -i
    To run the stress test for Typed actors, cd to the AkkawebDemoClient folder and run:
        gradle clean runUntypedTest -i
        
    Do not forget to add the -i flag, otherwise the output of the test will not be displayed on the console.
Something went wrong with that request. Please try again.