Skip to content

when only 1 redis backend is set, rkv get query returns unexpected error "the number of nodes is 1, which means there is no replica" #54

@h-w-chen

Description

@h-w-chen

after posting values for a specific key, query of its value returns unexpected response: the number of nodes is 1, which means there is no replica

What is expected: the latest value of the key
What is specific: only one (the local) redis is set up

How to reproduce

  1. set up the local redis server, e.g. listening at 127.0.0.1:16378
  2. modify config.json file accordingly like below
{
    "ConsistentHash": "rendezvous",
    "BucketSize": 10,
    "ReplicaNum": 1,
    "StoreType": "redis",
    "Concurrent": true,
    "Stores": [
        {
            "RegionType": "local",
            "Name": "store1",
            "Host": "127.0.0.1",
            "Port": 16378
        }
    ]
}
  1. start rkv server
  2. run command to post value of key curl -X POST 127.0.0.1:8090/kv -d '{"key":"testk", "value":"testv"}'; notice the response is The key value pair (testk,testv) has been saved as revision 6 at 127.0.0.1:16378, assuming success
  3. run command to get back its value curl 127.0.0.1:8090/kv?key=testk
    the response is
the number of nodes is 1, which means there is no replica

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions