Skip to content

Releases: ghostdogpr/caliban

v2.6.0

16 Apr 00:34
15f7611
Compare
Choose a tag to compare

Release Notes

The highlight of this release is that Websocket support has been added to the QuickAdapter (the adapter that's the fastest to use and also provides the best performance). Since this adapter is using zio-http under the hood, we deprecated the existing tapir-based ZHttpAdapter which you can simply replace by the QuickAdapter. A small breaking change coming with this change is that we moved WebSocketHooks to another package and changed the type to describe transformation from StreamTransformer to ZPipeline.

Apart from that, there are quite a few performance improvements, in particular some coming from zio-query that should make things a lot faster if you use queries with a DataSource.

New features

  • Added WebSocket support to caliban-quick #2150 by @kyri-petrou
  • Added excludeDeprecated option to client code generation #2163 by @jeejeeone
  • Allowed prepending input path to HttpInterpreter-generated Tapir endpoints #2188 by @olisikh
  • Allowed providing a custom zio.query.Cache when executing queries by @kyri-petrou
  • Added interpreterUnsafe method to GraphQL #2160 by @kyri-petrou

Bug fixes

Performance improvements

Important dependency upgrades

v2.5.3

03 Mar 01:02
deaf50c
Compare
Choose a tag to compare

Release Notes

This release includes support for subscriptions over Server-Sent Events, as well as a few bug fixes and improvements.

Server

Tools

  • Fixed an issue with schema codegen when using the @lazy directive and the ZIO environment is not Any #2125 by @develeon

v2.5.2

17 Feb 00:29
a45aaa4
Compare
Choose a tag to compare

Release Notes

This release includes a new set of performance improvements as well as some usability improvements, in particular for schema code generation. It is fully backward compatible with 2.5.0.

Server

Client

Tools

  • Added a new directive called @newtype for the schema codegen to map ID to your own types #2091 by @develeon
  • Made the schema codegen generate the @GQLDeprecated annotation for deprecated fields #2107 by @johnspade
  • Fixed schema codegen when using derives with a ZIO Environment that is not Any #2104 by @develeon
  • Fixed schema comparison of implements #2116 by @ghostdogpr

v2.5.1

16 Jan 10:42
64096a8
Compare
Choose a tag to compare

Release Notes

This release brings a bug fix for an issue that was introduced in 2.5.0 and possibly caused duplicated fields in responses when using fragments. It is fully backward compatible with 2.5.0.

Server

Interop

Tools

  • Fix server code generation to support @lazy fields with abstract effect #2064 by @johnspade

v2.5.0

26 Dec 09:14
765318f
Compare
Choose a tag to compare

Release Notes

This release brings an incredible amount of performance improvements, some major library upgrades (zio-http, Play) as well as some powerful new derivation abilities such as deriving fields from case class methods.

Server

Adapters

Federation

v2.4.3

16 Nov 00:05
42d739d
Compare
Choose a tag to compare

Release Notes

This version brings a few bug fixes and improvements related to schema derivation on Scala 3.
In addition to that, it contains a new adapter named QuickAdapter and based on zio-http, that serves 2 purposes:

  • Offer the best performance among all adapters. This adapter is not using Tapir under the hood to prevent any overhead. We picked zio-http and jsoniter-scala because they gave the best benchmarks results among all our supported adapters and json libraries. The only drawback is that it doesn't include WebSocket support at the moment. If you care about performance above all, use this adapter!

  • Be super quick and easy to get started. With this adapter you can simply do that to go from your api to a running server:

import caliban._
import caliban.quick._ // adds syntax to `GraphQL`

val api: GraphQL[Any] = ???

api.runServer(
  port = 8080,
  apiPath = "/api/graphql",
  graphiqlPath = Some("/graphiql")
)

Server

Tools

v2.4.2

09 Nov 05:28
f4eb239
Compare
Choose a tag to compare

Release Notes

This version brings a few bug fixes as well as some performance improvements.
Big thanks to @kyri-petrou for his many contributions!

Server

Tools

  • Fixed a warning about impure expression that could popup when using the compile time codegen #1965 by @satorg

v2.4.1

20 Oct 13:20
3c4ab1f
Compare
Choose a tag to compare

Release Notes

This version fixes a regression introduced in 2.4.0 that prevents the usage of java.time types in schemas when using Scala 3 and JDK 17+ (#1950).

v2.4.0

15 Oct 08:01
dce6e9b
Compare
Choose a tag to compare

Release Notes

This version contains:

  • an important number of performance improvements
  • support for new specs and protocols: deprecated input fields, GraphQL over HTTP, new Apollo Caching, Federation 2.5
  • usability improvements, small fixes and library upgrades

Warning

Due to an issue in zio-http 3.0.0-RC2, servers exposing websocket endpoints via the caliban-zio-http module are required to include additional config for subscriptions to work as shown in this example.

This is a temporary workaround until a new version of zio-http is released which contains a fix to this issue.

Server

Adapters

Tools

  • Properly escaped union types in client code generation #1908 by @ghostdogpr
  • Fixed various things in server code generation #1925 by @oyvindberg
  • Added support for a @lazy directive to generate side-effecting fields in server code generation #1927 by @oyvindberg

Federation

v2.3.1

10 Sep 00:39
7a0ff58
Compare
Choose a tag to compare

Release Notes

This version contains important performance improvements as well as support for Pekko.

Server

  • Performance improvements
  • Added support for auto enum derivation with Scala 3 #1834 by @kyri-petrou
  • Added a wrapper that allows skipping selected validation wrappers during introspection #1837 by @kyri-petrou
  • Fixed WS protocol by always returning an id upon errors #1845 by @SvenW
  • Added a helper renderSchema to render a schema without a resolver #1877 by @ghostdogpr

Adapters