Rpc Error
data class RpcError(val code: Int, val message: String, val data: String = "", val cause: Throwable? = null) : Exception
Specialized error handling for RPC methods.
Instances of this type, when thrown in a RPC method handler, will have their message serialized and sent across the wire. The sender will receive an equivalent error on the other side.
Built-in types are included but developers may use any message string, with a max length of 256 bytes.