Skip to main content

sources

Creates, updates, deletes, gets or lists a sources resource.

Overview

Namesources
TypeResource
Idgoogle.vmmigration.sources

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringOutput only. The Source name.
awsobjectAWS type source details. (id: AwsSourceDetails)
azureobjectAzure type source details. (id: AzureSourceDetails)
createTimestring (google-datetime)Output only. The create time timestamp.
descriptionstringUser-provided description of the source.
encryptionobjectOptional. Immutable. The encryption details of the source data stored by the service. (id: Encryption)
labelsobjectThe labels of the source.
updateTimestring (google-datetime)Output only. The update time timestamp.
vmwareobjectVmware type source details. (id: VmwareSourceDetails)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, sourcesIdGets details of a single Source.
listselectprojectsId, locationsIdpageSize, pageToken, filter, orderByLists Sources in a given project and location.
createinsertprojectsId, locationsIdsourceId, requestIdCreates a new Source in a given project and location.
patchupdateprojectsId, locationsId, sourcesIdupdateMask, requestIdUpdates the parameters of a single Source.
deletedeleteprojectsId, locationsId, sourcesIdrequestIdDeletes a single Source.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
locationsIdstring
projectsIdstring
sourcesIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring
requestIdstring
sourceIdstring
updateMaskstring (google-fieldmask)

SELECT examples

Gets details of a single Source.

SELECT
name,
aws,
azure,
createTime,
description,
encryption,
labels,
updateTime,
vmware
FROM google.vmmigration.sources
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND sourcesId = '{{ sourcesId }}' -- required;

INSERT examples

Creates a new Source in a given project and location.

INSERT INTO google.vmmigration.sources (
data__vmware,
data__aws,
data__azure,
data__labels,
data__description,
data__encryption,
projectsId,
locationsId,
sourceId,
requestId
)
SELECT
'{{ vmware }}',
'{{ aws }}',
'{{ azure }}',
'{{ labels }}',
'{{ description }}',
'{{ encryption }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ sourceId }}',
'{{ requestId }}'
RETURNING
name,
done,
error,
metadata,
response
;

UPDATE examples

Updates the parameters of a single Source.

UPDATE google.vmmigration.sources
SET
data__vmware = '{{ vmware }}',
data__aws = '{{ aws }}',
data__azure = '{{ azure }}',
data__labels = '{{ labels }}',
data__description = '{{ description }}',
data__encryption = '{{ encryption }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND sourcesId = '{{ sourcesId }}' --required
AND updateMask = '{{ updateMask}}'
AND requestId = '{{ requestId}}'
RETURNING
name,
done,
error,
metadata,
response;

DELETE examples

Deletes a single Source.

DELETE FROM google.vmmigration.sources
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND sourcesId = '{{ sourcesId }}' --required
AND requestId = '{{ requestId }}';