Fermyon's Spin WebAssembly Version 3.0 Released |
Written by Nikos Vaggalis | |||
Tuesday, 26 November 2024 | |||
The open source developer tool for building, distributing, and running serverless WebAssembly applications reaches version 3.0. What's new? We looked into Spin last year in Spin Brings WebAssembly To The Cloud, where we describe what it actually is about: Spin provides the interfaces for writing WebAssembly modules that can do things like answer HTTP requests. With Spin you reduce the overhead of microservices by factoring out the web server (replaced by a WAGI server) and writing out HTTP handlers in whatever language we want (Rust, C, JavaScript, Python, etc), which are then compiled to WebAssembly. With that in place, what does version 3. 0 bring to the table? you've authored an AWS S3 client in Rust and would like to use it in your Javascript-based Spin app - With that property you can mix and match components very easily into your workflow. Furthermore with the new "Selective Deployments" you can split an application across environments while still distributing it as a single unit. For example, you ship the same binary which is comprised of a front end, a database backend and an AI service to different locations but you invoke only the designated part in the appropriate location:
While Spin was already modularized with modules called "host components" in order to facilitate low coupling, in practice The new version also comes with deeper integration with the WASI Standards. As a refresher WASI (WebAssembly System Interface) is a modular system interface for WebAssembly (Wasm) that enables developers to run Wasm programs on any platform, including the browser, the cloud, and the edge. As such, Spin now officially supports the WASI Key-Value and WASI Config APIs. WASI key/value defines a collection of interfaces for interacting with key-value stores while Config aims to provide a set of generic interfaces for providing configuration to a component. To put Spin into practice, here is the code of a simple LLM powered application written in Rust and powered by the Spin sdk:
Take note that you can do the same in other languages like Python or Typescript, and/or connect other components together written in any other supported languages. Multi-language programming in practice! If you find the proposition interesting the download the SDK and check the many examples found on its Github repo in a multitude of languages.
More Information
Related ArticlesSpin Brings WebAssembly To The Cloud To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.
Comments
or email your comment to: comments@i-programmer.info |
|||
Last Updated ( Tuesday, 26 November 2024 ) |