yetitwo
05/04/2023, 9:57 PMjava
status = StatusProto.fromThrowable(e);
details = status.getDetails(0);
errorInfo = details.unpack(ErrorInfo.class);
reason = errorInfo.getReason();
metadataMap = errorInfo.getMetadataMap();
the parts that seemed very much unintuitive were knowing about StatusProto
and knowing to unpack the details
as ErrorInfo