< Return to Blog

Toasty, an async ORM for Rust

Toasty is an asynchronous ORM for the Rust programming language that prioritises ease of use. Toasty supports SQL and NoSQL databases, including DynamoDB and Cassandra (soon). This description is straight from their blog post, as folks on Reddit are complaining my post lacks "details". *Cough*.
We can see users being created (in memory).  It's possible to use the underlying SQLite driver as well.
The docs don't show this yet but we can use Rustqlite like this, where I've turned this example into a PR,
// Use rustqlite as the driver, creating a file locally in `./` let filename = "toasty.db3"; let file_path = format!("./{}", filename); let file = PathBuf::from(file_path.as_str()); let driver = Sqlite::open(file).unwrap(); let db = Db::new(schema, driver).await;
As well as Todos
Support for other SQL options are on the way.  AWS DynamoDB is supported out of the box, as is SQlite.  MySQL is also on the way, and it looks like they'll probably tie SQL backing into a possibly a single crate.  In any case, this is first an ORM and as their README and blog post says, we can choose to throw any custom driver in, which is just lovely.