Click here to Skip to main content
15,891,184 members
Articles / Hosted Services / Microservices

Rust microservices in server-side WebAssembly

21 Dec 2022CPOL7 min read 22.6K   48   9  
This article discusses the use of the Rust programming language and WebAssembly (Wasm) runtime for building and deploying microservices in the cloud, highlighting the benefits of using Wasm for Rust programs in terms of performance, portability, and security.
The Rust programming language has gained popularity in recent years due to its ability to enable developers to write high-performance and memory-safe programs. However, one challenge for using Rust for server-side applications is that programs are compiled into native machine code, which is not portable and is unsafe in multi-tenancy cloud environments. Additionally, tools for managing and orchestrating native applications in the cloud are lacking. To address these issues, Rust programs can be compiled into WebAssembly (Wasm) bytecode, which can be deployed and run in the cloud using a Wasm runtime. Wasm runtimes provide better isolation than Linux containers and have smaller attack surfaces, and Wasm bytecode is portable across operating systems and hardware platforms. This article provides an overview of the tools and techniques needed to build and deploy Rust microservices in a Wasm runtime, including creating a web service, creating a web service client, creating a database client,
This is an old version of the currently published article.

Only logged in members can view this content

Please go to the Microservices Table of Contents to view the list of available articles in this section.