io.grpc.Status vs

Hi Stefano,

Thanks for the response! I just have a few questions that stem from your response.

Q1 . You mention that is used in the specific context of the Command Completion Service stream of completed commands. Would it be safe to imply that in every other context, we should be using io.grpc.Status?

Q2 . Having done some toying with the Command Service and the Command Completion Service, I found that having submitted a request using the Command Service, one could expect a response from the Command Completion Service if they were subscribed. This validated my understanding that the Command Service is a wrapper of the Command Submission Service and the Command Completion Service. With this in mind, if a transaction was submitted to the Command Service and failed, for example due to an assertion failure during execution, would we expect the same gRPC Error Code and Error Message in the Command Completion Service? This would be unusual considering I would handle an error from the Command Service using io.grpc.Status, whereas I would be using for the Command Completion Response. Are we guaranteed to have the same error description/message?

Q3. More on the topic of Command Service as a wrapper of the Command Submission Service and Command Completion Service. Based on the Command Service documentation: daml/command_service.proto at cda93db944afe55d987ba8b7d5326e256ae359cf · digital-asset/daml · GitHub , we see that there is a RESOURCE_EXHAUSTED error return if the number of in-flight commands reaches a maximum, and we have a limit set, which is also confirmed by Robert in When is RESOURCE_EXHAUSTED returned by the command submission/completion services? - #2 by Robert_Autenrieth . From our own research using Daml on VMWare Blockchain (VMBC), we have identified two other scenarios where RESOURCE_EXHAUSTED occurs: backpressure on client nodes, backpressure on replicas. Would the ‘in-flight’ commands issue imply there is a third scenario under which RESOURCE_EXHAUSTED might occur and is this exclusive to the Command Service?

Thank you!


1 Like