Data Science: Serving and Processing Data with Actix.

applied.math.coding
5 min readAug 12, 2023

This story is part of my Data Science series.

Tasks in Machine Learning not only involves building of models or data analysis but in addition to deploy the results on production systems. Often such systems are built around a web server — and at exactly this I want to focus in this story.

At the time of writing one of the best web frameworks in the Rust community is Actix. It offers full support of asynchronous request handling which is very important for scalability and performance of I/O tasks.

In order to not repeat ourselves, I simply re-use the project that we setup together in the previous story about accessing data.

First of all, we add Actix to our dependencies in Cargo.toml:

[dependencies]
...
actix-web = { version = "4" }
serde = { version = "1.0", features = ["derive"] }

Actix is a very easy to use web framework with high performance. Actually it resembles features that you find in frameworks like Express.js, Nestjs or even Spring MVC.

--

--

applied.math.coding

I am a Software Developer - Java, Rust, SQL, TypeScript - with strong interest doing research in pure and applied Mathematics.