Navigation
Search
|
Deno adds OpenTelemetry integration
Friday February 21, 2025. 03:44 AM , from InfoWorld
Deno Land has released Deno 2.2, a new version of the Deno runtime for JavaScript and TypeScript that features built-in OpenTelemetry for monitoring logs, metrics, and traces. The new Deno release also features Linter updates that include a new plugin system and new rules for React and Preact users.
Announced February 19, Deno 2.2 can be installed by current users by running the command deno upgrade. Instructions for new installs can be found here. With Deno 2.2, Deno automatically instruments APIs such as console.log, Deno.serve, and fetch. Developers can instrument their own code using npm:@opentelemetry/api. To capture observability data, users will need to provide an OpenTelemetry protocol (OTLP) endpoint. For development and test environments, Deno Land suggests using Grafana’s LGTM Docker image. Deno 2.2 also introduces a major upgrade to deno lint, which features a new plugin system and 15 rules particularly for React and Preact users. The rules include jsx-boolean-value, jsx-button-has-type, jsx-curly-braces, jsx-key, jsx-no-children-prop, jsx-no-comment-text-nodes, jsx-no-duplicate-props, jsx-no-unescaped-entities, jsx-no-useless-fragment, jsx-props-no-spread-multi, jsx-void-dom-elements-no-children, no-useless-rename, react-no-danger-with-children, react-no-danger, and react-rules-of-hooks. To improve performance, Deno 2.2 now clears information about module analysis after a timeout. This leads to lower memory consumption, according to Deno Land officials. In another performance boost, Deno.stat and node:fs.stat now are as much as 2.5 times faster on Windows. Also, Node.js module resolution is made faster by limiting conversions between URLs and paths. Deno 2.2 has a change to the deno outdated tool that adds an interactive way to update dependencies, according to Deno Land. And Node.js and NPM compatibility improvements continue with Deno 2.2, with capabilities such as.npmrc files now being discovered in the home directory and project directory. Also in Deno 2.2: A highly requested node:sqlite module makes it easy to work with in-memory or local databases. Improvements to deno lsp make it faster and more responsive, with major boosts for web framework users. The deno bench tool, for benchmarking code, has been made more precise. The deno check tools for type checking now respect JSDoc tags and allow compiler options to be configured per workspace member. Performance and quality of life improvements have been made to deno compile, which is now smaller and faster. The release upgrades to TypeScript 5.7. A revamped WebGPU implementation should improve performance of available APIs.
https://www.infoworld.com/article/3829619/deno-adds-opentelemetry-integration.html
Related News |
25 sources
Current Date
Feb, Sat 22 - 18:43 CET
|