MCPcopy Create free account
hub / github.com/apache/brpc / OwnerOfKey

Method OwnerOfKey

test/brpc_redis_cluster_unittest.cpp:138–144  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

136 }
137
138 int OwnerOfKey(const std::string& key) const {
139 std::unordered_map<std::string, int>::const_iterator it = owner_override.find(key);
140 if (it != owner_override.end()) {
141 return it->second;
142 }
143 return OwnerBySlot(HashSlot(key));
144 }
145};
146
147struct NodeData {

Callers 1

RunMethod · 0.80

Calls 4

OwnerBySlotFunction · 0.85
HashSlotFunction · 0.85
findMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected