[HTML payload içeriği buraya]
28.3 C
Jakarta
Monday, May 11, 2026

Kotlin-based Ktor 3.4 boosts HTTP shopper dealing with



Ktor 3.4 additionally introduces a brand new API for dynamically documenting endpoints that works in tandem with a brand new compiler plugin. As an alternative of constructing a Swagger entrance finish from a static file, the mannequin is constructed at runtime from particulars embedded within the routing tree. To generate documentation, builders can allow it by way of the Ktor Gradle plugin, then it’ll robotically present particulars in code by way of the brand new describe API.

Additionally in Ktor 3.4, the OkHttp shopper engine now helps duplex streaming, enabling shoppers to ship request physique information and obtain response information concurrently, in distinction to common HTTP calls, the place the request physique should be absolutely despatched earlier than the response begins. Duplex streaming is offered for HTTP/2 connections and will be enabled utilizing the brand new duplexStreamingEnabled property in OkHttpConfig.

And the Compression plugin now helps Ztsd by way of a ktor-server-compression-zstd module. Zstd is a quick compression algorithm with excessive compression ratios, low compression instances, and a configurable compression degree.

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles