Skip to main content

collectors

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

Overview​

Namecollectors
TypeResource
Idgoogle.rapidmigrationassessment.collectors

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringname of resource.
bucketstringOutput only. Store cloud storage bucket name (which is a guid) created with this Collector.
clientVersionstringOutput only. Client version.
collectionDaysinteger (int32)How many days to collect data.
createTimestring (google-datetime)Output only. Create time stamp.
descriptionstringUser specified description of the Collector.
displayNamestringUser specified name of the Collector.
eulaUristringUri for EULA (End User License Agreement) from customer.
expectedAssetCountstring (int64)User specified expected asset count.
guestOsScanobjectOutput only. Reference to MC Source Guest Os Scan. (id: GuestOsScan)
labelsobjectLabels as key value pairs.
serviceAccountstringService Account email used to ingest data to this Collector.
statestringOutput only. State of the Collector. (STATE_UNSPECIFIED, STATE_INITIALIZING, STATE_READY_TO_USE, STATE_REGISTERED, STATE_ACTIVE, STATE_PAUSED, STATE_DELETING, STATE_DECOMMISSIONED, STATE_ERROR)
updateTimestring (google-datetime)Output only. Update time stamp.
vsphereScanobjectOutput only. Reference to MC Source vsphere_scan. (id: VSphereScan)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, collectorsIdGets details of a single Collector.
listselectprojectsId, locationsIdfilter, orderBy, pageSize, pageTokenLists Collectors in a given project and location.
createinsertprojectsId, locationsIdcollectorId, requestIdCreate a Collector to manage the on-prem appliance which collects information about Customer assets.
patchupdateprojectsId, locationsId, collectorsIdrequestId, updateMaskUpdates the parameters of a single Collector.
deletedeleteprojectsId, locationsId, collectorsIdrequestIdDeletes a single Collector - changes state of collector to "Deleting". Background jobs does final deletion through producer API.
pauseexecprojectsId, locationsId, collectorsIdPauses the given collector.
registerexecprojectsId, locationsId, collectorsIdRegisters the given collector.
resumeexecprojectsId, locationsId, collectorsIdResumes the given collector.

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
collectorsIdstring
locationsIdstring
projectsIdstring
collectorIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring
requestIdstring
updateMaskstring (google-fieldmask)

SELECT examples​

Gets details of a single Collector.

SELECT
name,
bucket,
clientVersion,
collectionDays,
createTime,
description,
displayName,
eulaUri,
expectedAssetCount,
guestOsScan,
labels,
serviceAccount,
state,
updateTime,
vsphereScan
FROM google.rapidmigrationassessment.collectors
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND collectorsId = '{{ collectorsId }}' -- required
;

INSERT examples​

Create a Collector to manage the on-prem appliance which collects information about Customer assets.

INSERT INTO google.rapidmigrationassessment.collectors (
data__collectionDays,
data__description,
data__displayName,
data__eulaUri,
data__expectedAssetCount,
data__labels,
data__name,
data__serviceAccount,
projectsId,
locationsId,
collectorId,
requestId
)
SELECT
{{ collectionDays }},
'{{ description }}',
'{{ displayName }}',
'{{ eulaUri }}',
'{{ expectedAssetCount }}',
'{{ labels }}',
'{{ name }}',
'{{ serviceAccount }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ collectorId }}',
'{{ requestId }}'
RETURNING
name,
done,
error,
metadata,
response
;

UPDATE examples​

Updates the parameters of a single Collector.

UPDATE google.rapidmigrationassessment.collectors
SET
data__collectionDays = {{ collectionDays }},
data__description = '{{ description }}',
data__displayName = '{{ displayName }}',
data__eulaUri = '{{ eulaUri }}',
data__expectedAssetCount = '{{ expectedAssetCount }}',
data__labels = '{{ labels }}',
data__name = '{{ name }}',
data__serviceAccount = '{{ serviceAccount }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND collectorsId = '{{ collectorsId }}' --required
AND requestId = '{{ requestId}}'
AND updateMask = '{{ updateMask}}'
RETURNING
name,
done,
error,
metadata,
response;

DELETE examples​

Deletes a single Collector - changes state of collector to "Deleting". Background jobs does final deletion through producer API.

DELETE FROM google.rapidmigrationassessment.collectors
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND collectorsId = '{{ collectorsId }}' --required
AND requestId = '{{ requestId }}'
;

Lifecycle Methods​

Pauses the given collector.

EXEC google.rapidmigrationassessment.collectors.pause
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@collectorsId='{{ collectorsId }}' --required
@@json=
'{
"requestId": "{{ requestId }}"
}'
;