Struct etcd_client::ClusterClient
source · pub struct ClusterClient { /* private fields */ }
Expand description
Client for Cluster operations.
Implementations§
source§impl ClusterClient
impl ClusterClient
sourcepub async fn member_add(
&mut self,
urls: impl Into<Vec<String>>,
options: Option<MemberAddOptions>,
) -> Result<MemberAddResponse, Error>
pub async fn member_add( &mut self, urls: impl Into<Vec<String>>, options: Option<MemberAddOptions>, ) -> Result<MemberAddResponse, Error>
Adds a new member into the cluster.
sourcepub async fn member_remove(
&mut self,
id: u64,
) -> Result<MemberRemoveResponse, Error>
pub async fn member_remove( &mut self, id: u64, ) -> Result<MemberRemoveResponse, Error>
Removes an existing member from the cluster.
sourcepub async fn member_update(
&mut self,
id: u64,
url: impl Into<Vec<String>>,
) -> Result<MemberUpdateResponse, Error>
pub async fn member_update( &mut self, id: u64, url: impl Into<Vec<String>>, ) -> Result<MemberUpdateResponse, Error>
Updates the member configuration.
sourcepub async fn member_list(&mut self) -> Result<MemberListResponse, Error>
pub async fn member_list(&mut self) -> Result<MemberListResponse, Error>
Lists all the members in the cluster.
sourcepub async fn member_promote(
&mut self,
id: u64,
) -> Result<MemberPromoteResponse, Error>
pub async fn member_promote( &mut self, id: u64, ) -> Result<MemberPromoteResponse, Error>
Promotes a member from raft learner (non-voting) to raft voting member.
Trait Implementations§
source§impl Clone for ClusterClient
impl Clone for ClusterClient
source§fn clone(&self) -> ClusterClient
fn clone(&self) -> ClusterClient
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl !Freeze for ClusterClient
impl !RefUnwindSafe for ClusterClient
impl Send for ClusterClient
impl Sync for ClusterClient
impl Unpin for ClusterClient
impl !UnwindSafe for ClusterClient
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request