WebAssembly Modules as Alternative to Docker Containers in IoT Application Development
Steven Pham, Kaue Oliveira, Chung–Horng Lung · 2023
Containers have been commonly used in recent years for application deployment in many fields of computing, including the Internet of Things (IoT). Thus, there is an opportunity for the use of WebAssembly (WASM) to improve application security and fault tolerance. Applications using WebAssembly expose small and purpose-built APIs to different application modules when combined with WASM’s strong sandboxing capabilities and increase application security under the principle of least privilege. Applications leverage the small startup time of WASM modules compared to Docker containers to create small unit-of-work-sized modules. These small, sandboxed modules can increase application fault tolerance when combined with providing modules with focused APIs. We investigated the viability of WASM as an alternative to Docker containers for IoT applications. Experiments were conducted to evaluate the overhead of WASM on heavy code throughput and latency. The results showed that WASM has a modest performance cost and provides secure application modularity.