Fix status code
This commit is contained in:
parent
9063159a64
commit
4e2e1e8c8e
@ -587,7 +587,7 @@ public class GrpcConnection extends BaseConnection implements RocksDBAPI {
|
||||
var desc = statusRuntimeException.getStatus().getDescription();
|
||||
var closeIndex = desc.indexOf(']');
|
||||
var errorCode = desc.substring(grpcRocksDbErrorPrefixString.length(), closeIndex);
|
||||
var errorDescription = desc.substring(closeIndex + 1);
|
||||
var errorDescription = desc.substring(closeIndex + 2);
|
||||
return RocksDBException.of(RocksDBErrorType.valueOf(errorCode), errorDescription);
|
||||
} else {
|
||||
return t;
|
||||
|
@ -301,7 +301,6 @@ public class GrpcServer extends Server {
|
||||
@Override
|
||||
public Mono<Changed> putGetChanged(PutRequest request) {
|
||||
return executeSync(() -> {
|
||||
if(true) throw new RocksDBRetryException();
|
||||
try (var arena = Arena.ofConfined()) {
|
||||
var changed = api.put(arena,
|
||||
request.getTransactionOrUpdateId(),
|
||||
|
Loading…
Reference in New Issue
Block a user