Class VmMigrationAsyncClient (1.7.0)

VmMigrationAsyncClient(*, credentials: typing.Optional[google.auth.credentials.Credentials] = None, transport: typing.Union[str, google.cloud.vmmigration_v1.services.vm_migration.transports.base.VmMigrationTransport] = 'grpc_asyncio', client_options: typing.Optional[google.api_core.client_options.ClientOptions] = None, client_info: google.api_core.gapic_v1.client_info.ClientInfo = <google.api_core.gapic_v1.client_info.ClientInfo object>)

VM Migration Service

Properties

transport

Returns the transport used by the client instance.

Returns
TypeDescription
VmMigrationTransportThe transport used by the client instance.

Methods

VmMigrationAsyncClient

VmMigrationAsyncClient(*, credentials: typing.Optional[google.auth.credentials.Credentials] = None, transport: typing.Union[str, google.cloud.vmmigration_v1.services.vm_migration.transports.base.VmMigrationTransport] = 'grpc_asyncio', client_options: typing.Optional[google.api_core.client_options.ClientOptions] = None, client_info: google.api_core.gapic_v1.client_info.ClientInfo = <google.api_core.gapic_v1.client_info.ClientInfo object>)

Instantiates the vm migration client.

Parameters
NameDescription
credentials Optional[google.auth.credentials.Credentials]

The authorization credentials to attach to requests. These credentials identify the application to the service; if none are specified, the client will attempt to ascertain the credentials from the environment.

transport Union[str, .VmMigrationTransport]

The transport to use. If set to None, a transport is chosen automatically.

client_options ClientOptions

Custom options for the client. It won't take effect if a transport instance is provided. (1) The api_endpoint property can be used to override the default endpoint provided by the client. GOOGLE_API_USE_MTLS_ENDPOINT environment variable can also be used to override the endpoint: "always" (always use the default mTLS endpoint), "never" (always use the default regular endpoint) and "auto" (auto switch to the default mTLS endpoint if client certificate is present, this is the default value). However, the api_endpoint property takes precedence if provided. (2) If GOOGLE_API_USE_CLIENT_CERTIFICATE environment variable is "true", then the client_cert_source property can be used to provide client certificate for mutual TLS transport. If not provided, the default SSL client certificate will be used if present. If GOOGLE_API_USE_CLIENT_CERTIFICATE is "false" or not set, no client certificate will be used.

Exceptions
TypeDescription
google.auth.exceptions.MutualTlsChannelErrorIf mutual TLS transport creation failed for any reason.

add_group_migration

add_group_migration(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.AddGroupMigrationRequest, dict
        ]
    ] = None,
    *,
    group: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Adds a MigratingVm to a Group.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_add_group_migration():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.AddGroupMigrationRequest(
        group="group_value",
    )

    # Make the request
    operation = client.add_group_migration(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.AddGroupMigrationRequest, dict]]

The request object. Request message for 'AddGroupMigration' request.

group str

Required. The full path name of the Group to add to. This corresponds to the group field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be AddGroupMigrationResponse Response message for 'AddGroupMigration' request.

cancel_clone_job

cancel_clone_job(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CancelCloneJobRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Initiates the cancellation of a running clone job.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_cancel_clone_job():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CancelCloneJobRequest(
        name="name_value",
    )

    # Make the request
    operation = client.cancel_clone_job(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CancelCloneJobRequest, dict]]

The request object. Request message for 'CancelCloneJob' request.

name str

Required. The clone job id This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be CancelCloneJobResponse Response message for 'CancelCloneJob' request.

cancel_cutover_job

cancel_cutover_job(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CancelCutoverJobRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Initiates the cancellation of a running cutover job.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_cancel_cutover_job():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CancelCutoverJobRequest(
        name="name_value",
    )

    # Make the request
    operation = client.cancel_cutover_job(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CancelCutoverJobRequest, dict]]

The request object. Request message for 'CancelCutoverJob' request.

name str

Required. The cutover job id This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be CancelCutoverJobResponse Response message for 'CancelCutoverJob' request.

cancel_operation

cancel_operation(
    request: typing.Optional[
        google.longrunning.operations_pb2.CancelOperationRequest
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> None

Starts asynchronous cancellation on a long-running operation.

The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED.

Parameters
NameDescription
request .operations_pb2.CancelOperationRequest

The request object. Request message for CancelOperation method.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

clone_job_path

clone_job_path(
    project: str, location: str, source: str, migrating_vm: str, clone_job: str
) -> str

Returns a fully-qualified clone_job string.

common_billing_account_path

common_billing_account_path(billing_account: str) -> str

Returns a fully-qualified billing_account string.

common_folder_path

common_folder_path(folder: str) -> str

Returns a fully-qualified folder string.

common_location_path

common_location_path(project: str, location: str) -> str

Returns a fully-qualified location string.

common_organization_path

common_organization_path(organization: str) -> str

Returns a fully-qualified organization string.

common_project_path

common_project_path(project: str) -> str

Returns a fully-qualified project string.

create_clone_job

create_clone_job(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateCloneJobRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    clone_job: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.CloneJob
    ] = None,
    clone_job_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Initiates a Clone of a specific migrating VM.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_clone_job():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateCloneJobRequest(
        parent="parent_value",
        clone_job_id="clone_job_id_value",
    )

    # Make the request
    operation = client.create_clone_job(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateCloneJobRequest, dict]]

The request object. Request message for 'CreateCloneJob' request.

parent str

Required. The Clone's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

clone_job CloneJob

Required. The clone request body. This corresponds to the clone_job field on the request instance; if request is provided, this should not be set.

clone_job_id str

Required. The clone job identifier. This corresponds to the clone_job_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be CloneJob CloneJob describes the process of creating a clone of a MigratingVM to the requested target based on the latest successful uploaded snapshots. While the migration cycles of a MigratingVm take place, it is possible to verify the uploaded VM can be started in the cloud, by creating a clone. The clone can be created without any downtime, and it is created using the latest snapshots which are already in the cloud. The cloneJob is only responsible for its work, not its products, which means once it is finished, it will never touch the instance it created. It will only delete it in case of the CloneJob being cancelled or upon failure to clone.

create_cutover_job

create_cutover_job(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateCutoverJobRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    cutover_job: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.CutoverJob
    ] = None,
    cutover_job_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Initiates a Cutover of a specific migrating VM. The returned LRO is completed when the cutover job resource is created and the job is initiated.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_cutover_job():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateCutoverJobRequest(
        parent="parent_value",
        cutover_job_id="cutover_job_id_value",
    )

    # Make the request
    operation = client.create_cutover_job(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateCutoverJobRequest, dict]]

The request object. Request message for 'CreateCutoverJob' request.

parent str

Required. The Cutover's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

cutover_job CutoverJob

Required. The cutover request body. This corresponds to the cutover_job field on the request instance; if request is provided, this should not be set.

cutover_job_id str

Required. The cutover job identifier. This corresponds to the cutover_job_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be CutoverJob CutoverJob message describes a cutover of a migrating VM. The CutoverJob is the operation of shutting down the VM, creating a snapshot and clonning the VM using the replicated snapshot.

create_datacenter_connector

create_datacenter_connector(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateDatacenterConnectorRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    datacenter_connector: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.DatacenterConnector
    ] = None,
    datacenter_connector_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Creates a new DatacenterConnector in a given Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_datacenter_connector():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateDatacenterConnectorRequest(
        parent="parent_value",
        datacenter_connector_id="datacenter_connector_id_value",
    )

    # Make the request
    operation = client.create_datacenter_connector(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateDatacenterConnectorRequest, dict]]

The request object. Request message for 'CreateDatacenterConnector' request.

parent str

Required. The DatacenterConnector's parent. Required. The Source in where the new DatacenterConnector will be created. For example: projects/my-project/locations/us-central1/sources/my-source This corresponds to the parent field on the request instance; if request is provided, this should not be set.

datacenter_connector DatacenterConnector

Required. The create request body. This corresponds to the datacenter_connector field on the request instance; if request is provided, this should not be set.

datacenter_connector_id str

Required. The datacenterConnector identifier. This corresponds to the datacenter_connector_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be DatacenterConnector DatacenterConnector message describes a connector between the Source and Google Cloud, which is installed on a vmware datacenter (an OVA vm installed by the user) to connect the Datacenter to Google Cloud and support vm migration data transfer.

create_group

create_group(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateGroupRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    group: typing.Optional[google.cloud.vmmigration_v1.types.vmmigration.Group] = None,
    group_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Creates a new Group in a given project and location.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_group():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateGroupRequest(
        parent="parent_value",
        group_id="group_id_value",
    )

    # Make the request
    operation = client.create_group(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateGroupRequest, dict]]

The request object. Request message for 'CreateGroup' request.

parent str

Required. The Group's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

group Group

Required. The create request body. This corresponds to the group field on the request instance; if request is provided, this should not be set.

group_id str

Required. The group identifier. This corresponds to the group_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be Group Describes message for 'Group' resource. The Group is a collections of several MigratingVms.

create_migrating_vm

create_migrating_vm(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateMigratingVmRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    migrating_vm: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.MigratingVm
    ] = None,
    migrating_vm_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Creates a new MigratingVm in a given Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_migrating_vm():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateMigratingVmRequest(
        parent="parent_value",
        migrating_vm_id="migrating_vm_id_value",
    )

    # Make the request
    operation = client.create_migrating_vm(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateMigratingVmRequest, dict]]

The request object. Request message for 'CreateMigratingVm' request.

parent str

Required. The MigratingVm's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

migrating_vm MigratingVm

Required. The create request body. This corresponds to the migrating_vm field on the request instance; if request is provided, this should not be set.

migrating_vm_id str

Required. The migratingVm identifier. This corresponds to the migrating_vm_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be MigratingVm MigratingVm describes the VM that will be migrated from a Source environment and its replication state.

create_source

create_source(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateSourceRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    source: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.Source
    ] = None,
    source_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Creates a new Source in a given project and location.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_source():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateSourceRequest(
        parent="parent_value",
        source_id="source_id_value",
    )

    # Make the request
    operation = client.create_source(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateSourceRequest, dict]]

The request object. Request message for 'CreateSource' request.

parent str

Required. The Source's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

source Source

Required. The create request body. This corresponds to the source field on the request instance; if request is provided, this should not be set.

source_id str

Required. The source identifier. This corresponds to the source_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be Source Source message describes a specific vm migration Source resource. It contains the source environment information.

create_target_project

create_target_project(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateTargetProjectRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    target_project: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.TargetProject
    ] = None,
    target_project_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Creates a new TargetProject in a given project.

NOTE: TargetProject is a global resource; hence the only supported value for location is global.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_target_project():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateTargetProjectRequest(
        parent="parent_value",
        target_project_id="target_project_id_value",
    )

    # Make the request
    operation = client.create_target_project(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateTargetProjectRequest, dict]]

The request object. Request message for 'CreateTargetProject' request.

parent str

Required. The TargetProject's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

target_project TargetProject

Required. The create request body. This corresponds to the target_project field on the request instance; if request is provided, this should not be set.

target_project_id str

Required. The target_project identifier. This corresponds to the target_project_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be TargetProject TargetProject message represents a target Compute Engine project for a migration or a clone.

create_utilization_report

create_utilization_report(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.CreateUtilizationReportRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    utilization_report: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.UtilizationReport
    ] = None,
    utilization_report_id: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Creates a new UtilizationReport.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_create_utilization_report():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.CreateUtilizationReportRequest(
        parent="parent_value",
        utilization_report_id="utilization_report_id_value",
    )

    # Make the request
    operation = client.create_utilization_report(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.CreateUtilizationReportRequest, dict]]

The request object. Request message for 'CreateUtilizationReport' request.

parent str

Required. The Utilization Report's parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

utilization_report UtilizationReport

Required. The report to create. This corresponds to the utilization_report field on the request instance; if request is provided, this should not be set.

utilization_report_id str

Required. The ID to use for the report, which will become the final component of the reports's resource name. This value maximum length is 63 characters, and valid characters are /a-z][0-9]-/. It must start with an english letter and must not end with a hyphen. This corresponds to the utilization_report_id field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be UtilizationReport Utilization report details the utilization (CPU, memory, etc.) of selected source VMs.

cutover_job_path

cutover_job_path(
    project: str, location: str, source: str, migrating_vm: str, cutover_job: str
) -> str

Returns a fully-qualified cutover_job string.

datacenter_connector_path

datacenter_connector_path(
    project: str, location: str, source: str, datacenter_connector: str
) -> str

Returns a fully-qualified datacenter_connector string.

delete_datacenter_connector

delete_datacenter_connector(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.DeleteDatacenterConnectorRequest,
            dict,
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Deletes a single DatacenterConnector.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_delete_datacenter_connector():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.DeleteDatacenterConnectorRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_datacenter_connector(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.DeleteDatacenterConnectorRequest, dict]]

The request object. Request message for 'DeleteDatacenterConnector' request.

name str

Required. The DatacenterConnector name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be google.protobuf.empty_pb2.Empty A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

delete_group

delete_group(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.DeleteGroupRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Deletes a single Group.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_delete_group():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.DeleteGroupRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_group(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.DeleteGroupRequest, dict]]

The request object. Request message for 'DeleteGroup' request.

name str

Required. The Group name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be google.protobuf.empty_pb2.Empty A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

delete_migrating_vm

delete_migrating_vm(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.DeleteMigratingVmRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Deletes a single MigratingVm.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_delete_migrating_vm():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.DeleteMigratingVmRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_migrating_vm(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.DeleteMigratingVmRequest, dict]]

The request object. Request message for 'DeleteMigratingVm' request.

name str

Required. The name of the MigratingVm. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be google.protobuf.empty_pb2.Empty A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

delete_operation

delete_operation(
    request: typing.Optional[
        google.longrunning.operations_pb2.DeleteOperationRequest
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> None

Deletes a long-running operation.

This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED.

Parameters
NameDescription
request .operations_pb2.DeleteOperationRequest

The request object. Request message for DeleteOperation method.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

delete_source

delete_source(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.DeleteSourceRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Deletes a single Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_delete_source():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.DeleteSourceRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_source(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.DeleteSourceRequest, dict]]

The request object. Request message for 'DeleteSource' request.

name str

Required. The Source name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be google.protobuf.empty_pb2.Empty A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

delete_target_project

delete_target_project(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.DeleteTargetProjectRequest,
            dict,
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Deletes a single TargetProject.

NOTE: TargetProject is a global resource; hence the only supported value for location is global.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_delete_target_project():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.DeleteTargetProjectRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_target_project(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.DeleteTargetProjectRequest, dict]]

The request object. Request message for 'DeleteTargetProject' request.

name str

Required. The TargetProject name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be google.protobuf.empty_pb2.Empty A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

delete_utilization_report

delete_utilization_report(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.DeleteUtilizationReportRequest,
            dict,
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Deletes a single Utilization Report.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_delete_utilization_report():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.DeleteUtilizationReportRequest(
        name="name_value",
    )

    # Make the request
    operation = client.delete_utilization_report(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.DeleteUtilizationReportRequest, dict]]

The request object. Request message for 'DeleteUtilizationReport' request.

name str

Required. The Utilization Report name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be google.protobuf.empty_pb2.Empty A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

fetch_inventory

fetch_inventory(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.FetchInventoryRequest, dict
        ]
    ] = None,
    *,
    source: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.FetchInventoryResponse

List remote source's inventory of VMs. The remote source is the onprem vCenter (remote in the sense it's not in Compute Engine). The inventory describes the list of existing VMs in that source. Note that this operation lists the VMs on the remote source, as opposed to listing the MigratingVms resources in the vmmigration service.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_fetch_inventory():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.FetchInventoryRequest(
        source="source_value",
    )

    # Make the request
    response = await client.fetch_inventory(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.FetchInventoryRequest, dict]]

The request object. Request message for fetchInventory.

source str

Required. The name of the Source. This corresponds to the source field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.FetchInventoryResponseResponse message for fetchInventory.

finalize_migration

finalize_migration(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.FinalizeMigrationRequest, dict
        ]
    ] = None,
    *,
    migrating_vm: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Marks a migration as completed, deleting migration resources that are no longer being used. Only applicable after cutover is done.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_finalize_migration():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.FinalizeMigrationRequest(
        migrating_vm="migrating_vm_value",
    )

    # Make the request
    operation = client.finalize_migration(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.FinalizeMigrationRequest, dict]]

The request object. Request message for 'FinalizeMigration' request.

migrating_vm str

Required. The name of the MigratingVm. This corresponds to the migrating_vm field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be FinalizeMigrationResponse Response message for 'FinalizeMigration' request.

from_service_account_file

from_service_account_file(filename: str, *args, **kwargs)

Creates an instance of this client using the provided credentials file.

Parameter
NameDescription
filename str

The path to the service account private key json file.

Returns
TypeDescription
VmMigrationAsyncClientThe constructed client.

from_service_account_info

from_service_account_info(info: dict, *args, **kwargs)

Creates an instance of this client using the provided credentials info.

Parameter
NameDescription
info dict

The service account private key info.

Returns
TypeDescription
VmMigrationAsyncClientThe constructed client.

from_service_account_json

from_service_account_json(filename: str, *args, **kwargs)

Creates an instance of this client using the provided credentials file.

Parameter
NameDescription
filename str

The path to the service account private key json file.

Returns
TypeDescription
VmMigrationAsyncClientThe constructed client.

get_clone_job

get_clone_job(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetCloneJobRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.CloneJob

Gets details of a single CloneJob.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_clone_job():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetCloneJobRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_clone_job(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetCloneJobRequest, dict]]

The request object. Request message for 'GetCloneJob' request.

name str

Required. The name of the CloneJob. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.CloneJobCloneJob describes the process of creating a clone of a MigratingVM to the requested target based on the latest successful uploaded snapshots. While the migration cycles of a MigratingVm take place, it is possible to verify the uploaded VM can be started in the cloud, by creating a clone. The clone can be created without any downtime, and it is created using the latest snapshots which are already in the cloud. The cloneJob is only responsible for its work, not its products, which means once it is finished, it will never touch the instance it created. It will only delete it in case of the CloneJob being cancelled or upon failure to clone.

get_cutover_job

get_cutover_job(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetCutoverJobRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.CutoverJob

Gets details of a single CutoverJob.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_cutover_job():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetCutoverJobRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_cutover_job(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetCutoverJobRequest, dict]]

The request object. Request message for 'GetCutoverJob' request.

name str

Required. The name of the CutoverJob. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.CutoverJobCutoverJob message describes a cutover of a migrating VM. The CutoverJob is the operation of shutting down the VM, creating a snapshot and clonning the VM using the replicated snapshot.

get_datacenter_connector

get_datacenter_connector(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetDatacenterConnectorRequest,
            dict,
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.DatacenterConnector

Gets details of a single DatacenterConnector.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_datacenter_connector():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetDatacenterConnectorRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_datacenter_connector(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetDatacenterConnectorRequest, dict]]

The request object. Request message for 'GetDatacenterConnector' request.

name str

Required. The name of the DatacenterConnector. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.DatacenterConnectorDatacenterConnector message describes a connector between the Source and Google Cloud, which is installed on a vmware datacenter (an OVA vm installed by the user) to connect the Datacenter to Google Cloud and support vm migration data transfer.

get_group

get_group(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetGroupRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.Group

Gets details of a single Group.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_group():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetGroupRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_group(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetGroupRequest, dict]]

The request object. Request message for 'GetGroup' request.

name str

Required. The group name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.GroupDescribes message for 'Group' resource. The Group is a collections of several MigratingVms.

get_location

get_location(
    request: typing.Optional[
        google.cloud.location.locations_pb2.GetLocationRequest
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.location.locations_pb2.Location

Gets information about a location.

Parameters
NameDescription
request .location_pb2.GetLocationRequest

The request object. Request message for GetLocation method.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
.location_pb2.LocationLocation object.

get_migrating_vm

get_migrating_vm(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetMigratingVmRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.MigratingVm

Gets details of a single MigratingVm.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_migrating_vm():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetMigratingVmRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_migrating_vm(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetMigratingVmRequest, dict]]

The request object. Request message for 'GetMigratingVm' request.

name str

Required. The name of the MigratingVm. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.MigratingVmMigratingVm describes the VM that will be migrated from a Source environment and its replication state.

get_mtls_endpoint_and_cert_source

get_mtls_endpoint_and_cert_source(
    client_options: typing.Optional[
        google.api_core.client_options.ClientOptions
    ] = None,
)

Return the API endpoint and client cert source for mutual TLS.

The client cert source is determined in the following order: (1) if GOOGLE_API_USE_CLIENT_CERTIFICATE environment variable is not "true", the client cert source is None. (2) if client_options.client_cert_source is provided, use the provided one; if the default client cert source exists, use the default one; otherwise the client cert source is None.

The API endpoint is determined in the following order: (1) if client_options.api_endpoint if provided, use the provided one. (2) if GOOGLE_API_USE_CLIENT_CERTIFICATE environment variable is "always", use the default mTLS endpoint; if the environment variable is "never", use the default API endpoint; otherwise if client cert source exists, use the default mTLS endpoint, otherwise use the default API endpoint.

More details can be found at https://google.aip.dev/auth/4114.

Parameter
NameDescription
client_options google.api_core.client_options.ClientOptions

Custom options for the client. Only the api_endpoint and client_cert_source properties may be used in this method.

Exceptions
TypeDescription
google.auth.exceptions.MutualTLSChannelErrorIf any errors happen.
Returns
TypeDescription
Tuple[str, Callable[[], Tuple[bytes, bytes]]]returns the API endpoint and the client cert source to use.

get_operation

get_operation(
    request: typing.Optional[
        google.longrunning.operations_pb2.GetOperationRequest
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.longrunning.operations_pb2.Operation

Gets the latest state of a long-running operation.

Parameters
NameDescription
request .operations_pb2.GetOperationRequest

The request object. Request message for GetOperation method.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
.operations_pb2.OperationAn Operation object.

get_replication_cycle

get_replication_cycle(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetReplicationCycleRequest,
            dict,
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.ReplicationCycle

Gets details of a single ReplicationCycle.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_replication_cycle():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetReplicationCycleRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_replication_cycle(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetReplicationCycleRequest, dict]]

The request object. Request message for 'GetReplicationCycle' request.

name str

Required. The name of the ReplicationCycle. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.ReplicationCycleReplicationCycle contains information about the current replication cycle status.

get_source

get_source(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetSourceRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.Source

Gets details of a single Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_source():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetSourceRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_source(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetSourceRequest, dict]]

The request object. Request message for 'GetSource' request.

name str

Required. The Source name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.SourceSource message describes a specific vm migration Source resource. It contains the source environment information.

get_target_project

get_target_project(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetTargetProjectRequest, dict
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.TargetProject

Gets details of a single TargetProject.

NOTE: TargetProject is a global resource; hence the only supported value for location is global.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_target_project():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetTargetProjectRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_target_project(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetTargetProjectRequest, dict]]

The request object. Request message for 'GetTargetProject' call.

name str

Required. The TargetProject name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.TargetProjectTargetProject message represents a target Compute Engine project for a migration or a clone.

get_transport_class

get_transport_class() -> (
    typing.Type[
        google.cloud.vmmigration_v1.services.vm_migration.transports.base.VmMigrationTransport
    ]
)

Returns an appropriate transport class.

Parameter
NameDescription
label typing.Optional[str]

The name of the desired transport. If none is provided, then the first transport in the registry is used.

get_utilization_report

get_utilization_report(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.GetUtilizationReportRequest,
            dict,
        ]
    ] = None,
    *,
    name: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.types.vmmigration.UtilizationReport

Gets a single Utilization Report.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_get_utilization_report():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.GetUtilizationReportRequest(
        name="name_value",
    )

    # Make the request
    response = await client.get_utilization_report(request=request)

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.GetUtilizationReportRequest, dict]]

The request object. Request message for 'GetUtilizationReport' request.

name str

Required. The Utilization Report name. This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.types.UtilizationReportUtilization report details the utilization (CPU, memory, etc.) of selected source VMs.

group_path

group_path(project: str, location: str, group: str) -> str

Returns a fully-qualified group string.

list_clone_jobs

list_clone_jobs(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListCloneJobsRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.services.vm_migration.pagers.ListCloneJobsAsyncPager

Lists CloneJobs of a given migrating VM.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_clone_jobs():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListCloneJobsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_clone_jobs(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListCloneJobsRequest, dict]]

The request object. Request message for 'ListCloneJobsRequest' request.

parent str

Required. The parent, which owns this collection of source VMs. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListCloneJobsAsyncPagerResponse message for 'ListCloneJobs' request. Iterating over this object will yield results and resolve additional pages automatically.

list_cutover_jobs

list_cutover_jobs(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListCutoverJobsRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.services.vm_migration.pagers.ListCutoverJobsAsyncPager

Lists CutoverJobs of a given migrating VM.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_cutover_jobs():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListCutoverJobsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_cutover_jobs(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListCutoverJobsRequest, dict]]

The request object. Request message for 'ListCutoverJobsRequest' request.

parent str

Required. The parent, which owns this collection of migrating VMs. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListCutoverJobsAsyncPagerResponse message for 'ListCutoverJobs' request. Iterating over this object will yield results and resolve additional pages automatically.

list_datacenter_connectors

list_datacenter_connectors(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListDatacenterConnectorsRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> (
    google.cloud.vmmigration_v1.services.vm_migration.pagers.ListDatacenterConnectorsAsyncPager
)

Lists DatacenterConnectors in a given Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_datacenter_connectors():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListDatacenterConnectorsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_datacenter_connectors(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListDatacenterConnectorsRequest, dict]]

The request object. Request message for 'ListDatacenterConnectors' request.

parent str

Required. The parent, which owns this collection of connectors. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListDatacenterConnectorsAsyncPagerResponse message for 'ListDatacenterConnectors' request. Iterating over this object will yield results and resolve additional pages automatically.

list_groups

list_groups(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListGroupsRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.services.vm_migration.pagers.ListGroupsAsyncPager

Lists Groups in a given project and location.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_groups():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListGroupsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_groups(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListGroupsRequest, dict]]

The request object. Request message for 'ListGroups' request.

parent str

Required. The parent, which owns this collection of groups. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListGroupsAsyncPagerResponse message for 'ListGroups' request. Iterating over this object will yield results and resolve additional pages automatically.

list_locations

list_locations(
    request: typing.Optional[
        google.cloud.location.locations_pb2.ListLocationsRequest
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.location.locations_pb2.ListLocationsResponse

Lists information about the supported locations for this service.

Parameters
NameDescription
request .location_pb2.ListLocationsRequest

The request object. Request message for ListLocations method.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
.location_pb2.ListLocationsResponseResponse message for ListLocations method.

list_migrating_vms

list_migrating_vms(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListMigratingVmsRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> (
    google.cloud.vmmigration_v1.services.vm_migration.pagers.ListMigratingVmsAsyncPager
)

Lists MigratingVms in a given Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_migrating_vms():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListMigratingVmsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_migrating_vms(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListMigratingVmsRequest, dict]]

The request object. Request message for 'LisMigratingVmsRequest' request.

parent str

Required. The parent, which owns this collection of MigratingVms. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListMigratingVmsAsyncPagerResponse message for 'ListMigratingVms' request. Iterating over this object will yield results and resolve additional pages automatically.

list_operations

list_operations(
    request: typing.Optional[
        google.longrunning.operations_pb2.ListOperationsRequest
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.longrunning.operations_pb2.ListOperationsResponse

Lists operations that match the specified filter in the request.

Parameters
NameDescription
request .operations_pb2.ListOperationsRequest

The request object. Request message for ListOperations method.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
.operations_pb2.ListOperationsResponseResponse message for ListOperations method.

list_replication_cycles

list_replication_cycles(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListReplicationCyclesRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> (
    google.cloud.vmmigration_v1.services.vm_migration.pagers.ListReplicationCyclesAsyncPager
)

Lists ReplicationCycles in a given MigratingVM.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_replication_cycles():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListReplicationCyclesRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_replication_cycles(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListReplicationCyclesRequest, dict]]

The request object. Request message for 'LisReplicationCyclesRequest' request.

parent str

Required. The parent, which owns this collection of ReplicationCycles. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListReplicationCyclesAsyncPagerResponse message for 'ListReplicationCycles' request. Iterating over this object will yield results and resolve additional pages automatically.

list_sources

list_sources(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListSourcesRequest, dict
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.cloud.vmmigration_v1.services.vm_migration.pagers.ListSourcesAsyncPager

Lists Sources in a given project and location.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_sources():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListSourcesRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_sources(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListSourcesRequest, dict]]

The request object. Request message for 'ListSources' request.

parent str

Required. The parent, which owns this collection of sources. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListSourcesAsyncPagerResponse message for 'ListSources' request. Iterating over this object will yield results and resolve additional pages automatically.

list_target_projects

list_target_projects(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListTargetProjectsRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> (
    google.cloud.vmmigration_v1.services.vm_migration.pagers.ListTargetProjectsAsyncPager
)

Lists TargetProjects in a given project.

NOTE: TargetProject is a global resource; hence the only supported value for location is global.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_target_projects():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListTargetProjectsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_target_projects(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListTargetProjectsRequest, dict]]

The request object. Request message for 'ListTargetProjects' call.

parent str

Required. The parent, which owns this collection of targets. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListTargetProjectsAsyncPagerResponse message for 'ListTargetProjects' call. Iterating over this object will yield results and resolve additional pages automatically.

list_utilization_reports

list_utilization_reports(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ListUtilizationReportsRequest,
            dict,
        ]
    ] = None,
    *,
    parent: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> (
    google.cloud.vmmigration_v1.services.vm_migration.pagers.ListUtilizationReportsAsyncPager
)

Lists Utilization Reports of the given Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_list_utilization_reports():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ListUtilizationReportsRequest(
        parent="parent_value",
        page_token="page_token_value",
    )

    # Make the request
    page_result = client.list_utilization_reports(request=request)

    # Handle the response
    async for response in page_result:
        print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ListUtilizationReportsRequest, dict]]

The request object. Request message for 'ListUtilizationReports' request.

parent str

Required. The Utilization Reports parent. This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.vmmigration_v1.services.vm_migration.pagers.ListUtilizationReportsAsyncPagerResponse message for 'ListUtilizationReports' request. Iterating over this object will yield results and resolve additional pages automatically.

migrating_vm_path

migrating_vm_path(
    project: str, location: str, source: str, migrating_vm: str
) -> str

Returns a fully-qualified migrating_vm string.

parse_clone_job_path

parse_clone_job_path(path: str) -> typing.Dict[str, str]

Parses a clone_job path into its component segments.

parse_common_billing_account_path

parse_common_billing_account_path(path: str) -> typing.Dict[str, str]

Parse a billing_account path into its component segments.

parse_common_folder_path

parse_common_folder_path(path: str) -> typing.Dict[str, str]

Parse a folder path into its component segments.

parse_common_location_path

parse_common_location_path(path: str) -> typing.Dict[str, str]

Parse a location path into its component segments.

parse_common_organization_path

parse_common_organization_path(path: str) -> typing.Dict[str, str]

Parse a organization path into its component segments.

parse_common_project_path

parse_common_project_path(path: str) -> typing.Dict[str, str]

Parse a project path into its component segments.

parse_cutover_job_path

parse_cutover_job_path(path: str) -> typing.Dict[str, str]

Parses a cutover_job path into its component segments.

parse_datacenter_connector_path

parse_datacenter_connector_path(path: str) -> typing.Dict[str, str]

Parses a datacenter_connector path into its component segments.

parse_group_path

parse_group_path(path: str) -> typing.Dict[str, str]

Parses a group path into its component segments.

parse_migrating_vm_path

parse_migrating_vm_path(path: str) -> typing.Dict[str, str]

Parses a migrating_vm path into its component segments.

parse_replication_cycle_path

parse_replication_cycle_path(path: str) -> typing.Dict[str, str]

Parses a replication_cycle path into its component segments.

parse_source_path

parse_source_path(path: str) -> typing.Dict[str, str]

Parses a source path into its component segments.

parse_target_project_path

parse_target_project_path(path: str) -> typing.Dict[str, str]

Parses a target_project path into its component segments.

parse_utilization_report_path

parse_utilization_report_path(path: str) -> typing.Dict[str, str]

Parses a utilization_report path into its component segments.

pause_migration

pause_migration(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.PauseMigrationRequest, dict
        ]
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Pauses a migration for a VM. If cycle tasks are running they will be cancelled, preserving source task data. Further replication cycles will not be triggered while the VM is paused.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_pause_migration():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.PauseMigrationRequest(
        migrating_vm="migrating_vm_value",
    )

    # Make the request
    operation = client.pause_migration(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.PauseMigrationRequest, dict]]

The request object. Request message for 'PauseMigration' request.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be PauseMigrationResponse Response message for 'PauseMigration' request.

remove_group_migration

remove_group_migration(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.RemoveGroupMigrationRequest,
            dict,
        ]
    ] = None,
    *,
    group: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Removes a MigratingVm from a Group.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_remove_group_migration():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.RemoveGroupMigrationRequest(
        group="group_value",
    )

    # Make the request
    operation = client.remove_group_migration(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.RemoveGroupMigrationRequest, dict]]

The request object. Request message for 'RemoveMigration' request.

group str

Required. The name of the Group. This corresponds to the group field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be RemoveGroupMigrationResponse Response message for 'RemoveMigration' request.

replication_cycle_path

replication_cycle_path(
    project: str, location: str, source: str, migrating_vm: str, replication_cycle: str
) -> str

Returns a fully-qualified replication_cycle string.

resume_migration

resume_migration(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.ResumeMigrationRequest, dict
        ]
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Resumes a migration for a VM. When called on a paused migration, will start the process of uploading data and creating snapshots; when called on a completed cut-over migration, will update the migration to active state and start the process of uploading data and creating snapshots.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_resume_migration():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.ResumeMigrationRequest(
        migrating_vm="migrating_vm_value",
    )

    # Make the request
    operation = client.resume_migration(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.ResumeMigrationRequest, dict]]

The request object. Request message for 'ResumeMigration' request.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be ResumeMigrationResponse Response message for 'ResumeMigration' request.

source_path

source_path(project: str, location: str, source: str) -> str

Returns a fully-qualified source string.

start_migration

start_migration(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.StartMigrationRequest, dict
        ]
    ] = None,
    *,
    migrating_vm: typing.Optional[str] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Starts migration for a VM. Starts the process of uploading data and creating snapshots, in replication cycles scheduled by the policy.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_start_migration():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.StartMigrationRequest(
        migrating_vm="migrating_vm_value",
    )

    # Make the request
    operation = client.start_migration(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.StartMigrationRequest, dict]]

The request object. Request message for 'StartMigrationRequest' request.

migrating_vm str

Required. The name of the MigratingVm. This corresponds to the migrating_vm field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be StartMigrationResponse Response message for 'StartMigration' request.

target_project_path

target_project_path(project: str, location: str, target_project: str) -> str

Returns a fully-qualified target_project string.

update_group

update_group(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.UpdateGroupRequest, dict
        ]
    ] = None,
    *,
    group: typing.Optional[google.cloud.vmmigration_v1.types.vmmigration.Group] = None,
    update_mask: typing.Optional[google.protobuf.field_mask_pb2.FieldMask] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Updates the parameters of a single Group.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_update_group():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.UpdateGroupRequest(
    )

    # Make the request
    operation = client.update_group(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.UpdateGroupRequest, dict]]

The request object. Update message for 'UpdateGroups' request.

group Group

Required. The update request body. This corresponds to the group field on the request instance; if request is provided, this should not be set.

update_mask google.protobuf.field_mask_pb2.FieldMask

Field mask is used to specify the fields to be overwritten in the Group resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. This corresponds to the update_mask field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be Group Describes message for 'Group' resource. The Group is a collections of several MigratingVms.

update_migrating_vm

update_migrating_vm(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.UpdateMigratingVmRequest, dict
        ]
    ] = None,
    *,
    migrating_vm: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.MigratingVm
    ] = None,
    update_mask: typing.Optional[google.protobuf.field_mask_pb2.FieldMask] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Updates the parameters of a single MigratingVm.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_update_migrating_vm():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.UpdateMigratingVmRequest(
    )

    # Make the request
    operation = client.update_migrating_vm(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.UpdateMigratingVmRequest, dict]]

The request object. Request message for 'UpdateMigratingVm' request.

migrating_vm MigratingVm

Required. The update request body. This corresponds to the migrating_vm field on the request instance; if request is provided, this should not be set.

update_mask google.protobuf.field_mask_pb2.FieldMask

Field mask is used to specify the fields to be overwritten in the MigratingVm resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. This corresponds to the update_mask field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be MigratingVm MigratingVm describes the VM that will be migrated from a Source environment and its replication state.

update_source

update_source(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.UpdateSourceRequest, dict
        ]
    ] = None,
    *,
    source: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.Source
    ] = None,
    update_mask: typing.Optional[google.protobuf.field_mask_pb2.FieldMask] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Updates the parameters of a single Source.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_update_source():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.UpdateSourceRequest(
    )

    # Make the request
    operation = client.update_source(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.UpdateSourceRequest, dict]]

The request object. Update message for 'UpdateSources' request.

source Source

Required. The update request body. This corresponds to the source field on the request instance; if request is provided, this should not be set.

update_mask google.protobuf.field_mask_pb2.FieldMask

Field mask is used to specify the fields to be overwritten in the Source resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. This corresponds to the update_mask field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be Source Source message describes a specific vm migration Source resource. It contains the source environment information.

update_target_project

update_target_project(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.UpdateTargetProjectRequest,
            dict,
        ]
    ] = None,
    *,
    target_project: typing.Optional[
        google.cloud.vmmigration_v1.types.vmmigration.TargetProject
    ] = None,
    update_mask: typing.Optional[google.protobuf.field_mask_pb2.FieldMask] = None,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Updates the parameters of a single TargetProject.

NOTE: TargetProject is a global resource; hence the only supported value for location is global.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_update_target_project():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.UpdateTargetProjectRequest(
    )

    # Make the request
    operation = client.update_target_project(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.UpdateTargetProjectRequest, dict]]

The request object. Update message for 'UpdateTargetProject' request.

target_project TargetProject

Required. The update request body. This corresponds to the target_project field on the request instance; if request is provided, this should not be set.

update_mask google.protobuf.field_mask_pb2.FieldMask

Field mask is used to specify the fields to be overwritten in the TargetProject resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. This corresponds to the update_mask field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be TargetProject TargetProject message represents a target Compute Engine project for a migration or a clone.

upgrade_appliance

upgrade_appliance(
    request: typing.Optional[
        typing.Union[
            google.cloud.vmmigration_v1.types.vmmigration.UpgradeApplianceRequest, dict
        ]
    ] = None,
    *,
    retry: typing.Union[
        google.api_core.retry_async.AsyncRetry,
        google.api_core.gapic_v1.method._MethodDefault,
    ] = _MethodDefault._DEFAULT_VALUE,
    timeout: typing.Union[float, object] = _MethodDefault._DEFAULT_VALUE,
    metadata: typing.Sequence[typing.Tuple[str, str]] = ()
) -> google.api_core.operation_async.AsyncOperation

Upgrades the appliance relate to this DatacenterConnector to the in-place updateable version.

# This snippet has been automatically generated and should be regarded as a
# code template only.
# It will require modifications to work:
# - It may require correct/in-range values for request initialization.
# - It may require specifying regional endpoints when creating the service
#   client as shown in:
#   https://googleapis.dev/python/google-api-core/latest/client_options.html
from google.cloud import vmmigration_v1

async def sample_upgrade_appliance():
    # Create a client
    client = vmmigration_v1.VmMigrationAsyncClient()

    # Initialize request argument(s)
    request = vmmigration_v1.UpgradeApplianceRequest(
        datacenter_connector="datacenter_connector_value",
    )

    # Make the request
    operation = client.upgrade_appliance(request=request)

    print("Waiting for operation to complete...")

    response = (await operation).result()

    # Handle the response
    print(response)
Parameters
NameDescription
request Optional[Union[google.cloud.vmmigration_v1.types.UpgradeApplianceRequest, dict]]

The request object. Request message for 'UpgradeAppliance' request.

retry google.api_core.retry_async.AsyncRetry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be UpgradeApplianceResponse Response message for 'UpgradeAppliance' request.

utilization_report_path

utilization_report_path(
    project: str, location: str, source: str, utilization_report: str
) -> str

Returns a fully-qualified utilization_report string.