# Google Cloud Memorystore for Memcached API - Class Google::Cloud::Memcache::V1beta2::Instance (v0.17.0)

0.17.0 (latest) 0.16.1 0.15.1 0.14.0 0.13.0 0.12.1 0.11.0 0.10.0 0.9.2 0.8.2 0.7.0 0.6.1 0.5.0 0.4.0 0.3.0 0.2.5 Reference documentation and code samples for the Google Cloud Memorystore for Memcached API class Google::Cloud::Memcache::V1beta2::Instance.

A Memorystore for Memcached instance

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #authorized_network

    def authorized_network() -> ::String

**Returns**

- (::String) --- The full name of the Google Compute Engine [network](https://cloud.google.com/vpc/docs/vpc) to which the instance is connected. If left unspecified, the `default` network will be used.

### #authorized_network=

    def authorized_network=(value) -> ::String

**Parameter**

- **value** (::String) --- The full name of the Google Compute Engine [network](https://cloud.google.com/vpc/docs/vpc) to which the instance is connected. If left unspecified, the `default` network will be used.
**Returns**

- (::String) --- The full name of the Google Compute Engine [network](https://cloud.google.com/vpc/docs/vpc) to which the instance is connected. If left unspecified, the `default` network will be used.

### #create_time

    def create_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Protobuf-Timestamp)) --- Output only. The time the instance was created.

### #discovery_endpoint

    def discovery_endpoint() -> ::String

**Returns**

- (::String) --- Output only. Endpoint for the Discovery API.

### #display_name

    def display_name() -> ::String

**Returns**

- (::String) --- User provided name for the instance, which is only used for display purposes. Cannot be more than 80 characters.

### #display_name=

    def display_name=(value) -> ::String

**Parameter**

- **value** (::String) --- User provided name for the instance, which is only used for display purposes. Cannot be more than 80 characters.
**Returns**

- (::String) --- User provided name for the instance, which is only used for display purposes. Cannot be more than 80 characters.

### #instance_messages

    def instance_messages() -> ::Array<::Google::Cloud::Memcache::V1beta2::Instance::InstanceMessage>

**Returns**

- (::Array\<[::Google::Cloud::Memcache::V1beta2::Instance::InstanceMessage](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-InstanceMessage)\>) --- List of messages that describe the current state of the Memcached instance.

### #instance_messages=

    def instance_messages=(value) -> ::Array<::Google::Cloud::Memcache::V1beta2::Instance::InstanceMessage>

**Parameter**

- **value** (::Array\<[::Google::Cloud::Memcache::V1beta2::Instance::InstanceMessage](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-InstanceMessage)\>) --- List of messages that describe the current state of the Memcached instance.
**Returns**

- (::Array\<[::Google::Cloud::Memcache::V1beta2::Instance::InstanceMessage](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-InstanceMessage)\>) --- List of messages that describe the current state of the Memcached instance.

### #labels

    def labels() -> ::Google::Protobuf::Map{::String => ::String}

**Returns**

- (::Google::Protobuf::Map{::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

### #labels=

    def labels=(value) -> ::Google::Protobuf::Map{::String => ::String}

**Parameter**

- **value** (::Google::Protobuf::Map{::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
**Returns**

- (::Google::Protobuf::Map{::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

### #maintenance_policy

    def maintenance_policy() -> ::Google::Cloud::Memcache::V1beta2::MaintenancePolicy

**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MaintenancePolicy](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MaintenancePolicy)) --- The maintenance policy for the instance. If not provided, the maintenance event will be performed based on Memorystore internal rollout schedule.

### #maintenance_policy=

    def maintenance_policy=(value) -> ::Google::Cloud::Memcache::V1beta2::MaintenancePolicy

**Parameter**

- **value** ([::Google::Cloud::Memcache::V1beta2::MaintenancePolicy](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MaintenancePolicy)) --- The maintenance policy for the instance. If not provided, the maintenance event will be performed based on Memorystore internal rollout schedule.
**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MaintenancePolicy](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MaintenancePolicy)) --- The maintenance policy for the instance. If not provided, the maintenance event will be performed based on Memorystore internal rollout schedule.

### #maintenance_schedule

    def maintenance_schedule() -> ::Google::Cloud::Memcache::V1beta2::MaintenanceSchedule

**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MaintenanceSchedule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MaintenanceSchedule)) --- Output only. Published maintenance schedule.

### #memcache_full_version

    def memcache_full_version() -> ::String

**Returns**

- (::String) --- Output 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".

### #memcache_nodes

    def memcache_nodes() -> ::Array<::Google::Cloud::Memcache::V1beta2::Instance::Node>

**Returns**

- (::Array\<[::Google::Cloud::Memcache::V1beta2::Instance::Node](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-Node)\>) --- Output only. List of Memcached nodes. Refer to [Node](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-Node "Google::Cloud::Memcache::V1beta2::Instance::Node (class)") message for more details.

### #memcache_version

    def memcache_version() -> ::Google::Cloud::Memcache::V1beta2::MemcacheVersion

**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MemcacheVersion](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MemcacheVersion)) --- The 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.

### #memcache_version=

    def memcache_version=(value) -> ::Google::Cloud::Memcache::V1beta2::MemcacheVersion

**Parameter**

- **value** ([::Google::Cloud::Memcache::V1beta2::MemcacheVersion](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MemcacheVersion)) --- The 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.
**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MemcacheVersion](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MemcacheVersion)) --- The 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.

### #name

    def name() -> ::String

**Returns**

- (::String) --- Required. 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](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance#Google__Cloud__Memcache__V1beta2__Instance_zones_instance_ "Google::Cloud::Memcache::V1beta2::Instance#zones (method)") field for more details.

### #name=

    def name=(value) -> ::String

**Parameter**

- **value** (::String) --- Required. 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](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance#Google__Cloud__Memcache__V1beta2__Instance_zones_instance_ "Google::Cloud::Memcache::V1beta2::Instance#zones (method)") field for more details.
**Returns**

- (::String) --- Required. 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](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance#Google__Cloud__Memcache__V1beta2__Instance_zones_instance_ "Google::Cloud::Memcache::V1beta2::Instance#zones (method)") field for more details.

### #node_config

    def node_config() -> ::Google::Cloud::Memcache::V1beta2::Instance::NodeConfig

**Returns**

- ([::Google::Cloud::Memcache::V1beta2::Instance::NodeConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-NodeConfig)) --- Required. Configuration for Memcached nodes.

### #node_config=

    def node_config=(value) -> ::Google::Cloud::Memcache::V1beta2::Instance::NodeConfig

**Parameter**

- **value** ([::Google::Cloud::Memcache::V1beta2::Instance::NodeConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-NodeConfig)) --- Required. Configuration for Memcached nodes.
**Returns**

- ([::Google::Cloud::Memcache::V1beta2::Instance::NodeConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-NodeConfig)) --- Required. Configuration for Memcached nodes.

### #node_count

    def node_count() -> ::Integer

**Returns**

- (::Integer) --- Required. Number of nodes in the Memcached instance.

### #node_count=

    def node_count=(value) -> ::Integer

**Parameter**

- **value** (::Integer) --- Required. Number of nodes in the Memcached instance.
**Returns**

- (::Integer) --- Required. Number of nodes in the Memcached instance.

### #parameters

    def parameters() -> ::Google::Cloud::Memcache::V1beta2::MemcacheParameters

**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MemcacheParameters](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MemcacheParameters)) --- User defined parameters to apply to the memcached process on each node.

### #parameters=

    def parameters=(value) -> ::Google::Cloud::Memcache::V1beta2::MemcacheParameters

**Parameter**

- **value** ([::Google::Cloud::Memcache::V1beta2::MemcacheParameters](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MemcacheParameters)) --- User defined parameters to apply to the memcached process on each node.
**Returns**

- ([::Google::Cloud::Memcache::V1beta2::MemcacheParameters](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-MemcacheParameters)) --- User defined parameters to apply to the memcached process on each node.

### #state

    def state() -> ::Google::Cloud::Memcache::V1beta2::Instance::State

**Returns**

- ([::Google::Cloud::Memcache::V1beta2::Instance::State](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Cloud-Memcache-V1beta2-Instance-State)) --- Output only. The state of this Memcached instance.

### #update_available

    def update_available() -> ::Boolean

**Returns**

- (::Boolean) --- Output only. Returns true if there is an update waiting to be applied

### #update_time

    def update_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-memcache-v1beta2/latest/Google-Protobuf-Timestamp)) --- Output only. The time the instance was updated.

### #zones

    def zones() -> ::Array<::String>

**Returns**

- (::Array\<::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.

### #zones=

    def zones=(value) -> ::Array<::String>

**Parameter**

- **value** (::Array\<::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.
**Returns**

- (::Array\<::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.