#[non_exhaustive]pub struct Instance {Show 18 fields
pub name: String,
pub display_name: String,
pub labels: HashMap<String, String>,
pub authorized_network: String,
pub zones: Vec<String>,
pub node_count: i32,
pub node_config: Option<NodeConfig>,
pub memcache_version: MemcacheVersion,
pub parameters: Option<MemcacheParameters>,
pub memcache_nodes: Vec<Node>,
pub create_time: Option<Timestamp>,
pub update_time: Option<Timestamp>,
pub state: State,
pub memcache_full_version: String,
pub instance_messages: Vec<InstanceMessage>,
pub discovery_endpoint: String,
pub maintenance_policy: Option<MaintenancePolicy>,
pub maintenance_schedule: Option<MaintenanceSchedule>,
/* private fields */
}Expand description
A Memorystore for Memcached instance
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringRequired. Unique name of the resource in this scope including project and
location using the form:
projects/{project_id}/locations/{location_id}/instances/{instance_id}
Note: Memcached instances are managed and addressed at the regional level
so location_id here refers to a Google Cloud region; however, users may
choose which zones Memcached nodes should be provisioned in within an
instance. Refer to zones field for more details.
display_name: StringUser provided name for the instance, which is only used for display purposes. Cannot be more than 80 characters.
labels: HashMap<String, String>Resource labels to represent user-provided metadata. Refer to cloud documentation on labels for more details. https://cloud.google.com/compute/docs/labeling-resources
The full name of the Google Compute Engine
network to which the
instance is connected. If left unspecified, the default network
will be used.
zones: Vec<String>Zones in which Memcached nodes should be provisioned. Memcached nodes will be equally distributed across these zones. If not provided, the service will by default create nodes in all zones in the region for the instance.
node_count: i32Required. Number of nodes in the Memcached instance.
node_config: Option<NodeConfig>Required. Configuration for Memcached nodes.
memcache_version: MemcacheVersionThe major version of Memcached software.
If not provided, latest supported version will be used. Currently the
latest supported major version is MEMCACHE_1_5.
The minor version will be automatically determined by our system based on
the latest supported minor version.
parameters: Option<MemcacheParameters>User defined parameters to apply to the memcached process on each node.
memcache_nodes: Vec<Node>Output only. List of Memcached nodes. Refer to Node message for more details.
create_time: Option<Timestamp>Output only. The time the instance was created.
update_time: Option<Timestamp>Output only. The time the instance was updated.
state: StateOutput only. The state of this Memcached instance.
memcache_full_version: StringOutput only. The full version of memcached server running on this instance. System automatically determines the full memcached version for an instance based on the input MemcacheVersion. The full version format will be “memcached-1.5.16”.
instance_messages: Vec<InstanceMessage>List of messages that describe the current state of the Memcached instance.
discovery_endpoint: StringOutput only. Endpoint for the Discovery API.
maintenance_policy: Option<MaintenancePolicy>The maintenance policy for the instance. If not provided, the maintenance event will be performed based on Memorystore internal rollout schedule.
maintenance_schedule: Option<MaintenanceSchedule>Output only. Published maintenance schedule.
Implementations§
Source§impl Instance
impl Instance
pub fn new() -> Self
Sourcepub fn set_display_name<T: Into<String>>(self, v: T) -> Self
pub fn set_display_name<T: Into<String>>(self, v: T) -> Self
Sets the value of display_name.
Sourcepub fn set_labels<T, K, V>(self, v: T) -> Self
pub fn set_labels<T, K, V>(self, v: T) -> Self
Sets the value of labels.
Sets the value of authorized_network.
Sourcepub fn set_node_count<T: Into<i32>>(self, v: T) -> Self
pub fn set_node_count<T: Into<i32>>(self, v: T) -> Self
Sets the value of node_count.
Sourcepub fn set_node_config<T>(self, v: T) -> Selfwhere
T: Into<NodeConfig>,
pub fn set_node_config<T>(self, v: T) -> Selfwhere
T: Into<NodeConfig>,
Sets the value of node_config.
Sourcepub fn set_or_clear_node_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<NodeConfig>,
pub fn set_or_clear_node_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<NodeConfig>,
Sets or clears the value of node_config.
Sourcepub fn set_memcache_version<T: Into<MemcacheVersion>>(self, v: T) -> Self
pub fn set_memcache_version<T: Into<MemcacheVersion>>(self, v: T) -> Self
Sets the value of memcache_version.
Sourcepub fn set_parameters<T>(self, v: T) -> Selfwhere
T: Into<MemcacheParameters>,
pub fn set_parameters<T>(self, v: T) -> Selfwhere
T: Into<MemcacheParameters>,
Sets the value of parameters.
Sourcepub fn set_or_clear_parameters<T>(self, v: Option<T>) -> Selfwhere
T: Into<MemcacheParameters>,
pub fn set_or_clear_parameters<T>(self, v: Option<T>) -> Selfwhere
T: Into<MemcacheParameters>,
Sets or clears the value of parameters.
Sourcepub fn set_memcache_nodes<T, V>(self, v: T) -> Self
pub fn set_memcache_nodes<T, V>(self, v: T) -> Self
Sets the value of memcache_nodes.
Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
Sourcepub fn set_memcache_full_version<T: Into<String>>(self, v: T) -> Self
pub fn set_memcache_full_version<T: Into<String>>(self, v: T) -> Self
Sets the value of memcache_full_version.
Sourcepub fn set_instance_messages<T, V>(self, v: T) -> Self
pub fn set_instance_messages<T, V>(self, v: T) -> Self
Sets the value of instance_messages.
Sourcepub fn set_discovery_endpoint<T: Into<String>>(self, v: T) -> Self
pub fn set_discovery_endpoint<T: Into<String>>(self, v: T) -> Self
Sets the value of discovery_endpoint.
Sourcepub fn set_maintenance_policy<T>(self, v: T) -> Selfwhere
T: Into<MaintenancePolicy>,
pub fn set_maintenance_policy<T>(self, v: T) -> Selfwhere
T: Into<MaintenancePolicy>,
Sets the value of maintenance_policy.
Sourcepub fn set_or_clear_maintenance_policy<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenancePolicy>,
pub fn set_or_clear_maintenance_policy<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenancePolicy>,
Sets or clears the value of maintenance_policy.
Sourcepub fn set_maintenance_schedule<T>(self, v: T) -> Selfwhere
T: Into<MaintenanceSchedule>,
pub fn set_maintenance_schedule<T>(self, v: T) -> Selfwhere
T: Into<MaintenanceSchedule>,
Sets the value of maintenance_schedule.
Sourcepub fn set_or_clear_maintenance_schedule<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenanceSchedule>,
pub fn set_or_clear_maintenance_schedule<T>(self, v: Option<T>) -> Selfwhere
T: Into<MaintenanceSchedule>,
Sets or clears the value of maintenance_schedule.