mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 17:19:15 +08:00
refactor(scheduler): improve code reusability and consumer logs (#3712)
This commit is contained in:
@ -596,7 +596,12 @@ impl super::RedisConnectionPool {
|
||||
None => self.pool.xread_map(count, block, streams, ids).await,
|
||||
}
|
||||
.into_report()
|
||||
.change_context(errors::RedisError::StreamReadFailed)
|
||||
.map_err(|err| match err.current_context().kind() {
|
||||
RedisErrorKind::NotFound | RedisErrorKind::Parse => {
|
||||
err.change_context(errors::RedisError::StreamEmptyOrNotAvailable)
|
||||
}
|
||||
_ => err.change_context(errors::RedisError::StreamReadFailed),
|
||||
})
|
||||
}
|
||||
|
||||
// Consumer Group API
|
||||
|
||||
Reference in New Issue
Block a user