Recently, I encountered a challenge in integrating the Axum web framework and the rust-s3 library. The task at hand is to create two endpoints:
Of course, this should be done without using temporary files and without holding the entire file data in memory.
In this article, you'll find the complete code required to implement this functionality, accompanied by brief explanations.
As Rust's prominence in web development continues to surge, this article embarks on an in-depth exploration, conducting a comprehensive performance evaluation of the three most coveted web frameworks - Axum, Actix and Rocket. We will not only compare their performance but also delve into their key features, assess documentation quality, and conduct rigorous performance testing. Through this analysis, we will build a simple REST service with three distinct endpoints, each using one of these frameworks. One endpoint delivers a formatted string, the second introduces a 20-millisecond delay to simulate light database work or an external service call, and the third performs resource-intensive work by calculating a bcrypt hash, simulating complex business logic. Whether you're a seasoned Rust developer or new to the language, this article equips you with invaluable insights to make well-informed decisions for your upcoming web projects.