@@ -63,7 +63,7 @@ actor GrpcClient: CustomStringConvertible {
6363 private lazy var client : FirebaseDataConnectAsyncClient ? = {
6464 do {
6565 DataConnectLogger
66- . debug ( " GrpcClient \( self . description, privacy: . private) initialization starts. " )
66+ . debug ( " GrpcClient: \( self . description, privacy: . private) initialization starts. " )
6767 let group = PlatformSupport . makeEventLoopGroup ( loopCount: threadPoolSize)
6868 let channel = try GRPCChannelPool . with (
6969 target: . host( serverSettings. host, port: serverSettings. port) ,
@@ -72,11 +72,12 @@ actor GrpcClient: CustomStringConvertible {
7272 . plaintext,
7373 eventLoopGroup: group
7474 )
75- DataConnectLogger . debug ( " GrpcClient \( self . description, privacy: . private) has been created. " )
75+ DataConnectLogger
76+ . debug ( " GrpcClient: \( self . description, privacy: . private) has been created. " )
7677 return FirebaseDataConnectAsyncClient ( channel: channel)
7778 } catch {
7879 DataConnectLogger
79- . debug ( " Error: \( error) when creating GrpcClient \( self . description, privacy: . private) . " )
80+ . debug ( " Error: \( error) when creating GrpcClient: \( self . description, privacy: . private) . " )
8081 return nil
8182 }
8283 } ( )
@@ -117,7 +118,7 @@ actor GrpcClient: CustomStringConvertible {
117118 googRequestHeaderValue = " location= \( self . connectorConfig. location) &frontend=data "
118119
119120 description = """
120- : projectId= \( projectId) \
121+ projectId= \( projectId) \
121122 connector= \( connectorConfig. connector) \
122123 host= \( serverSettings. host) \
123124 port= \( serverSettings. port) \
@@ -140,27 +141,27 @@ actor GrpcClient: CustomStringConvertible {
140141 connectorName: connectorName,
141142 request: request
142143 )
143- let requestString = try " : " + grpcRequest. jsonString ( )
144+ let requestString = try grpcRequest. jsonString ( )
144145
145146 do {
146147 DataConnectLogger
147- . debug ( " executeQuery() sends grpc request \( requestString, privacy: . private) . " )
148+ . debug ( " executeQuery() sends grpc request: \( requestString, privacy: . private) . " )
148149 let results = try await client. executeQuery ( grpcRequest, callOptions: createCallOptions ( ) )
149- let resultsString = try " : " + results. jsonString ( )
150+ let resultsString = try results. jsonString ( )
150151 DataConnectLogger
151- . debug ( " executeQuery() receives response \( resultsString, privacy: . private) . " )
152+ . debug ( " executeQuery() receives response: \( resultsString, privacy: . private) . " )
152153 // Not doing error decoding here
153154 if let decodedResults = try codec. decode ( result: results. data, asType: resultType) {
154155 return OperationResult ( data: decodedResults)
155156 } else {
156157 // In future, set this as error in OperationResult
157158 DataConnectLogger
158- . debug ( " executeQuery() response \( resultsString, privacy: . private) decode failed. " )
159+ . debug ( " executeQuery() response: \( resultsString, privacy: . private) decode failed. " )
159160 throw DataConnectError . decodeFailed
160161 }
161162 } catch {
162163 DataConnectLogger . error (
163- " executeQuery() \( requestString, privacy: . private) grpc call FAILED with \( error) . "
164+ " executeQuery(): \( requestString, privacy: . private) grpc call FAILED with \( error) . "
164165 )
165166 throw error
166167 }
@@ -183,25 +184,25 @@ actor GrpcClient: CustomStringConvertible {
183184 request: request
184185 )
185186
186- let requestString = try " : " + grpcRequest. jsonString ( )
187+ let requestString = try grpcRequest. jsonString ( )
187188
188189 do {
189190 DataConnectLogger
190- . debug ( " executeMutation() sends grpc request \( requestString, privacy: . private) . " )
191+ . debug ( " executeMutation() sends grpc request: \( requestString, privacy: . private) . " )
191192 let results = try await client. executeMutation ( grpcRequest, callOptions: createCallOptions ( ) )
192- let resultsString = try " : " + results. jsonString ( )
193+ let resultsString = try results. jsonString ( )
193194 DataConnectLogger
194- . debug ( " executeMutation() receives response \( resultsString, privacy: . private) . " )
195+ . debug ( " executeMutation() receives response: \( resultsString, privacy: . private) . " )
195196 if let decodedResults = try codec. decode ( result: results. data, asType: resultType) {
196197 return OperationResult ( data: decodedResults)
197198 } else {
198199 DataConnectLogger
199- . debug ( " executeMutation() response \( resultsString, privacy: . private) decode failed. " )
200+ . debug ( " executeMutation() response: \( resultsString, privacy: . private) decode failed. " )
200201 throw DataConnectError . decodeFailed
201202 }
202203 } catch {
203204 DataConnectLogger . error (
204- " executeMutation() \( requestString, privacy: . private) grpc call FAILED with \( error) . "
205+ " executeMutation(): \( requestString, privacy: . private) grpc call FAILED with \( error) . "
205206 )
206207 throw error
207208 }
0 commit comments