Skip to main content

Module error_map

Module error_map 

Source
Expand description

Total map from the Java worker’s string error codes to the Rust ErrorCode set (spec §4.1). Every known worker string maps to a variant; any UNKNOWN string falls back to WorkerUnavailable with the raw code preserved in details.worker_code so nothing is silently lost.

Functions§

map_worker_error
Map a (worker_code, message) pair from an RpcResponse::Failure error object into a structured ErrorEnvelope. worker_code is the string in the worker error’s code field; message its message field. Unknown codes are preserved (never dropped).