You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Failover servers work fine if we have more than 1 master node but not working for 1 master node. Replacing the server upon failure just replaces the servers in hashring and not in memcached (this.servers), so the below logic seems to be wrong.
// try to find the correct server for this query
if (!server) {
// no need to do a hashring lookup if we only have one server assigned to
// us
if (this.servers.length === 1) {
server = this.servers[0]; // -> this seems to be wrong since the this.servers is not getting updated upon servers swap
} else {
if (redundancy && queryRedundancy) {
redundancy = this.HashRing.createRange(query.key, (this.redundancy + 1), true);
server = redundancy.shift();
} else {
server = this.HashRing.get(query.key);
}
}
}
The text was updated successfully, but these errors were encountered:
Failover servers work fine if we have more than 1 master node but not working for 1 master node. Replacing the server upon failure just replaces the servers in hashring and not in memcached (this.servers), so the below logic seems to be wrong.
// try to find the correct server for this query
if (!server) {
// no need to do a hashring lookup if we only have one server assigned to
// us
if (this.servers.length === 1) {
server = this.servers[0]; // -> this seems to be wrong since the this.servers is not getting updated upon servers swap
} else {
if (redundancy && queryRedundancy) {
redundancy = this.HashRing.createRange(query.key, (this.redundancy + 1), true);
server = redundancy.shift();
} else {
server = this.HashRing.get(query.key);
}
}
}
The text was updated successfully, but these errors were encountered: