Skip to content

Unable to get an error while using opsForHash().get() command #2210

Closed

Description

@MariaNosareva

Hi,
I came across some strange behavior while working with ReactiveHashOperations: it seems that there is no error propagation in the case of getting value from hash by only one key (.get(key) method).

result = cmd.hget(command.getKey(), key.duplicate()).map(value -> KeyValue.fromNullable(key, value))
.map(Collections::singletonList).onErrorReturn(Collections.emptyList());

For example, if the service has trouble reconnecting to Redis, the endpoint user of that method will never know if any problems exist. But in the case of using .multiGet() (uses the same method under the hood - hMGet()) there is no such issue, all errors are delivered well.

Is there any chance of changing this behavior?

Thanks!

Activity

  1. self-assigned this
    on Dec 10, 2021
  2. mp911de commented on Dec 10, 2021

    @mp911de
    Member

    Thanks for reporting the issue. It is indeed a regression in which the empty response should return a collection with an empty element.

  3. added a commit that references this issue on Dec 10, 2021
    dd42326
  4. added a commit that references this issue on Dec 10, 2021
    33ffc9f
  5. added this to the 2.5.8 (2021.0.8) milestone on Dec 10, 2021
  6. added a commit that references this issue on Apr 26, 2024
    9a56c38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

type: regressionA regression from a previous release

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions