Send one message to the target server. The operation is non-blocking -- it does not guarantee the payloads have reached the target or even have left the sender process. However, all the payloads (i.e., data and arrays) can be safely freed after this function returns. The data b
(msg, target)
| 1045 | |
| 1046 | |
| 1047 | def send_rpc_message(msg, target): |
| 1048 | """Send one message to the target server. |
| 1049 | |
| 1050 | The operation is non-blocking -- it does not guarantee the payloads have |
| 1051 | reached the target or even have left the sender process. However, |
| 1052 | all the payloads (i.e., data and arrays) can be safely freed after this |
| 1053 | function returns. |
| 1054 | |
| 1055 | The data buffer in the requst will be copied to internal buffer for actual |
| 1056 | transmission, while no memory copy for tensor payloads (a.k.a. zero-copy). |
| 1057 | The underlying sending threads will hold references to the tensors until |
| 1058 | the contents have been transmitted. |
| 1059 | |
| 1060 | Parameters |
| 1061 | ---------- |
| 1062 | msg : RPCMessage |
| 1063 | The message to send. |
| 1064 | target : int |
| 1065 | target ID |
| 1066 | |
| 1067 | Raises |
| 1068 | ------ |
| 1069 | ConnectionError if there is any problem with the connection. |
| 1070 | """ |
| 1071 | _CAPI_DGLRPCSendRPCMessage(msg, int(target)) |
| 1072 | |
| 1073 | |
| 1074 | def recv_rpc_message(timeout=0): |
no outgoing calls
no test coverage detected