pub struct BootstrapHandler { /* private fields */ }Expand description
Bootstrap handler for cluster initialization
Implementations§
Source§impl BootstrapHandler
impl BootstrapHandler
Sourcepub fn new(client: RestClient) -> Self
pub fn new(client: RestClient) -> Self
Create a new handler bound to the given REST client.
Sourcepub async fn create(
&self,
config: BootstrapConfig,
) -> Result<BootstrapStatusResponse>
pub async fn create( &self, config: BootstrapConfig, ) -> Result<BootstrapStatusResponse>
Initialize cluster bootstrap.
POST /v1/bootstrap. Returns the BootstrapStatusResponse
wrapper (bootstrap_status + optional local_node_info).
Sourcepub async fn status(&self) -> Result<BootstrapStatusResponse>
pub async fn status(&self) -> Result<BootstrapStatusResponse>
Get current bootstrap status.
GET /v1/bootstrap. Returns the BootstrapStatusResponse
wrapper.
Sourcepub async fn join(
&self,
config: BootstrapConfig,
) -> Result<BootstrapStatusResponse>
pub async fn join( &self, config: BootstrapConfig, ) -> Result<BootstrapStatusResponse>
Join this node to an existing cluster.
POST /v1/bootstrap/join. Returns the BootstrapStatusResponse
wrapper.
Auto Trait Implementations§
impl Freeze for BootstrapHandler
impl !RefUnwindSafe for BootstrapHandler
impl Send for BootstrapHandler
impl Sync for BootstrapHandler
impl Unpin for BootstrapHandler
impl UnsafeUnpin for BootstrapHandler
impl !UnwindSafe for BootstrapHandler
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