Rustler is a library for writing Erlang NIFs in safe Rust code. That means there should be no ways to crash the BEAM (Erlang VM). The library provides facilities for generating the boilerplate for interacting with the BEAM, handles encoding and decoding of Erlang terms, and catches rust panics before they unwind into C. The library provides functionality for both Erlang and Elixir, however Elixir is favored as of now. The code you write in a Rust NIF should never be able to crash the BEAM. Decoding and encoding rust values into Erlang terms is as easy as a function call. Making a Rust struct encodable and decodable to Erlang or Elixir can be done with a single attribute. Enables you to safely pass a reference to a Rust struct into Erlang code. The struct will be automatically dropped when it's no longer referenced.

Features

  • Safety
  • Interop
  • Type composition
  • Resource objects
  • Functionality for both Erlang and Elixir
  • Add the rustler elixir library as a dependency of your project
  • Rustler aims to support the newest three major OTP versions

Project Samples

Project Activity

See All Activity >

License

Apache License V2.0

Follow Rustler

Rustler Web Site

Other Useful Business Software
Build AI Apps with Gemini 3 on Vertex AI Icon
Build AI Apps with Gemini 3 on Vertex AI

Access Google’s most capable multimodal models. Train, test, and deploy AI with 200+ foundation models on one platform.

Vertex AI gives developers access to Gemini 3—Google’s most advanced reasoning and coding model—plus 200+ foundation models including Claude, Llama, and Gemma. Build generative AI apps with Vertex AI Studio, customize with fine-tuning, and deploy to production with enterprise-grade MLOps. New customers get $300 in free credits.
Try Vertex AI Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Rustler!

Additional Project Details

Operating Systems

Mac, Windows

Programming Language

Rust

Related Categories

Rust Software Development Software

Registered

2022-10-06