gRPC Java 1.57.0 Release Notes
This release accidentally broke Java 8: NoSuchMethodError
for some ByteBuffer methods. The issue is tracked in #10432 and fixed in 1.57.1.
API Changes
- Use fully qualified java.lang.String in all cases in generated code. This fixes compilation if a protobuf message is named “String”.
- Stabilize io.grpc.Status.asRuntimeException(Metadata) and trailersFromThrowable
- Stabilize io.grpc.ManagedChannelBuilder.useTransportSecurity (#10244)
- Stabilize io.grpc.util.MutableHandlerRegistry (#10348)
Behavior Changes
- api: CheckedForwardingClientCall now passes trailers from the caught exception
- context, api: Package io.grpc is now consolidated into a single artifact grpc-api by moving classes from grpc-context to grpc-api. grpc-context now has a dependency on grpc-api (but excludes other dependencies of grpc-api) so any application previously using only grpc-context will now also bring in grpc-api. This fixes #3522 which was the major issue preventing support of Java modules. We are not done fixing support, as some artifacts need to be split and Automatic-Module-Name needs to be added. The next release is likely to be more stable for modules.
- core: Change delay for hedging retry after a non-fatal error to be 0 to match the gRFC (A6).
- core: Wrap other name resolver types in a RetryingNameResolver . Previously, if authority was not overridden, then some name resolvers (such as grpclb) had no retry.
- xds: Handle loops and duplicates in xds Aggregate clusters
- xds: require EDS service name in CDS resources with an xdstp name
- xds: Use Rule order instead of RuleChain
- xds: Environment variable "GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT" is no longer respected, so xDS security cannot be disabled any more (#10243)
New Features
- binder: Add
UserHandle
andBinderChannelCredentials
to support cross-user communication (#10197) - xds,orca: LRS named metrics support
Improvements
- core: Resolve isAndroid only once on class loading. This can improve channel creation performance on Android.
- xds: Pick a subchannel with new static stride scheduler in WeightedRoundRobinLoadBalancer
Bug Fixes
- xds: Fix the server sending a GOAWAY when an LDS update with no changes other than ordering is received.
- netty: Fix NPE when a header with errors is received with endStream=true. This was causing logs to be filled with errors when health checkers didn’t specify a content type.
- okhttp: Fix the Socket data race when shutdown/closed during connecting that was causing a significant delay
Dependencies
- Upgraded Netty to 4.1.93-Final
- Update guava dependency to 32.0.1 to address CVE-2023-2976
Acknowledgements
- Benjamin Peterson
- Masakuni Oishi
- Philip K. Warren
- Stephane Landelle