Open Systems Laboratory at Illinois

ActorFoundry

ActorFoundry is a JVM-based framework for Actor programming. Actor programs consist of concurrent entities (Actors) that communicate by asynchronous message-passing. The model is inherently concurrent; it is therefore considered to be a promising approach towards multi-core programming. There is no shared state among Actors and therefore the model is free from low-level data races. The wikipedia page and this article on concurrent object-oriented programming have more details about the model.

ActorFoundry enables writing Actor programs in familiar Java syntax. An ActorFoundry program looks like this:

package osl.examples.helloworld;
 
import osl.manager.*;
import osl.util.*;
import osl.manager.annotations.message;
 
public class HelloWorld extends Actor {
 
@message public void boot() throws RemoteCodeException {
ActorName a2 = create("osl.examples.helloworld.HelloWorld");
send(a2, "relayGreeting", "Hello ");
send(a2, "relayAudience", "World!");
}
 
@message public void relayGreeting(String item) {
send(stdout, "print", item);
}
 
@message public void relayAudience(String item) {
send(stdout, "println", item);
}

}

Java

Features

  • Safe (by-copy) as well as efficient (zero-copy) messaging
  • Message ordering using local synchronization constraints
  • Pattern-matching (multiple dispatch)
  • Fair scheduling
  • Mobility
  • Location independence
  • Modular and extensible
  • Portable (pure Java implementation)

Performance

ActorFoundry internally performs a CPS transformation (using the bytecode post-processor included in Kilim) and uses an M:N architecture (mapping M Actors to N native threads where M >> N) for a highly efficient implementation of the Actor semantics. The performance of ActorFoundry for the thread-ring benchmark at The Computer Language Benchmarks Game is comparable to that of other top performing languages. Our comparative analysis of Actor frameworks for the JVM discuss the performance-related optimizations in detail.

Downloads

This version of ActorFoundry requires the Java Development Kit 6 and Apache Ant 1.7 or later. The README includes details on building and running ActorFoundry. The distribution includes a bunch of example Actor programs (with source) to get one started. This version of ActorFoundry can be used for developing single-node Actor programs only. Later versions will have support for distribution.

Documentation

To get started, follow this ActorFoundry tutorial. It provides an introduction to ActorFoundry and includes a few examples. We acknowledge Sarmad Abbasi and Zubair Zahid for contributing this tutorial.

License

The ActorFoundry software is NOT in the public domain. However, it is freely available without fee for education, research, and non-profit purposes as described in the complete ActorFoundry license.

History

ActorFoundry was originally designed and implemented by Mark Astley along with Thomas Clausen and James Waldby around 1998-2000. Mark Astley was a member of Open Systems Laboratory at that time.

Contact

Please contact us for any question, clarification or reporting any bugs.

Rajesh Karmani