wanton7

wanton7

Found interesting actor-model project.

https://github.com/lunatic-lang/lunatic

Showing Posts 1 to 6

michaelvigor

michaelvigor

This has an updated website now: https://lunatic.solutions/

Similar to Lumen, but instead of Erlang compiling to WebAssembly, this is just inspired by Erlang, and written in Rust.

bkolobara

bkolobara

Hi! I’m the author of Lunatic and a huge Elixir fan :heart:.

I started working on Lunatic when I moved to Rust and missed the features from the BEAM world. Especially being able to just spawn a lightweight process that is self isolated. It’s impossible to do this in Rust using just libraries because all the code shares the same memory space.

I came up with the idea to use WebAssembly instances as process replacements. Contrary to Lumen, LAM and other implementations, Lunatic doesn’t run inside one WebAssembly instance, but runs thousands of instances as lightweight processes.

This gives Lunatic also a bit more powerful per process isolation than you get on the BEAM. E.g:

  1. You can spawn a process that can only use a limited amount of memory or CPU.
  2. You can use C bindings without fear. Once everything is compiled to WebAssembly, long running code will still be preempted and crashes don’t escape the process boundary.
  3. You can limit syscalls on a per process level, e.g. spawn this process but don’t let any code running in it open a network connection.
  4. Redirect syscallls, e.g. if this process writes to a log file redirect the stream over the network to an Elastic cluster.
  5. You can use it from you favourite language if it compiles to WebAssembly. Currently we only provide libraries for Rust and AssemblyScript.

The project is still in its early stage and not all features are implemented yet, but we got initial funding from YC and are working full time on it.

16
Post #2
Brainiac

Brainiac

Would it be feasible to use this runtime for, say, writing client side applications? So long as the target can run the executable? For example, writing the core of an app in rust, compiling to wasm and distributing it with the executable with platform specific wrappers like electron ?

bkolobara

bkolobara

At the moment we don’t provide any APIs for GUIs (or wrappers) and solely focus on backend applications, but it could be an addition in the future.

The runtime works on Windows, MacOs and Linux (x64 & arm64).

gaolaowai

gaolaowai

My heart is exploding with happiness to see Lunatic.

I’ve been trying to find a reason compelling enough for me to learn Rust, and this just might be it.

At my company, I’ve written a distributed framework in Python that uses MQTT as a message-passing mechanism between python nodes… we do datascience/AI stuff, but I’ve been looking for something that has the model of BEAM and speed of C, and have several times started architecting what it is you’re doing with Lunatic. My take on it would have been writing a microruntime to execute FreeRTOS code (I have a background in writing microcontroller firmware for some medical stuff). I’d recently been looking at the Cosmopolitan C library to compile to bare-metal code, then executing that inside of microVMs.

Lunatic seems like a better direction to go for easier deployment in different cloud environments.

Thanks for putting Lunatic together, and I look forward to contributing in the near future. :slight_smile:

Rich_Morin

Rich_Morin

This seems like an interesting notion. They write code in Rust, compile it into WebAssembly, and then call on some infrastructure that emulates the Erlang/OTP environment.

Functional Futures: Lunatic with Bernard Kolobara

-r

— All posts loaded —

Where Next? Top

Trending in Discussions Top

cblavier
Hey there, It’s been more than a year since we started using LiveView as our main UI library and building a whole library of UI componen...
New
mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
mhanberg
Hi everyone! The first release candidate for the Expert language server project is now available! We’ve published a press release detai...
New
budgie
A little off-topic, but I feel like people here have a good head on their shoulders. I used to be quite good at making software. Was luc...
New
axelson
Hi there! :wave: @frigidcode and I (but mostly him) have been running an Elixir Book club, we’re almost done with Designing Elixir Syste...
New
budgie
I love Elixir. It’s one of 2 programming languages I’ve ever fallen in love with. But I don’t use it anymore. Serverless was the promis...
New
Null-logic-0
What IDE or editor are you using for Elixir development? Personally, I use Zed, and I really like it, but sometimes I wish there were a ...
New

Other Trending Topics Top

GenericJam
Edit: 2026 May 15 - This post is archived. Mob is alive!! Main docs: mob v0.7.11 — Documentation A bit of explanation for the slightly c...
New
JesseHerrick
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
garrison
Hobbes is a low-level distributed database for the Elixir programming language. Hobbes provides a simple, safe, and scalable storage lay...
New
mcass19
ExRatatui lets you cook up rich terminal UIs in Elixir, powered by Rust’s ratatui via Rustler NIFs. Build interactive terminal applicatio...
New
georgeguimaraes
Just published claude-code-elixir, a plugin marketplace for Claude Code with Elixir support. These are the plugins I’ve been using for my...
New
Dmk
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews