Decodes an exception from HBase 0.95 and up HBasePB.NameBytesPair. @param pair A pair whose name is the exception type, and whose value is the stringified stack trace.
(final HBaseRpc request,
final HBasePB.NameBytesPair pair)
| 1821 | * the stringified stack trace. |
| 1822 | */ |
| 1823 | static HBaseException decodeExceptionPair(final HBaseRpc request, |
| 1824 | final HBasePB.NameBytesPair pair) { |
| 1825 | final String stacktrace; |
| 1826 | if (pair.hasValue()) { |
| 1827 | stacktrace = pair.getValue().toStringUtf8(); |
| 1828 | } else { |
| 1829 | stacktrace = "(missing server-side stack trace)"; // Shouldn't happen. |
| 1830 | } |
| 1831 | return makeException(request, pair.getName(), stacktrace); |
| 1832 | } |
| 1833 | |
| 1834 | /** |
| 1835 | * De-serializes a "Writable" serialized by |
no test coverage detected