Releases: connectrpc/connect-kotlin
v0.7.4
What's Changed
Other changes
- Escape
%in comments by @srikrsna-buf in #435 - Update License badge source by @guspan-tanadi in #417
New Contributors
- @guspan-tanadi made their first contribution in #417
- @srikrsna-buf made their first contribution in #435
Full Changelog: v0.7.3...v0.7.4
v0.7.3
v0.7.2
v0.7.1
What's Changed
Other changes
- Update DCO language by @drice-buf in #300
- Determine protoc version from protobuf version by @pkwarren in #312
- Update to v1.0.3 of conformance suite by @jhump in #318
- Generate
@Deprecatedannotations by @timostamm in #334 - Update gradle to 8.10.2 by @pkwarren in #337
- Update to the latest kotlin K2 compiler by @pkwarren in #338
Full Changelog: v0.7.0...v0.7.1
v0.7.0
Protobuf Major Release
Release v0.7.0 requires the latest major release (4.x) of the com.google.protobuf runtime library and updates generated code to require the new version of the library. See https://protobuf.dev/support/cross-version-runtime-guarantee/#major for more details on the Protobuf release policy and https://protobuf.dev/news/2023-12-05/ for documentation on changes to the Java runtime library.
Users wishing to remain on the previous major release (3.x) should use v0.5.1.
What's Changed
Improvements
- Update client to pass all conformance tests from connect-conformance
- Add support for Editions by @jchadwick-buf in #297
Other changes
New Contributors
- @jchadwick-buf made their first contribution in #297
- @drice-buf made their first contribution in #298
Full Changelog: v0.6.1...v0.7.0
v0.5.1
What's Changed
API Improvements
- The ConnectException constructor changed signature slightly in #248 (callers must use
.withErrorDetailsto specify error details).
Other changes
- Update to to conformance suite v1.0.1 and fixes numerous bugs identified by conformance tests by @jhump in #248, #252, and #253
Full Changelog: v0.5.0...v0.5.1
v0.6.1
Protobuf Major Release
Release v0.6.1 requires the latest major release (4.x) of the com.google.protobuf runtime library and updates generated code to require the new version of the library. See https://protobuf.dev/support/cross-version-runtime-guarantee/#major for more details on the Protobuf release policy and https://protobuf.dev/news/2023-12-05/ for documentation on changes to the Java runtime library.
Users wishing to remain on the previous major release (3.x) should use v0.5.1.
What's Changed
API Improvements
- The ConnectException constructor changed signature slightly in #248 (callers must use
.withErrorDetailsto specify error details).
Other changes
- Update to to conformance suite v1.0.1 and fixes numerous bugs identified by conformance tests by @jhump in #248, #252, and #253
Full Changelog: v0.6.0...v0.6.1
v0.6.0
Protobuf Major Release
Release v0.6.0 updates connect-kotlin to the latest major release (4.26.0) of the com.google.protobuf runtime library and updates generated code to require the new version of the library. See https://protobuf.dev/support/cross-version-runtime-guarantee/#major for more details on the Protobuf release policy and https://protobuf.dev/news/2023-12-05/ for documentation on changes to the Java runtime library.
Users are recommended to regenerate code with Protobuf 26.0 or later.
What's Changed
Enhancements
Full Changelog: v0.5.0...v0.6.0
v0.5.0
Release v0.5.0 includes numerous fixes so that connect-kotlin now passes many test cases in the Connect conformance suite that failed with the previous release. It also includes some clean-up of some of the APIs (and internal implementation) which are not backwards-compatible, but should only require minor changes to user code. See the "API Updates" section below for a list of all changed APIs.
What's Changed
API Improvements
These include some API changes which may require modification to user programs.
- Some cleanup in the HTTP request representations by @jhump in #211
- Denormalize "Code" and further simplification of HTTP interfaces by @jhump in #224
- This is likely the greatest impact to user code. See the "API Updates" for
com.connectrpc.Codeandcom.connectrpc.ResponseMessagebelow for more details.
- This is likely the greatest impact to user code. See the "API Updates" for
- Simplify UnaryBlockingCall by @jhump in #225
Enhancements
- Client-only and server-only streaming RPCs can now be used with HTTP 1.1 connections (previously required HTTP/2) by @jhump in #196, #210
- Support for auto-dispatching potentially blocking operations to I/O coroutine context by @jhump in #218
Bugfixes
- Fixes to bugs in unary RPCs that were revealed by conformance tests by @jhump in #193
- Fixes to bugs in stream RPCs that were revealed by conformance tests by @jhump in #210
Other changes
- Adds new conformance/client module by @jhump in #182, #194, #195, #196, #212, #213, #217, and #226
- This adds use of a new conformance suite, which caught numerous bugs also fixed in this release
- Fix android deprecation warning by @pkwarren in #204
New Contributors
- @akshayjshah made their first contribution in #229
API Updates
com.connectrpc.BidirectionalStreamInterface
- methods
sendCloseandreceiveCloseare now suspend methods
com.connectrpc.ClientOnlyStreamInterface
- method
sendCloseis now a suspend method - adds new method:
suspend fun cancel(), to cancel operation w/out completing it
com.connectrpc.ServerOnlyStreamInterface
- method
receiveCloseis now a suspend method
com.connectrpc.Code
- removes enum constant
OK- An operation is now determined to be successful by lack of an exception, instead of having an
OKcode
- An operation is now determined to be successful by lack of an exception, instead of having an
- method
fromValue(Int?):Codechanged to return nullableCode?; an input value of zero returnsnull
com.connectrpc.UnaryFunction
requestFunctionnow accepts aUnaryHTTPRequestinstead ofHTTPRequest
com.connectrpc.ResponseMessage
- removed
codepropertySuccessconcrete sub-type does not need a code: code is an error code and does not apply (was previously alwaysOK)Failureconcrete sub-type now has only the code inside thecause: ConnectExceptionproperty (thecodeproperty was redundant)
- updated constructors for
SuccessandFailureconcrete sub-types to no longer accept code
com.connectrpc.StreamResult
- changed
causeproperty to beConnectException?instead ofThrowable?- calling code can use new
com.connectrpc.asConnectExceptionextension function to transform aThrowableinto aConnectException
- calling code can use new
- removed
codeproperty- it was redundant with the code property of
cause
- it was redundant with the code property of
- update constructor to no longer accept code and to require
ConnectException?for cause foldis now an inline funmaybeFoldhas been removed (trivial to accomplish the same thing withfoldand nullable result type)
com.connectrpc.UnaryBlockingCall
- now an interface, not a class
- otherwise, same API except there is no constructor or factory function
com.connectrpc.http.HTTPClientInterface
- method
unarynow accepts aUnaryHTTPRequestinstead ofHTTPRequest - method
streamnow accepts aduplex: Booleanparameter, indicating whether the operation needs to support full-duplex communication with the server (for bidirectional streams)
com.connectrpc.http.HTTPRequest
- no longer has
messageorhttpMethodproperties- for stream operations, method was always "POST" and message was always null/not applicable
- for unary operations, there is now a sub-class
UnaryHTTPRequestwhich adds these two properties
- constructor updated to no longer accept message or http method
clonemethod updated to no longer accept message or http method
com.connectrpc.http.HTTPResponse
- added
status: Int?property to indicate the numeric HTTP response code - removed
codeandtracingInfopropertiestracingInforeplaced by newstatuspropertycodeis not needed; it is provided by code property ofcauseor inferred from newstatusproperty
- constructor updated to accept status and no longer accept code and tracing info
com.connectrpc.http.Stream
- now an interface, not a class
- otherwise, same API except:
- methods
send,sendClose, andreceiveCloseare now suspend methods isClosedmethod removed; useisReceiveClosedinstead
- methods
- there is also a
Streamfactory function with same signature as previous class constructor except that all three callbacks are now suspend functions
com.connectrpc.okhttp.ConnectOkHttpClient
- updated to conform to changes to
HTTPClientInterface
com.connectrpc.extensions.GoogleJavaJSONStrategy
- added optional constructor parameter:
registry: com.google.protobuf.TypeRegistry
com.connectrpc.extensions.GoogleJavaProtobufStrategy
- added optional constructor parameter:
registry: com.google.protobuf.ExtensionRegistryLite
com.connectrpc.extensions.GoogleJavaLiteProtobufStrategy
- added optional constructor parameter:
registry: com.google.protobuf.ExtensionRegistryLite
Full Changelog: v0.4.0...v0.5.0
v0.4.0
What's Changed
Enhancements
- Add support for accessing headers and trailers to streaming calls by @jhump in #171
- Add method stream type to generated code by @pkwarren in #172
Bugfixes
- Mark duplex streaming bodies as one shot by @pkwarren in #155
- Fix URL resolution when base URI has non-empty path by @pkwarren in #173
Other changes
- Add conformance tests for lite runtime by @pkwarren in #148
- Upgrade Gradle to 8.5 by @pkwarren in #170
New Contributors
Full Changelog: v0.3.1...v0.4.0