pub struct ClusterManager { /* private fields */ }Expand description
Implements a client for the Kubernetes Engine API.
§Service Description
Google Kubernetes Engine Cluster Manager v1
§Configuration
ClusterManager has various configuration parameters, the defaults should
work with most applications.
§Pooling and Cloning
ClusterManager holds a connection pool internally, it is advised to
create one and the reuse it. You do not need to wrap ClusterManager in
an Rc or Arc to reuse it, because it already uses an Arc
internally.
Implementations§
Source§impl ClusterManager
impl ClusterManager
Sourcepub async fn new_with_config(conf: ClientConfig) -> Result<Self>
pub async fn new_with_config(conf: ClientConfig) -> Result<Self>
Creates a new client with the specified configuration.
Sourcepub fn from_stub<T>(stub: T) -> Selfwhere
T: ClusterManager + 'static,
pub fn from_stub<T>(stub: T) -> Selfwhere
T: ClusterManager + 'static,
Creates a new client from the provided stub.
The most common case for calling this function is when mocking the client.
Sourcepub fn list_clusters(&self, parent: impl Into<String>) -> ListClusters
pub fn list_clusters(&self, parent: impl Into<String>) -> ListClusters
Lists all clusters owned by a project in either the specified zone or all zones.
Sourcepub fn get_cluster(&self, name: impl Into<String>) -> GetCluster
pub fn get_cluster(&self, name: impl Into<String>) -> GetCluster
Gets the details of a specific cluster.
Sourcepub fn create_cluster(&self, parent: impl Into<String>) -> CreateCluster
pub fn create_cluster(&self, parent: impl Into<String>) -> CreateCluster
Creates a cluster, consisting of the specified number and type of Google Compute Engine instances.
By default, the cluster is created in the project’s default network.
One firewall is added for the cluster. After cluster creation, the Kubelet creates routes for each node to allow the containers on that node to communicate with all other instances in the cluster.
Finally, an entry is added to the project’s global metadata indicating which CIDR range the cluster is using.
Sourcepub fn update_cluster(&self, name: impl Into<String>) -> UpdateCluster
pub fn update_cluster(&self, name: impl Into<String>) -> UpdateCluster
Updates the settings of a specific cluster.
Sourcepub fn update_node_pool(&self, name: impl Into<String>) -> UpdateNodePool
pub fn update_node_pool(&self, name: impl Into<String>) -> UpdateNodePool
Updates the version and/or image type for the specified node pool.
Sourcepub fn set_node_pool_autoscaling(
&self,
name: impl Into<String>,
) -> SetNodePoolAutoscaling
pub fn set_node_pool_autoscaling( &self, name: impl Into<String>, ) -> SetNodePoolAutoscaling
Sets the autoscaling settings for the specified node pool.
Sourcepub fn set_logging_service(&self, name: impl Into<String>) -> SetLoggingService
pub fn set_logging_service(&self, name: impl Into<String>) -> SetLoggingService
Sets the logging service for a specific cluster.
Sourcepub fn set_monitoring_service(
&self,
name: impl Into<String>,
) -> SetMonitoringService
pub fn set_monitoring_service( &self, name: impl Into<String>, ) -> SetMonitoringService
Sets the monitoring service for a specific cluster.
Sourcepub fn set_addons_config(&self, name: impl Into<String>) -> SetAddonsConfig
pub fn set_addons_config(&self, name: impl Into<String>) -> SetAddonsConfig
Sets the addons for a specific cluster.
Sourcepub fn set_locations(&self, name: impl Into<String>) -> SetLocations
pub fn set_locations(&self, name: impl Into<String>) -> SetLocations
Sets the locations for a specific cluster. Deprecated. Use projects.locations.clusters.update instead.
Sourcepub fn update_master(&self, name: impl Into<String>) -> UpdateMaster
pub fn update_master(&self, name: impl Into<String>) -> UpdateMaster
Updates the master for a specific cluster.
Sourcepub fn set_master_auth(&self, name: impl Into<String>) -> SetMasterAuth
pub fn set_master_auth(&self, name: impl Into<String>) -> SetMasterAuth
Sets master auth materials. Currently supports changing the admin password or a specific cluster, either via password generation or explicitly setting the password.
Sourcepub fn delete_cluster(&self, name: impl Into<String>) -> DeleteCluster
pub fn delete_cluster(&self, name: impl Into<String>) -> DeleteCluster
Deletes the cluster, including the Kubernetes endpoint and all worker nodes.
Firewalls and routes that were configured during cluster creation are also deleted.
Other Google Compute Engine resources that might be in use by the cluster, such as load balancer resources, are not deleted if they weren’t present when the cluster was initially created.
Sourcepub fn list_operations(&self, parent: impl Into<String>) -> ListOperations
pub fn list_operations(&self, parent: impl Into<String>) -> ListOperations
Lists all operations in a project in a specific zone or all zones.
Sourcepub fn get_operation(&self, name: impl Into<String>) -> GetOperation
pub fn get_operation(&self, name: impl Into<String>) -> GetOperation
Gets the specified operation.
Sourcepub fn cancel_operation(&self, name: impl Into<String>) -> CancelOperation
pub fn cancel_operation(&self, name: impl Into<String>) -> CancelOperation
Cancels the specified operation.
Sourcepub fn get_server_config(&self, name: impl Into<String>) -> GetServerConfig
pub fn get_server_config(&self, name: impl Into<String>) -> GetServerConfig
Returns configuration info about the Google Kubernetes Engine service.
Sourcepub fn get_json_web_keys(&self, parent: impl Into<String>) -> GetJSONWebKeys
pub fn get_json_web_keys(&self, parent: impl Into<String>) -> GetJSONWebKeys
Gets the public component of the cluster signing keys in JSON Web Key format.
Sourcepub fn list_node_pools(&self, parent: impl Into<String>) -> ListNodePools
pub fn list_node_pools(&self, parent: impl Into<String>) -> ListNodePools
Lists the node pools for a cluster.
Sourcepub fn get_node_pool(&self, name: impl Into<String>) -> GetNodePool
pub fn get_node_pool(&self, name: impl Into<String>) -> GetNodePool
Retrieves the requested node pool.
Sourcepub fn create_node_pool(&self, parent: impl Into<String>) -> CreateNodePool
pub fn create_node_pool(&self, parent: impl Into<String>) -> CreateNodePool
Creates a node pool for a cluster.
Sourcepub fn delete_node_pool(&self, name: impl Into<String>) -> DeleteNodePool
pub fn delete_node_pool(&self, name: impl Into<String>) -> DeleteNodePool
Deletes a node pool from a cluster.
Sourcepub fn complete_node_pool_upgrade(
&self,
name: impl Into<String>,
) -> CompleteNodePoolUpgrade
pub fn complete_node_pool_upgrade( &self, name: impl Into<String>, ) -> CompleteNodePoolUpgrade
CompleteNodePoolUpgrade will signal an on-going node pool upgrade to complete.
Sourcepub fn rollback_node_pool_upgrade(
&self,
name: impl Into<String>,
) -> RollbackNodePoolUpgrade
pub fn rollback_node_pool_upgrade( &self, name: impl Into<String>, ) -> RollbackNodePoolUpgrade
Rolls back a previously Aborted or Failed NodePool upgrade. This makes no changes if the last upgrade successfully completed.
Sourcepub fn set_node_pool_management(
&self,
name: impl Into<String>,
) -> SetNodePoolManagement
pub fn set_node_pool_management( &self, name: impl Into<String>, ) -> SetNodePoolManagement
Sets the NodeManagement options for a node pool.
Sourcepub fn set_labels(&self, name: impl Into<String>) -> SetLabels
pub fn set_labels(&self, name: impl Into<String>) -> SetLabels
Sets labels on a cluster.
Sourcepub fn set_legacy_abac(&self, name: impl Into<String>) -> SetLegacyAbac
pub fn set_legacy_abac(&self, name: impl Into<String>) -> SetLegacyAbac
Enables or disables the ABAC authorization mechanism on a cluster.
Sourcepub fn start_ip_rotation(&self, name: impl Into<String>) -> StartIPRotation
pub fn start_ip_rotation(&self, name: impl Into<String>) -> StartIPRotation
Starts master IP rotation.
Sourcepub fn complete_ip_rotation(
&self,
name: impl Into<String>,
) -> CompleteIPRotation
pub fn complete_ip_rotation( &self, name: impl Into<String>, ) -> CompleteIPRotation
Completes master IP rotation.
Sourcepub fn set_node_pool_size(&self, name: impl Into<String>) -> SetNodePoolSize
pub fn set_node_pool_size(&self, name: impl Into<String>) -> SetNodePoolSize
Sets the size for a specific node pool. The new size will be used for all replicas, including future replicas created by modifying NodePool.locations.
Sourcepub fn set_network_policy(&self, name: impl Into<String>) -> SetNetworkPolicy
pub fn set_network_policy(&self, name: impl Into<String>) -> SetNetworkPolicy
Enables or disables Network Policy for a cluster.
Sourcepub fn set_maintenance_policy(
&self,
name: impl Into<String>,
) -> SetMaintenancePolicy
pub fn set_maintenance_policy( &self, name: impl Into<String>, ) -> SetMaintenancePolicy
Sets the maintenance policy for a cluster.
Sourcepub fn list_usable_subnetworks(
&self,
parent: impl Into<String>,
) -> ListUsableSubnetworks
pub fn list_usable_subnetworks( &self, parent: impl Into<String>, ) -> ListUsableSubnetworks
Lists subnetworks that are usable for creating clusters in a project.
Sourcepub fn check_autopilot_compatibility(
&self,
name: impl Into<String>,
) -> CheckAutopilotCompatibility
pub fn check_autopilot_compatibility( &self, name: impl Into<String>, ) -> CheckAutopilotCompatibility
Checks the cluster compatibility with Autopilot mode, and returns a list of compatibility issues.
Trait Implementations§
Source§impl Clone for ClusterManager
impl Clone for ClusterManager
Source§fn clone(&self) -> ClusterManager
fn clone(&self) -> ClusterManager
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more