Releases: grpc/grpc-swift
gRPC Swift 1.0.0-alpha.24
This release removes all deprecated code and compatibility shims for
deprecated code. This includes the interface between gRPC and generated
server code used by versions 1.0.0-alpha.22 and earlier.
SemVer Major
- Remove deprecated and unreachable code (#1115)
SemVer Patch
- Remove support for the 'old' way of handling RPCs on the server (#1113)
- Drop the "OK" message from the static 'ok' status. (#1120)
- Fix up some documentation, start an FAQs doc (#1121)
Other Changes
gRPC Swift 1.0.0-alpha.23
This release includes two noteworthy changes that users should be aware of:
- The minimum supported version of Swift has been raised to 5.2.
- The interface between gRPC and the generated server code has changed. The old interface has been deprecated and will be removed in an upcoming release. Users are required to re-generate their server code, no other action is necessary.
SemVer Major
- Raise the minimum Swift version to 5.2 (#1106)
SemVer Minor
- Add client API for providing a custom SSL certificate verification callback (#1107, patch credit to @franck-clement-ug)
- Expose the remote address on the server interceptor context (#1081)
- Refactor how gRPC handles incoming RPCs on the server. Note that this change impacts how the generated server code and gRPC interact; users must therefore re-generate their server code. (#1093, #1095, #1097, #1098, #1100, #1101, #1110, #1105, #1102)
SemVer Patch
- Added support of the protobuf optional feature (#1084, patch credit to @azatZul)
- Compact the client 'ChannelPipeline' to reduce runtime costs (#1083)
- Avoid unnecessary (and expensive) copies of client and server interceptor contexts (#1090, #1091, #1092)
Other Changes
gRPC Swift 1.0.0-alpha.22
SemVer Major
- Drop support for Swift 5.0 (#1070)
SemVer Minor
- Allow the server to be gracefully shutdown. (#1076)
- Generate service name for the client and proto service comments (#1059)
SemVer Patch
- Only generate services described in files in the codegen request (#1058)
- Store the HTTP/2 multiplexer instead of retrieving it from the
ChannelPipeline
(#1062) - Simplify client
ChannelPipeline
setup (#1064) - Extract the logic from the
GRPCIdleHandler
into a state machine (#1068) - Merge idle and keepalive handlers to reduce optional and force casts (#1079)
- Refactor state machines to avoid generics (#1073, #1080)
- Make a bunch of server code inlinable (#1077)
- Add a unary server benchmark (#1074)
- Remove unused code (#1078)
Other Changes
gRPC Swift 1.0.0-alpha.21
This release introduces interceptors and server performance improvements.
Interceptors are a new API layer which provides users with an entry point to the request and response streams, allowing cross cutting concerns such as logging or metrics to be implemented and cleanly shared across multiple RPCs. Note that using interceptors requires client and server code to be regenerated.
This release also includes significant changes to the internal server implementation to improve performance. Notably the implementation uses HTTP/2 concepts directly rather than translating to the simpler HTTP/1 types and back, as such the HTTP/1 concepts in the public API have been deprecated and will be removed in the future. Additionally, the generic constraints on the server call handlers have changed.
SemVer Major
- Add support for client and server interceptors. This is a breaking change as it required an alteration to the
GRPCChannel
protocol. (#986, #993, #1001, #1002, #1006, #1010, #1019, #1022, #1024, #1028, #1030, #1031, #1032, #1035, #1037) - Move server (de)serialization to the server call handler resulting in a change in the generic constraints on
_BaseCallHandler
,UnaryCallHandler
,ClientStreamingCallHandler
,ServerStreamingCallHandler
andBidirectionalStreamingCallHandler
(#1046) - Remove HTTP/1 types from the public server API and switch server processing to be done on HTTP/2 concepts to avoid the cost of translating between HTTP/1 and HTTP/2 types on HTTP/2 connections. gRPC Web (HTTP/1) remains supported by translating from HTTP/1 to HTTP/2. (#1017, #1041, #1047, #1048, #1050)
- Make 'GRPCStatus' a struct (#989)
SemVer Minor
- Add new API to allow responses to be sent from server contexts without allocating a promise (#1020)
- Enforce ALPN on the server and add new API to allow it to not be required. (#1055)
SemVer Patch
- Ensure that when responses are sent from streaming contexts that they are sent on the event loop. (#1054)
- Make the description of 'RPCTimedOut' static (#1009)
- Tolerate identity compression as no compression (#1016)
- Split path strings using UTF8 (#1027)
- Provide more specific errors messages for failing channels (#984)
- Tidy up some of the logic in the server call contexts (#1018)
- Use the server hostname override as the :authority, if present (#1033)
- Fix typo in 'requestDeserializer' (#1052)
- Reduce some excessive server logging. (#1011)
- Remove duplicated code. (#1013)
Other Changes
- Add support for watchOS to the podspecs (#998, patch credit to @daltonclaybrook)
- Fixed a typo in the protoc plugin name in README (#1021, patch credit to @chigichan24)
- Add a performance benchmark with unary and bidirectional streaming tests (#990, #1003, #1004, #1012, #1043, #1045)
- Pin the formatter version (#995)
- Stop checking in Package.resolved (#1008)
- Update CocoaPods to alpha.20 (#982)
Release 0.9.2
- Fixes an issue for building with Carthage using Xcode 12
gRPC Swift 1.0.0-alpha.20
SemVer Minor
- Add an option to the client builder to configure the TLS certificate verification mode (#980)
SemVer Patch
- Fixed a bug where the client would re-establish a connection if the connection was dropped and there were no active RPCs (#967)
- Increased the client idle timeout and removed the default server idle timeout to align with defaults used by grpc/grpc (#968)
- Added log messages for when the active stream count reaches and drops below the HTTP/2 max concurrent streams limit (#974)
- Avoid the possibility of making outcalls in 'ClientCallTransport' before updating internal state (#970)
- Update the logged connection ID on transient failures (#969)
- Update formatting (#957)
Other Changes
gRPC Swift 1.0.0-alpha.19
This release includes two sets of breaking changes. The first is a result of performance work on the server, as a result server code must be regenerated. Service provider implementations are not affected by this change. The second breaking change replaces the GRPCStatus.Code
enum
with an equivalent struct
and removes the doNotUse
case.
SemVer Major
- Performance improvements to RPC handling for the server. Note: this changes requires server code to be regenerated. (#924, #925, #931, #932, #935)
- Turn
GRPCStatus.Code
into a struct and remove thedoNotUse
case (#942)
SemVer Patch
- Fixed a bug where trailers-only responses without a content-type header would result in a status code being syntesized rather than propagating any status code present in the trailers. (#927)
- Fixed a few incorrect "source" labels emitted in logs (#933)
- Added additional HTTP/2 information to logs (#938)
- Allow the gRPC module name to be customised when generating code (#945, #952)
- Fixed a few edge cases which would lead to a precondition failure in the
ConnectionManager
(#950, #953) - Update NIO version to 2.22.0 and NIOHTTP2 to 1.14.1. (#954)
- Added SwiftFormat to CI and baselined the existing codebase (#929, #936)
Other Changes
gRPC Swift 1.0.0-alpha.18
This release includes breaking changes to the ServerErrorDelegate
protocol. The functions transformLibraryError(_:)
and transformRequestHandlerError(_:)
now return the GRPCStatus
and HTTPHeaders
: this allows users to send additional metatada to clients. The original API returning just GRPCStatus
has been deprecated and will be removed prior to 1.0.0.
As part of this release, gRPC will no longer log by default. A logger must be provided to gRPC in order for logs to be emitted.
SemVer Major
- Allow the server error delegate to return
HTTPHeaders
in addition to the gRPC status in order to allow for additional metatada to be sent to the client. (#873, patch credit to @FranzBusch)
SemVer Minor
- Added configuration to allow for loggers to be specified on the client and server (#902)
- Added configuration to allow clients and servers to provide a debugging channel initializer (#908, #911)
SemVer Patch
- Mitigate an issue where insecure connections using Network.framework may stall in the event of zero-length writes. (#917)
- Removed some unnecessary copy-on-writes (#906)
- Reduced code duplication between builders and configuration (#907)
- Update to SwiftNIO HTTP/2 1.13.0 (#922)
- Switch a
numericCast
to the required type (#920)
Other Changes
gRPC Swift 1.0.0-alpha.17
This release includes changes to how gRPC Swift supports SwiftProtobuf messages. As such service code will need to be regenerated.
gRPC Swift provides support for any message types conforming to the GRPCPayload
protocol. SwiftProtobuf.Message
followed the same code path as all other message types and required conformance to GRPCPayload
. This was done by generating conformance to GRPCProtobufPayload
which provided a default implementation of the methods required by GRPCPayload
for SwiftProtobuf.Message
s. However, generating this conformance caused numerous issues and required the user to pass their message definitions to the gRPC code generator. As such we now support SwiftProtobuf.Message
separately to GRPCPayload
: generating conformance to GRPCProtobufPayload
is no longer required and users are no longer required to pass their message definitions to the gRPC code generator; only their service definitions.
SemVer Major
- Support
SwiftProtobuf.Message
without requiringGRPCProtobufPayload
conformance. This change will require users to regenerate their code in order to remove the now redundant conformance. (#886, #888, #889, #894)
SemVer Minor
- Add support for ping-based keepalive to both client and server. (#850, #893, patch credit to @SebastianThiebaud)
SemVer Patch
- Fix an aggressive assert which cause a fatal error when using
NetworkPreference.best
on older platforms (#896)
Other Changes
- Reduce the size of input in some tests (#890)
gRPC Swift 1.0.0-alpha.16
This release includes a few breaking changes in order to enable API evolution in the future.
SemVer Major
- Turn
NetworkImplementation
andNetworkPreference
enum
s intostruct
s. This will only affect users switching over these types. (#866) - Remove
GRPCStreamType
public enum which was only used as part of an error type. (#880)
SemVer Patch
- Fixed a bug where clients may hit a preconditon failure on idle connections. (#875)
- Fixed a bug where payload conformance would not be generated for nested messages. (#879)
- Provide a new codegen option to allow test clients to be generated separately from real clients. (#881)