Note: This library is highly experimental.
Ratatoskr is a lightweight virtual actor framework for node.js.
Ratatoskr aims to make writing realtime distributed systems easier by leveraging virtual actors to allow developers to focus on application logic, not how their application will be distributed.
Visit the wiki for more documentation.
npm install --save ratatoskr
- Start redis locally
const ratatoskr = require("ratatoskr")();
ratatoskr.actor("helloActor", () => {
return class {
onMessage(username) {
return "Hello, " + username;
}
}
});
ratatoskr.start().then(() => {
return ratatoskr.send("helloActor", "Joe").then((result) => {
console.log(result);
});
});