mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-05-20 15:00:40 +00:00
chore: debt 3696 (#3705)
This commit is contained in:
@@ -468,28 +468,24 @@ impl MetaClient {
|
||||
Ok(res)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn heartbeat_client(&self) -> Result<HeartbeatClient> {
|
||||
self.heartbeat.clone().context(NotStartedSnafu {
|
||||
name: "heartbeat_client",
|
||||
})
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn store_client(&self) -> Result<StoreClient> {
|
||||
self.store.clone().context(NotStartedSnafu {
|
||||
name: "store_client",
|
||||
})
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn lock_client(&self) -> Result<LockClient> {
|
||||
self.lock.clone().context(NotStartedSnafu {
|
||||
name: "lock_client",
|
||||
})
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn procedure_client(&self) -> Result<ProcedureClient> {
|
||||
self.procedure.clone().context(NotStartedSnafu {
|
||||
name: "procedure_client",
|
||||
@@ -502,12 +498,10 @@ impl MetaClient {
|
||||
})
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn channel_config(&self) -> &ChannelConfig {
|
||||
self.channel_manager.config()
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn id(&self) -> Id {
|
||||
self.id
|
||||
}
|
||||
|
||||
@@ -166,7 +166,7 @@ impl Election for EtcdElection {
|
||||
|
||||
if let Some(res) = receiver.message().await.context(error::EtcdFailedSnafu)? {
|
||||
if res.ttl() <= 0 {
|
||||
// Failed to keep alive, just break the loop.
|
||||
warn!("Candidate lease expired, key: {}", self.candidate_key());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user