|License: LGPL||GitHub: Commits, Issues||Free (Code): All Releases, All Announcements||Google Group|
JActor is a high-throughput Java Actor framework, one of the fastest Actor implementations in any language.
- Two-way messages provide implicit flow control, for better performance under load.
- A simple machine builder is included to help keep application code clear and simple.
- A billion actors a second can be created on a single thread.
- Continuations are context free and can be used to send a response back from any thread–ideal for making actors completely transparent to application code. (new in release 4.5.0)
|Shared Mailbox||Across Mailboxes||Asynchronous Mailboxes|
|msgs per sec||222,861,399||151,987,233||81,083,272|
(Test Machine: i7-3770 @ 3.40 GHz, ASUS P8Z77-M Motherboard, 16 GB Corsair DDR3 1600 MHz RAM and Vertex 3 SATA III SSD)
JActor is available on The (Maven) Central Repository, so Maven users just need to add this to their POM file:
(Be sure to update the version number appropriately, of course.)
JActor makes use of SLF4J to work with a variety of loggers. For example, to use LOG4J you need to include the slf4j-log4j12-1.6.4.jar file. Again, Maven users just need to add this to their POM file:
Dependencies: Java 6, slf4j
- cp149/jactor-logger – An appender for logback
- skunkiferous / PingPong – A simple benchmark for JActor and PActor
- Ivan Hristov’s Chat
- Daniel Seidler’s Pi Calculation
- The Problem with Actors
Actor-based programming is quite appealing and holds a lot of potential. … more
- Introducing JActor
Vertical scaling is today a major issue when writing server code. Threads and locks are the traditional approach to making full utilization of fat (multi-core) computers, but result is code that is difficult to maintain and which to often does not run much faster than single-threaded code. … more
- JActor API Basics
Here we cover the basic API of JActor, which is very easy to use as you will see from the examples provided. … more
- Exception Handling made Easy
Message passing between threads and callbacks can both make exception handling more difficult. On the other hand, the use of 2-way messages (request/response) provides us with a natural default: uncaught exceptions should be passed back to the requesting actor for handling. And that is exactly what JActor does. … more
- A Bi-Modal Iterator for JActor
Loops are usually just a while loop with a hasNext() method in the condition and a next() method in the body. But when the response to these methods is asynchronous the loop fails, because the response is not received until after the while loop has completed. …more
- The Simple Machines of JActor
When multiple requests must be sent to other actors in the course of processing a request, the code can become quite muddled by the use of anonymous classes used to implement the callbacks for processing the responses of those requests. … more
- JActor Factories
The JAFactory actor binds actor type names to actor factories, allowing type names to be used in place of class names for serialization/deserialization. … more
Actors in the Small