-
Notifications
You must be signed in to change notification settings - Fork 3
RPC Protocol Description
Remote Procedure Call Binary Structure
Call type:
Procedure Call
Return Value
Exception Throw
Binary Message
Recipient ID:
ID retrieved from resource monitor
Perhaps reserved ID for broadcast
Parameters:
Length
Type
Data
Id:
call count
Timestamp
Registration Details:
Procedure Name
Parameter Datatypes
Suede:RPC
Binary Protocol Description
Each RPC message is converted to a binary stream for transmission. The binary structure is constructed according to the following description.
Call Type: 2 bits
0x0 Reserved
0x1 Procedure Call
0x2 Return
0x3 Exception Throw
Reserved: 6 bits
Reserved for Future development, such as idempotency , encryption keys, source validation, checksums, Time Validation, etc.-
Call ID (Count): 16 bits
unsigned count for this call with these parameters.
Remaining bits are specific to message type
Procedure Call
Parameter Count: 8 bits
Parameter type: 8 bits
Parameter Byte Length: 24 bits
Parameter: Parameter Byte Length x 8 bits
Second Parameter type: 8 bits
…
After end of last parameter, a “/n” character byte should be placed to verify valid end of RPC
Return
Return type: 8 bits
Return Byte Length: 24 bits
Return Value: Return Byte Length x 8 bits
After end of return value, a “/n” character byte should be placed to verify valid end of RPC
Exception Throw
Error Code: 8 bits
Message Byte Length: 24 bits
Error Message: Message Byte Length x 8 bits
After end of error message, a “/n” character byte should be placed to verify valid end of RPC