update to latest versions

This commit is contained in:
Alex Zenla
2024-11-03 03:51:25 -05:00
parent 2e5a37ea4b
commit 8ee3c4c977
26 changed files with 165 additions and 418 deletions

View File

@ -1,25 +1,10 @@
//
// DO NOT EDIT.
// swift-format-ignore-file
//
// Generated by the protocol buffer compiler.
// Source: metadata.proto
//
//
// Copyright 2018, gRPC Authors All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
import GRPC
import NIO
import NIOConcurrencyHelpers
@ -61,10 +46,8 @@ extension SdServerMetadataServiceClientProtocol {
}
}
#if compiler(>=5.6)
@available(*, deprecated)
extension SdServerMetadataServiceClient: @unchecked Sendable {}
#endif // compiler(>=5.6)
@available(*, deprecated, renamed: "SdServerMetadataServiceNIOClient")
public final class SdServerMetadataServiceClient: SdServerMetadataServiceClientProtocol {
@ -120,7 +103,6 @@ public struct SdServerMetadataServiceNIOClient: SdServerMetadataServiceClientPro
}
}
#if compiler(>=5.6)
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
public protocol SdServerMetadataServiceAsyncClientProtocol: GRPCClient {
static var serviceDescriptor: GRPCServiceDescriptor { get }
@ -187,9 +169,7 @@ public struct SdServerMetadataServiceAsyncClient: SdServerMetadataServiceAsyncCl
}
}
#endif // compiler(>=5.6)
public protocol SdServerMetadataServiceClientInterceptorFactoryProtocol: GRPCSendable {
public protocol SdServerMetadataServiceClientInterceptorFactoryProtocol: Sendable {
/// - Returns: Interceptors to use when invoking 'getServerMetadata'.
func makeGetServerMetadataInterceptors() -> [ClientInterceptor<SdGetServerMetadataRequest, SdGetServerMetadataResponse>]
@ -247,15 +227,13 @@ extension SdServerMetadataServiceProvider {
}
}
#if compiler(>=5.6)
/// To implement a server, implement an object which conforms to this protocol.
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
public protocol SdServerMetadataServiceAsyncProvider: CallHandlerProvider {
public protocol SdServerMetadataServiceAsyncProvider: CallHandlerProvider, Sendable {
static var serviceDescriptor: GRPCServiceDescriptor { get }
var interceptors: SdServerMetadataServiceServerInterceptorFactoryProtocol? { get }
@Sendable func getServerMetadata(
func getServerMetadata(
request: SdGetServerMetadataRequest,
context: GRPCAsyncServerCallContext
) async throws -> SdGetServerMetadataResponse
@ -286,7 +264,7 @@ extension SdServerMetadataServiceAsyncProvider {
requestDeserializer: ProtobufDeserializer<SdGetServerMetadataRequest>(),
responseSerializer: ProtobufSerializer<SdGetServerMetadataResponse>(),
interceptors: self.interceptors?.makeGetServerMetadataInterceptors() ?? [],
wrapping: self.getServerMetadata(request:context:)
wrapping: { try await self.getServerMetadata(request: $0, context: $1) }
)
default:
@ -295,9 +273,7 @@ extension SdServerMetadataServiceAsyncProvider {
}
}
#endif // compiler(>=5.6)
public protocol SdServerMetadataServiceServerInterceptorFactoryProtocol {
public protocol SdServerMetadataServiceServerInterceptorFactoryProtocol: Sendable {
/// - Returns: Interceptors to use when handling 'getServerMetadata'.
/// Defaults to calling `self.makeInterceptors()`.