Skip to content

Commit 1cde9ee

Browse files
authored
Make path available in async calls (#1462)
1 parent 4c63368 commit 1cde9ee

File tree

4 files changed

+20
-0
lines changed

4 files changed

+20
-0
lines changed

Sources/GRPC/AsyncAwaitSupport/GRPCAsyncBidirectionalStreamingCall.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ public struct GRPCAsyncBidirectionalStreamingCall<Request: Sendable, Response: S
3535
return self.call.options
3636
}
3737

38+
/// The path used to make the RPC.
39+
public var path: String {
40+
return self.call.path
41+
}
42+
3843
/// Cancel this RPC if it hasn't already completed.
3944
public func cancel() {
4045
self.call.cancel(promise: nil)

Sources/GRPC/AsyncAwaitSupport/GRPCAsyncClientStreamingCall.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@ public struct GRPCAsyncClientStreamingCall<Request: Sendable, Response: Sendable
3131
return self.call.options
3232
}
3333

34+
/// The path used to make the RPC.
35+
public var path: String {
36+
return self.call.path
37+
}
38+
3439
/// Cancel this RPC if it hasn't already completed.
3540
public func cancel() {
3641
self.call.cancel(promise: nil)

Sources/GRPC/AsyncAwaitSupport/GRPCAsyncServerStreamingCall.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ public struct GRPCAsyncServerStreamingCall<Request: Sendable, Response: Sendable
3232
return self.call.options
3333
}
3434

35+
/// The path used to make the RPC.
36+
public var path: String {
37+
return self.call.path
38+
}
39+
3540
/// Cancel this RPC if it hasn't already completed.
3641
public func cancel() {
3742
self.call.cancel(promise: nil)

Sources/GRPC/AsyncAwaitSupport/GRPCAsyncUnaryCall.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@ public struct GRPCAsyncUnaryCall<Request: Sendable, Response: Sendable>: Sendabl
3131
self.call.options
3232
}
3333

34+
/// The path used to make the RPC.
35+
public var path: String {
36+
self.call.path
37+
}
38+
3439
/// Cancel this RPC if it hasn't already completed.
3540
public func cancel() {
3641
self.call.cancel(promise: nil)

0 commit comments

Comments
 (0)