# Compute Engine v1 API - Class Reservation (3.28.0)

3.28.0 (latest) 3.27.0 3.26.0 3.25.0 3.24.0 3.23.0 3.22.0 3.21.0 3.20.0 3.19.0 3.18.0 3.17.0 3.16.0 3.15.0 3.14.0 3.13.0 3.12.0 3.11.0 3.10.0 3.9.0 3.8.0 3.7.0 3.6.0 3.5.0 3.4.0 3.3.0 3.2.0 3.1.0 3.0.0 2.17.0 2.16.0 2.15.0 2.14.0 2.13.0 2.12.0 2.11.0 2.10.0 2.9.0 2.8.0 2.7.0 2.6.0 2.5.0 2.4.0 2.3.0 2.2.0 2.1.0 2.0.0 1.4.0 1.3.0 1.2.0 1.1.0 1.0.0

    public sealed class Reservation : IMessage<Reservation>, IEquatable<Reservation>, IDeepCloneable<Reservation>, IBufferMessage, IMessage

Reference documentation and code samples for the Compute Engine v1 API class Reservation.

Represents a reservation resource. A reservation ensures that capacity is
held in a specific zone even if the reserved VMs are not running. For more
information, read Reserving zonal
resources.

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> Reservation

## Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[Reservation](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.Reservation), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Reservation](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.Reservation), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[Reservation](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.Reservation), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.Compute.V1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1)

## Assembly

Google.Cloud.Compute.V1.dll

## Constructors

### Reservation()

    public Reservation()

### Reservation(Reservation)

    public Reservation(Reservation other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.Reservation` |

## Properties

### AdvancedDeploymentControl

    public ReservationAdvancedDeploymentControl AdvancedDeploymentControl { get; set; }

Advanced control for cluster management, applicable only to DENSE
deployment type reservations.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.ReservationAdvancedDeploymentControl` |   |

### AggregateReservation

    public AllocationAggregateReservation AggregateReservation { get; set; }

Reservation for aggregated resources, providing shape flexibility.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.AllocationAggregateReservation` |   |

### Commitment

    public string Commitment { get; set; }

Output only. \[Output Only\] Full or partial URL to a parent commitment. This field
displays for reservations that are tied to a commitment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### ConfidentialComputeType

    public string ConfidentialComputeType { get; set; }

Check the ConfidentialComputeType enum for the list of possible values.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### CreationTimestamp

    public string CreationTimestamp { get; set; }

Output only. \[Output Only\] Creation timestamp inRFC3339
text format.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### DeleteAfterDuration

    public Duration DeleteAfterDuration { get; set; }

Duration time relative to reservation creation when Compute Engine will
automatically delete this resource.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.Duration` |   |

### DeleteAtTime

    public string DeleteAtTime { get; set; }

Absolute time in future when the reservation will be
auto-deleted by Compute Engine. Timestamp is represented inRFC3339 text format.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### DeploymentType

    public string DeploymentType { get; set; }

Specifies the deployment strategy for this reservation.
Check the DeploymentType enum for the list of possible values.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Description

    public string Description { get; set; }

An optional description of this resource. Provide this property when you
create the resource.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### EarlyAccessMaintenance

    public string EarlyAccessMaintenance { get; set; }

Indicates the early access maintenance for the reservation.
If this field is absent or set to NO_EARLY_ACCESS, the reservation is not
enrolled in early access maintenance and the standard notice applies.
Check the EarlyAccessMaintenance enum for the list of possible values.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### EnableEmergentMaintenance

    public bool EnableEmergentMaintenance { get; set; }

Indicates whether Compute Engine allows unplanned maintenance for your VMs;
for example, to fix hardware errors.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasCommitment

    public bool HasCommitment { get; }

Gets whether the "commitment" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasConfidentialComputeType

    public bool HasConfidentialComputeType { get; }

Gets whether the "confidential_compute_type" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasCreationTimestamp

    public bool HasCreationTimestamp { get; }

Gets whether the "creation_timestamp" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasDeleteAtTime

    public bool HasDeleteAtTime { get; }

Gets whether the "delete_at_time" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasDeploymentType

    public bool HasDeploymentType { get; }

Gets whether the "deployment_type" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasDescription

    public bool HasDescription { get; }

Gets whether the "description" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasEarlyAccessMaintenance

    public bool HasEarlyAccessMaintenance { get; }

Gets whether the "early_access_maintenance" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasEnableEmergentMaintenance

    public bool HasEnableEmergentMaintenance { get; }

Gets whether the "enable_emergent_maintenance" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasId

    public bool HasId { get; }

Gets whether the "id" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasKind

    public bool HasKind { get; }

Gets whether the "kind" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasName

    public bool HasName { get; }

Gets whether the "name" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasProtectionTier

    public bool HasProtectionTier { get; }

Gets whether the "protection_tier" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasSatisfiesPzs

    public bool HasSatisfiesPzs { get; }

Gets whether the "satisfies_pzs" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasSchedulingType

    public bool HasSchedulingType { get; }

Gets whether the "scheduling_type" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasSelfLink

    public bool HasSelfLink { get; }

Gets whether the "self_link" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasSpecificReservationRequired

    public bool HasSpecificReservationRequired { get; }

Gets whether the "specific_reservation_required" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasStatus

    public bool HasStatus { get; }

Gets whether the "status" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### HasZone

    public bool HasZone { get; }

Gets whether the "zone" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### Id

    public ulong Id { get; set; }

Output only. \[Output Only\] The unique identifier for the resource. This identifier is
defined by the server.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.uint64` |   |

### Kind

    public string Kind { get; set; }

Output only. \[Output Only\] Type of the resource. Alwayscompute#reservations for reservations.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### LinkedCommitments

    public RepeatedField<string> LinkedCommitments { get; }

Output only. \[Output Only\] Full or partial URL to parent commitments. This field
displays for reservations that are tied to multiple commitments.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.RepeatedField-1.htmlhttps://learn.microsoft.com/dotnet/api/system.string` |   |

### Name

    public string Name { get; set; }

The name of the resource, provided by the client when initially creating
the resource. The resource name must be 1-63 characters long, and comply
withRFC1035.
Specifically, the name must be 1-63 characters long and match the regular
expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first
character must be a lowercase letter, and all following characters must be
a dash, lowercase letter, or digit, except the last character, which cannot
be a dash.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Params

    public ReservationParams Params { get; set; }

Input only. Additional params passed with the request, but not persisted
as part of resource payload.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.ReservationParams` |   |

### ProtectionTier

    public string ProtectionTier { get; set; }

Protection tier for the workload which specifies the workload expectations
in the event of infrastructure failures at data center (e.g. power
and/or cooling failures).
Check the ProtectionTier enum for the list of possible values.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### ReservationSharingPolicy

    public AllocationReservationSharingPolicy ReservationSharingPolicy { get; set; }

Specify the reservation sharing policy. If unspecified, the reservation
will not be shared with Google Cloud managed services.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.AllocationReservationSharingPolicy` |   |

### ResourcePolicies

    public MapField<string, string> ResourcePolicies { get; }

Resource policies to be added to this reservation. The key is defined by
user, and the value is resource policy url. This is to define placement
policy with reservation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.MapField-2.htmlhttps://learn.microsoft.com/dotnet/api/system.stringhttps://learn.microsoft.com/dotnet/api/system.string` |   |

### ResourceStatus

    public AllocationResourceStatus ResourceStatus { get; set; }

Output only. \[Output Only\] Status information for Reservation resource.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.AllocationResourceStatus` |   |

### SatisfiesPzs

    public bool SatisfiesPzs { get; set; }

Output only. \[Output Only\] Reserved for future use.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### SchedulingType

    public string SchedulingType { get; set; }

The type of maintenance for the reservation.
Check the SchedulingType enum for the list of possible values.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### SelfLink

    public string SelfLink { get; set; }

Output only. \[Output Only\] Server-defined fully-qualified URL for this resource.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### ShareSettings

    public ShareSettings ShareSettings { get; set; }

Specify share-settings to create a shared reservation. This property is
optional. For more information about the syntax and options for this
field and its subfields, see the guide for creating
a shared reservation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.ShareSettings` |   |

### SpecificReservation

    public AllocationSpecificSKUReservation SpecificReservation { get; set; }

Reservation for instances with specific machine shapes.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.AllocationSpecificSKUReservation` |   |

### SpecificReservationRequired

    public bool SpecificReservationRequired { get; set; }

Indicates whether the reservation can be consumed by VMs with affinity
for "any" reservation. If the field is set, then only VMs that target
the reservation by name can consume from this reservation.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### Status

    public string Status { get; set; }

Output only. \[Output Only\] The status of the reservation.

     - CREATING: Reservation resources are being
       allocated.
     - READY: Reservation resources have been allocated,
       and the reservation is ready for use.
     - DELETING: Reservation deletion is in progress.
     - UPDATING: Reservation update is in progress.

Check the Status enum for the list of possible values.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Zone

    public string Zone { get; set; }

Zone in which the reservation resides. A zone must be provided if the
reservation is created within a commitment.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |