0.22.5 (latest) 0.22.4 0.21.0 0.20.0 0.19.0 0.18.0 0.17.37 0.16.0 0.15.0 0.14.0 0.13.0 0.12.0 0.11.0 0.10.0 0.9.0 0.8.1 0.7.0 0.6.0 0.5.0 0.4.1 0.3.2 0.2.0 0.1.2

    InstanceSelection(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Defines an instance selection for a given instance
flexibility policy.

.. _oneof: <https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields>

| ## Attributes ||
|---|---|
| **Name** | **Description** |
| `machine_types` | `MutableSequence[str]` Required. The Compute Engine machine type IDs. Only the machine type ID is supported, such as `n1-standard-16`. Full or partial URLs are not accepted. The total maximum number of machine types across all instance selections is 200. Exceeding this limit results in a validation error with code `INVALID_ARGUMENT`. |
| `rank` | `int` Optional. Indicates the preference of this instance selection. Lower number means higher preference. First try is to create a VM based on the machine-type with lowest rank and fallback to next rank based on availability. Machine types and instance selections with the same rank have the same preference. This field is a member of `oneof`_ `_rank`. |
| `disks` | `MutableSequence[https://docs.cloud.google.com/python/docs/reference/batch/latest/google.cloud.batch_v1alpha.types.AllocationPolicy.AttachedDisk]` Optional. List of disks to be attached to instances created from this selection. They override the disks specified in the instance properties. |
| `boot_disk` | `https://docs.cloud.google.com/python/docs/reference/batch/latest/google.cloud.batch_v1alpha.types.AllocationPolicy.Disk` Optional. Boot disk to be created and attached to instances created from this selection. It overrides the boot disk specified in the instance properties. (e.g., overriding `boot` disk type to Hyperdisk for 4th-gen machine types) |