I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1802: grpc_call_start_batch(call=05BEFFD8, ops=05EFED58, nops=6, tag=05BC64E0, reserved=00000000) I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1445: ops[0]: SEND_INITIAL_METADATA(nil) I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1445: ops[1]: SEND_MESSAGE ptr=05BDAFD0 I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1445: ops[2]: SEND_CLOSE_FROM_CLIENT I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1445: ops[3]: RECV_INITIAL_METADATA ptr=05BC64FC I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1445: ops[4]: RECV_MESSAGE ptr=05BC6508 I0804 13:52:46.505722 0 C:\jenkins\workspace\gRPC_build_artifacts\platform\windows\workspace_csharp_ext_windows_x86\src\core\lib\surface\call.c:1445: ops[5]: RECV_STATUS_ON_CLIENT metadata=05BC650C status=05BC6518 details=05BC651C
GRPC通道繼續開放,在C#
我很困惑,爲什麼GRPC通話記錄之間的消息SEND_CLOSE_FROM_CLIENT時,我認爲TCP連接保持開放。
本質上,我只是有一個隨機類與構造函數打開客戶端通道到gRPC服務器。在這個類中調用的方法中,每個迭代都有一個內部調用RPC方法的循環。但是,這很慢,我認爲這是因爲它每次嘗試進行RPC調用時都會創建連接。
如何讓連接保持打開狀態?這是雙向流式傳輸的情況嗎?
感謝澄清,你是對的。 – harmonickey