As of January 1, 2020 this library no longer supports Python 2 on the latest released version. Library versions released prior to that date will continue to be available. For more information please visit Python 2 support on Google Cloud.

Types for Google Cloud Memcache v1 API

class google.cloud.memcache_v1.types.ApplyParametersRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [ApplyParameters][google.cloud.memcache.v1.CloudMemcache.ApplyParameters].

name

Required. Resource name of the Memcached instance for which parameter group updates should be applied.

Type

str

node_ids

Nodes to which the instance-level parameter group is applied.

Type

MutableSequence[str]

apply_all

Whether to apply instance-level parameter group to all nodes. If set to true, users are restricted from specifying individual nodes, and ApplyParameters updates all nodes within the instance.

Type

bool

class google.cloud.memcache_v1.types.CreateInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [CreateInstance][google.cloud.memcache.v1.CloudMemcache.CreateInstance].

parent

Required. The resource name of the instance location using the form: projects/{project_id}/locations/{location_id} where location_id refers to a GCP region

Type

str

instance_id

Required. The logical name of the Memcached instance in the user project with the following restrictions:

  • Must contain only lowercase letters, numbers, and hyphens.

  • Must start with a letter.

  • Must be between 1-40 characters.

  • Must end with a number or a letter.

  • Must be unique within the user project / location.

If any of the above are not met, the API raises an invalid argument error.

Type

str

instance

Required. A Memcached Instance

Type

google.cloud.memcache_v1.types.Instance

class google.cloud.memcache_v1.types.DeleteInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [DeleteInstance][google.cloud.memcache.v1.CloudMemcache.DeleteInstance].

name

Required. Memcached instance resource name in the format: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a GCP region

Type

str

class google.cloud.memcache_v1.types.GetInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [GetInstance][google.cloud.memcache.v1.CloudMemcache.GetInstance].

name

Required. Memcached instance resource name in the format: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a GCP region

Type

str

class google.cloud.memcache_v1.types.Instance(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

A Memorystore for Memcached instance

name

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][google.cloud.memcache.v1.Instance.zones] field for more details.

Type

str

display_name

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

Type

str

labels

Resource labels to represent user-provided metadata. Refer to cloud documentation on labels for more details. https://cloud.google.com/compute/docs/labeling-resources

Type

MutableMapping[str, str]

authorized_network

The full name of the Google Compute Engine network to which the instance is connected. If left unspecified, the default network will be used.

Type

str

zones

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.

Type

MutableSequence[str]

node_count

Required. Number of nodes in the Memcached instance.

Type

int

node_config

Required. Configuration for Memcached nodes.

Type

google.cloud.memcache_v1.types.Instance.NodeConfig

memcache_version

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.

Type

google.cloud.memcache_v1.types.MemcacheVersion

parameters

User defined parameters to apply to the memcached process on each node.

Type

google.cloud.memcache_v1.types.MemcacheParameters

memcache_nodes

Output only. List of Memcached nodes. Refer to [Node][google.cloud.memcache.v1.Instance.Node] message for more details.

Type

MutableSequence[google.cloud.memcache_v1.types.Instance.Node]

create_time

Output only. The time the instance was created.

Type

google.protobuf.timestamp_pb2.Timestamp

update_time

Output only. The time the instance was updated.

Type

google.protobuf.timestamp_pb2.Timestamp

state

Output only. The state of this Memcached instance.

Type

google.cloud.memcache_v1.types.Instance.State

memcache_full_version

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”.

Type

str

instance_messages

List of messages that describe the current state of the Memcached instance.

Type

MutableSequence[google.cloud.memcache_v1.types.Instance.InstanceMessage]

discovery_endpoint

Output only. Endpoint for the Discovery API.

Type

str

maintenance_policy

The maintenance policy for the instance. If not provided, the maintenance event will be performed based on Memorystore internal rollout schedule.

Type

google.cloud.memcache_v1.types.MaintenancePolicy

maintenance_schedule

Output only. Published maintenance schedule.

Type

google.cloud.memcache_v1.types.MaintenanceSchedule

class InstanceMessage(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

code

A code that correspond to one type of user-facing message.

Type

google.cloud.memcache_v1.types.Instance.InstanceMessage.Code

message

Message on memcached instance which will be exposed to users.

Type

str

class Code(value)[source]

Bases: proto.enums.Enum

Values:
CODE_UNSPECIFIED (0):

Message Code not set.

ZONE_DISTRIBUTION_UNBALANCED (1):

Memcached nodes are distributed unevenly.

class LabelsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Bases: proto.message.Message

class Node(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

node_id

Output only. Identifier of the Memcached node. The node id does not include project or location like the Memcached instance name.

Type

str

zone

Output only. Location (GCP Zone) for the Memcached node.

Type

str

state

Output only. Current state of the Memcached node.

Type

google.cloud.memcache_v1.types.Instance.Node.State

host

Output only. Hostname or IP address of the Memcached node used by the clients to connect to the Memcached server on this node.

Type

str

port

Output only. The port number of the Memcached server on this node.

Type

int

parameters

User defined parameters currently applied to the node.

Type

google.cloud.memcache_v1.types.MemcacheParameters

class State(value)[source]

Bases: proto.enums.Enum

Different states of a Memcached node.

Values:
STATE_UNSPECIFIED (0):

Node state is not set.

CREATING (1):

Node is being created.

READY (2):

Node has been created and ready to be used.

DELETING (3):

Node is being deleted.

UPDATING (4):

Node is being updated.

class NodeConfig(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Configuration for a Memcached Node.

cpu_count

Required. Number of cpus per Memcached node.

Type

int

memory_size_mb

Required. Memory size in MiB for each Memcached node.

Type

int

class State(value)[source]

Bases: proto.enums.Enum

Different states of a Memcached instance.

Values:
STATE_UNSPECIFIED (0):

State not set.

CREATING (1):

Memcached instance is being created.

READY (2):

Memcached instance has been created and ready to be used.

UPDATING (3):

Memcached instance is updating configuration such as maintenance policy and schedule.

DELETING (4):

Memcached instance is being deleted.

PERFORMING_MAINTENANCE (5):

Memcached instance is going through maintenance, e.g. data plane rollout.

class google.cloud.memcache_v1.types.ListInstancesRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [ListInstances][google.cloud.memcache.v1.CloudMemcache.ListInstances].

parent

Required. The resource name of the instance location using the form: projects/{project_id}/locations/{location_id} where location_id refers to a GCP region

Type

str

page_size

The maximum number of items to return.

If not specified, a default value of 1000 will be used by the service. Regardless of the page_size value, the response may include a partial list and a caller should only rely on response’s [next_page_token][google.cloud.memcache.v1.ListInstancesResponse.next_page_token] to determine if there are more instances left to be queried.

Type

int

page_token

The next_page_token value returned from a previous List request, if any.

Type

str

filter

List filter. For example, exclude all Memcached instances with name as my-instance by specifying "name != my-instance".

Type

str

order_by

Sort results. Supported values are “name”, “name desc” or “” (unsorted).

Type

str

class google.cloud.memcache_v1.types.ListInstancesResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Response for [ListInstances][google.cloud.memcache.v1.CloudMemcache.ListInstances].

instances

A list of Memcached instances in the project in the specified location, or across all locations.

If the location_id in the parent field of the request is “-”, all regions available to the project are queried, and the results aggregated.

Type

MutableSequence[google.cloud.memcache_v1.types.Instance]

next_page_token

Token to retrieve the next page of results, or empty if there are no more results in the list.

Type

str

unreachable

Locations that could not be reached.

Type

MutableSequence[str]

class google.cloud.memcache_v1.types.LocationMetadata(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Metadata for the given [google.cloud.location.Location][google.cloud.location.Location].

available_zones

Output only. The set of available zones in the location. The map is keyed by the lowercase ID of each zone, as defined by GCE. These keys can be specified in the zones field when creating a Memcached instance.

Type

MutableMapping[str, google.cloud.memcache_v1.types.ZoneMetadata]

class AvailableZonesEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Bases: proto.message.Message

class google.cloud.memcache_v1.types.MaintenancePolicy(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Maintenance policy per instance.

create_time

Output only. The time when the policy was created.

Type

google.protobuf.timestamp_pb2.Timestamp

update_time

Output only. The time when the policy was updated.

Type

google.protobuf.timestamp_pb2.Timestamp

description

Description of what this policy is for. Create/Update methods return INVALID_ARGUMENT if the length is greater than 512.

Type

str

weekly_maintenance_window

Required. Maintenance window that is applied to resources covered by this policy. Minimum 1. For the current version, the maximum number of weekly_maintenance_windows is expected to be one.

Type

MutableSequence[google.cloud.memcache_v1.types.WeeklyMaintenanceWindow]

class google.cloud.memcache_v1.types.MaintenanceSchedule(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Upcoming maintenance schedule.

start_time

Output only. The start time of any upcoming scheduled maintenance for this instance.

Type

google.protobuf.timestamp_pb2.Timestamp

end_time

Output only. The end time of any upcoming scheduled maintenance for this instance.

Type

google.protobuf.timestamp_pb2.Timestamp

schedule_deadline_time

Output only. The deadline that the maintenance schedule start time can not go beyond, including reschedule.

Type

google.protobuf.timestamp_pb2.Timestamp

class google.cloud.memcache_v1.types.MemcacheParameters(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

id

Output only. The unique ID associated with this set of parameters. Users can use this id to determine if the parameters associated with the instance differ from the parameters associated with the nodes. A discrepancy between parameter ids can inform users that they may need to take action to apply parameters on nodes.

Type

str

params

User defined set of parameters to use in the memcached process.

Type

MutableMapping[str, str]

class ParamsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Bases: proto.message.Message

class google.cloud.memcache_v1.types.MemcacheVersion(value)[source]

Bases: proto.enums.Enum

Memcached versions supported by our service.

Values:
MEMCACHE_VERSION_UNSPECIFIED (0):

No description available.

MEMCACHE_1_5 (1):

Memcached 1.5 version.

class google.cloud.memcache_v1.types.OperationMetadata(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Represents the metadata of a long-running operation.

create_time

Output only. Time when the operation was created.

Type

google.protobuf.timestamp_pb2.Timestamp

end_time

Output only. Time when the operation finished running.

Type

google.protobuf.timestamp_pb2.Timestamp

target

Output only. Server-defined resource path for the target of the operation.

Type

str

verb

Output only. Name of the verb executed by the operation.

Type

str

status_detail

Output only. Human-readable status of the operation, if any.

Type

str

cancel_requested

Output only. Identifies whether the user has requested cancellation of the operation. Operations that have successfully been cancelled have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to Code.CANCELLED.

Type

bool

api_version

Output only. API version used to start the operation.

Type

str

class google.cloud.memcache_v1.types.RescheduleMaintenanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [RescheduleMaintenance][google.cloud.memcache.v1.CloudMemcache.RescheduleMaintenance].

instance

Required. Memcache instance resource name using the form: projects/{project_id}/locations/{location_id}/instances/{instance_id} where location_id refers to a GCP region.

Type

str

reschedule_type

Required. If reschedule type is SPECIFIC_TIME, must set up schedule_time as well.

Type

google.cloud.memcache_v1.types.RescheduleMaintenanceRequest.RescheduleType

schedule_time

Timestamp when the maintenance shall be rescheduled to if reschedule_type=SPECIFIC_TIME, in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.

Type

google.protobuf.timestamp_pb2.Timestamp

class RescheduleType(value)[source]

Bases: proto.enums.Enum

Reschedule options.

Values:
RESCHEDULE_TYPE_UNSPECIFIED (0):

Not set.

IMMEDIATE (1):

If the user wants to schedule the maintenance to happen now.

NEXT_AVAILABLE_WINDOW (2):

If the user wants to use the existing maintenance policy to find the next available window.

SPECIFIC_TIME (3):

If the user wants to reschedule the maintenance to a specific time.

class google.cloud.memcache_v1.types.UpdateInstanceRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [UpdateInstance][google.cloud.memcache.v1.CloudMemcache.UpdateInstance].

update_mask

Required. Mask of fields to update.

  • displayName

Type

google.protobuf.field_mask_pb2.FieldMask

instance

Required. A Memcached Instance. Only fields specified in update_mask are updated.

Type

google.cloud.memcache_v1.types.Instance

class google.cloud.memcache_v1.types.UpdateParametersRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Request for [UpdateParameters][google.cloud.memcache.v1.CloudMemcache.UpdateParameters].

name

Required. Resource name of the Memcached instance for which the parameters should be updated.

Type

str

update_mask

Required. Mask of fields to update.

Type

google.protobuf.field_mask_pb2.FieldMask

parameters

The parameters to apply to the instance.

Type

google.cloud.memcache_v1.types.MemcacheParameters

class google.cloud.memcache_v1.types.WeeklyMaintenanceWindow(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Time window specified for weekly operations.

day

Required. Allows to define schedule that runs specified day of the week.

Type

google.type.dayofweek_pb2.DayOfWeek

start_time

Required. Start time of the window in UTC.

Type

google.type.timeofday_pb2.TimeOfDay

duration

Required. Duration of the time window.

Type

google.protobuf.duration_pb2.Duration