MCPcopy Create free account
hub / github.com/apache/kvrocks / GetReplicationState

Method GetReplicationState

src/server/server.cc:1858–1864  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1856}
1857
1858ReplState Server::GetReplicationState() {
1859 std::lock_guard<std::mutex> guard(slaveof_mu_);
1860 if (IsSlave() && replication_thread_) {
1861 return replication_thread_->State();
1862 }
1863 return kReplConnecting;
1864}
1865
1866StatusOr<std::unique_ptr<redis::Commander>> Server::LookupAndCreateCommand(const std::string &cmd_name) {
1867 if (cmd_name.empty()) return {Status::RedisUnknownCmd};

Callers 2

RedisGenericCommandFunction · 0.80
ExecuteCommandsMethod · 0.80

Calls 1

StateMethod · 0.80

Tested by

no test coverage detected