# Compute Engine v1 API - Class InstanceGroupManager (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 InstanceGroupManager : IMessage<InstanceGroupManager>, IEquatable<InstanceGroupManager>, IDeepCloneable<InstanceGroupManager>, IBufferMessage, IMessage

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

Represents a Managed Instance Group resource.

An instance group is a collection of VM instances that you can manage as a
single entity. For more information, readInstance groups.

For zonal Managed Instance Group, use the instanceGroupManagers
resource.

For regional Managed Instance Group, use theregionInstanceGroupManagers resource.

## Inheritance

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

## Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[InstanceGroupManager](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.InstanceGroupManager), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[InstanceGroupManager](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.InstanceGroupManager), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[InstanceGroupManager](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.InstanceGroupManager), [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

### InstanceGroupManager()

    public InstanceGroupManager()

### InstanceGroupManager(InstanceGroupManager)

    public InstanceGroupManager(InstanceGroupManager other)

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

## Properties

### AllInstancesConfig

    public InstanceGroupManagerAllInstancesConfig AllInstancesConfig { get; set; }

Specifies configuration that overrides the instance template configuration
for the group.

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

### AutoHealingPolicies

    public RepeatedField<InstanceGroupManagerAutoHealingPolicy> AutoHealingPolicies { get; }

The autohealing policy for this managed instance group. You can specify
only one value.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.RepeatedField-1.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.InstanceGroupManagerAutoHealingPolicy` |   |

### BaseInstanceName

    public string BaseInstanceName { get; set; }

The base instance name is a prefix that you want to attach to the names of
all VMs in a MIG. The maximum character length is 58 and the name must
comply with RFC1035 format.

When a VM is created in the group, the MIG appends a hyphen and a random
four-character string to the base instance name. If you want the MIG to
assign sequential numbers instead of a random string, then end the base
instance name with a hyphen followed by one or more hash symbols. The hash
symbols indicate the number of digits. For example, a base instance name of
"vm-###" results in "vm-001" as a VM name.
@pattern
[a-z](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/([-a-z0-9]{0,57})|([-a-z0-9]{0,51}-#{1,10}(\[[0-9]{1,10}\])?))

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

### CreationTimestamp

    public string CreationTimestamp { get; set; }

Output only. The creation timestamp for this managed instance group inRFC3339
text format.

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

### CurrentActions

    public InstanceGroupManagerActionsSummary CurrentActions { get; set; }

Output only. The list of instance actions and the number of instances
in this managed instance group that are scheduled for each of those
actions.

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

### Description

    public string Description { get; set; }

An optional description of this resource.

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

### DistributionPolicy

    public DistributionPolicy DistributionPolicy { get; set; }

Policy specifying the intended distribution of managed instances across
zones in a regional managed instance group.

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

### Fingerprint

    public string Fingerprint { get; set; }

Fingerprint of this resource. This field may be used in optimistic locking.
It will be ignored when inserting an InstanceGroupManager. An up-to-date
fingerprint must be provided in order to update the InstanceGroupManager,
otherwise the request will fail with error412 conditionNotMet.

To see the latest fingerprint, make a get() request to
retrieve an InstanceGroupManager.

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

### HasBaseInstanceName

    public bool HasBaseInstanceName { get; }

Gets whether the "base_instance_name" 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` |   |

### HasDescription

    public bool HasDescription { get; }

Gets whether the "description" field is set

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

### HasFingerprint

    public bool HasFingerprint { get; }

Gets whether the "fingerprint" 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` |   |

### HasInstanceGroup

    public bool HasInstanceGroup { get; }

Gets whether the "instance_group" field is set

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

### HasInstanceTemplate

    public bool HasInstanceTemplate { get; }

Gets whether the "instance_template" 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` |   |

### HasListManagedInstancesResults

    public bool HasListManagedInstancesResults { get; }

Gets whether the "list_managed_instances_results" 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` |   |

### HasRegion

    public bool HasRegion { get; }

Gets whether the "region" field is set

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

### HasSatisfiesPzi

    public bool HasSatisfiesPzi { get; }

Gets whether the "satisfies_pzi" 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` |   |

### 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` |   |

### HasTargetSize

    public bool HasTargetSize { get; }

Gets whether the "target_size" field is set

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

### HasTargetStoppedSize

    public bool HasTargetStoppedSize { get; }

Gets whether the "target_stopped_size" field is set

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

### HasTargetSuspendedSize

    public bool HasTargetSuspendedSize { get; }

Gets whether the "target_suspended_size" 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. A unique identifier for this resource type. The server
generates this identifier.

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

### InstanceFlexibilityPolicy

    public InstanceGroupManagerInstanceFlexibilityPolicy InstanceFlexibilityPolicy { get; set; }

Instance flexibility allowing MIG to create VMs from multiple
types of machines.
Instance flexibility configuration on MIG overrides instance
template configuration.

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

### InstanceGroup

    public string InstanceGroup { get; set; }

Output only. The URL of the Instance Group resource.

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

### InstanceLifecyclePolicy

    public InstanceGroupManagerInstanceLifecyclePolicy InstanceLifecyclePolicy { get; set; }

The repair policy for this managed instance group.

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

### InstanceTemplate

    public string InstanceTemplate { get; set; }

The URL of the instance template that is specified for this managed
instance group. The group uses this template to create all new instances
in the managed instance group. The templates for existing instances in the
group do not change unless you run recreateInstances, runapplyUpdatesToInstances, or set the group'supdatePolicy.type to PROACTIVE.

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

### Kind

    public string Kind { get; set; }

Output only. The resource type, which is alwayscompute#instanceGroupManager for managed instance groups.

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

### ListManagedInstancesResults

    public string ListManagedInstancesResults { get; set; }

Pagination behavior of the listManagedInstances API method for
this managed instance group.
Check the ListManagedInstancesResults enum for the list of possible values.

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

### Name

    public string Name { get; set; }

The name of the managed instance group. The name must be 1-63 characters
long, and comply withRFC1035.

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

### NamedPorts

    public RepeatedField<NamedPort> NamedPorts { get; }

\[Output Only\] Named ports configured on the Instance Groups complementary
to this Instance Group Manager.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.RepeatedField-1.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.NamedPort` |   |

### Region

    public string Region { get; set; }

Output only. \[Output Only\] The URL of theregion
where the managed instance group resides (for regional resources).

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

### ResourcePolicies

    public InstanceGroupManagerResourcePolicies ResourcePolicies { get; set; }

Resource policies for this managed instance group.

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

### SatisfiesPzi

    public bool SatisfiesPzi { get; set; }

Output only. Reserved for future use.

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

### SatisfiesPzs

    public bool SatisfiesPzs { get; set; }

Output only. Reserved for future use.

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

### SelfLink

    public string SelfLink { get; set; }

Output only. The URL for this managed instance group. The server defines
this URL.

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

### StandbyPolicy

    public InstanceGroupManagerStandbyPolicy StandbyPolicy { get; set; }

Standby policy for stopped and suspended instances.

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

### StatefulPolicy

    public StatefulPolicy StatefulPolicy { get; set; }

Stateful configuration for this Instanced Group Manager

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

### Status

    public InstanceGroupManagerStatus Status { get; set; }

Output only. The status of this managed instance group.

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

### TargetPools

    public RepeatedField<string> TargetPools { get; }

The URLs for all TargetPool resources to which instances in theinstanceGroup field are added. The target pools automatically
apply to all of the instances in the managed instance group.

| **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` |   |

### TargetSize

    public int TargetSize { get; set; }

The target number of running instances for this managed instance group.
You can reduce this number by using the instanceGroupManager
deleteInstances or abandonInstances methods. Resizing the group also
changes this number.

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

### TargetSizePolicy

    public InstanceGroupManagerTargetSizePolicy TargetSizePolicy { get; set; }

The policy that specifies how the MIG creates its VMs to achieve the target
size.

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

### TargetStoppedSize

    public int TargetStoppedSize { get; set; }

The target number of stopped instances for this managed instance group.
This number changes when you:

- Stop instance using the stopInstances method or start instances using the startInstances method.
- Manually change the targetStoppedSize using the update method.

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

### TargetSuspendedSize

    public int TargetSuspendedSize { get; set; }

The target number of suspended instances for this managed instance group.
This number changes when you:

- Suspend instance using the suspendInstances method or resume instances using the resumeInstances method.
- Manually change the targetSuspendedSize using the update method.

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

### UpdatePolicy

    public InstanceGroupManagerUpdatePolicy UpdatePolicy { get; set; }

The update policy for this managed instance group.

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

### Versions

    public RepeatedField<InstanceGroupManagerVersion> Versions { get; }

Specifies the instance templates used by this managed instance group to
create instances.

Each version is defined by an instanceTemplate and aname. Every version can appear at most once per instance
group. This field overrides the top-level instanceTemplate
field. Read more about therelationships
between these fields. Exactly one version must leave thetargetSize field unset. That version will be applied to all
remaining instances. For more information, read aboutcanary
updates.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.Collections.RepeatedField-1.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Compute.V1/latest/Google.Cloud.Compute.V1.InstanceGroupManagerVersion` |   |

### Zone

    public string Zone { get; set; }

Output only. The URL of azone
where the managed instance group is located (for zonal resources).

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