Deno 1.9 previews native HTTP/2 server
- 16 April, 2021 11:30
Deno 1.9 was introduced April 13. For this release, the developers enlisted hyper, a fast HTTP implementation based on the Rust language, to build a new native HTTP/2 server API in Deno. The prior TypeScript-based HTTP server, std/http, offered good tail latency despite using a scripted HTTP server, but it was HTTP 1.1-only, with no easy path toward HTTP 2, according to Deno 1.9 release notes.
The Deno developers say the new binding has improved hello-world throughput by 48 percent when compared to the std/http HTTP server. They hope to stabilise the API soon; for now, it is offered under an
unstable flag, for developers to try it out.
Deno is positioned as a more secure alternative to Node.js. Deno 1.9 also features:
- Blob URL support is featured. Blob URLs can be used in
fetch, to instantiate web workers using
new Worker, and in dynamic URLs using
fetchalso now supports
- Deno Language Server, a tool to power editor extensions, has been improved, including the reintroduction and improvement of the import completions feature from the prior Visual Studio Code extension. This feature allows developers to get completions in import statements.
- Developers can interactively prompt for permissions on use rather than declaring them up front.
- Several APIs related to the file system, such as
Deno.fstatSync, have been stabilised.
Current Deno users can upgrade to version 1.9 by running
deno upgrade. Multiple methods for installing Deno for the first time can be found in the release notes. Version 1.9 follows the prior Deno 1.8 release, which published on March 2.