problem: when an upstream grpc returns error it isn't handled and dshackle returns the default error with "no available upstream"

This commit is contained in:
Igor Artamonov
2022-06-23 21:34:07 -04:00
parent 3ecccfe6ce
commit cdf3e90877
2 changed files with 41 additions and 2 deletions

View File

@@ -130,8 +130,9 @@ class QuorumRpcReader(
.flatMap { response ->
response.requireResult()
.transform(withSignature(api, key, response))
.transform(withErrorResume(api, key))
}
// must catch not only the processing of a response but also errors thrown from the .read() call
.transform(withErrorResume(api, key))
.map { Tuples.of(it.t1, it.t2, api) }
}