Skip to main content

collectors

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

Overview

Namecollectors
TypeResource
Idgoogle.rapidmigrationassessment.collectors

Fields

NameDatatypeDescription
namestringname of resource.
descriptionstringUser specified description of the Collector.
bucketstringOutput only. Store cloud storage bucket name (which is a guid) created with this Collector.
clientVersionstringOutput only. Client version.
collectionDaysintegerHow many days to collect data.
createTimestringOutput only. Create time stamp.
displayNamestringUser specified name of the Collector.
eulaUristringUri for EULA (End User License Agreement) from customer.
expectedAssetCountstringUser specified expected asset count.
guestOsScanobjectMessage describing a MC Source of type Guest OS Scan.
labelsobjectLabels as key value pairs.
serviceAccountstringService Account email used to ingest data to this Collector.
statestringOutput only. State of the Collector.
updateTimestringOutput only. Update time stamp.
vsphereScanobjectMessage describing a MC Source of type VSphere Scan.

Methods

NameAccessible byRequired ParamsDescription
getSELECTcollectorsId, locationsId, projectsIdGets details of a single Collector.
listSELECTlocationsId, projectsIdLists Collectors in a given project and location.
createINSERTlocationsId, projectsIdCreate a Collector to manage the on-prem appliance which collects information about Customer assets.
deleteDELETEcollectorsId, locationsId, projectsIdDeletes a single Collector - changes state of collector to "Deleting". Background jobs does final deletion thorugh producer api.
patchUPDATEcollectorsId, locationsId, projectsIdUpdates the parameters of a single Collector.
pauseEXECcollectorsId, locationsId, projectsIdPauses the given collector.
registerEXECcollectorsId, locationsId, projectsIdRegisters the given collector.
resumeEXECcollectorsId, locationsId, projectsIdResumes the given collector.

SELECT examples

Lists Collectors in a given project and location.

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

INSERT example

Use the following StackQL query and manifest file to create a new collectors resource.

/*+ create */
INSERT INTO google.rapidmigrationassessment.collectors (
locationsId,
projectsId,
name,
labels,
displayName,
description,
serviceAccount,
expectedAssetCount,
collectionDays,
eulaUri
)
SELECT
'{{ locationsId }}',
'{{ projectsId }}',
'{{ name }}',
'{{ labels }}',
'{{ displayName }}',
'{{ description }}',
'{{ serviceAccount }}',
'{{ expectedAssetCount }}',
'{{ collectionDays }}',
'{{ eulaUri }}'
;

UPDATE example

Updates a collectors resource.

/*+ update */
UPDATE google.rapidmigrationassessment.collectors
SET
name = '{{ name }}',
labels = '{{ labels }}',
displayName = '{{ displayName }}',
description = '{{ description }}',
serviceAccount = '{{ serviceAccount }}',
expectedAssetCount = '{{ expectedAssetCount }}',
collectionDays = '{{ collectionDays }}',
eulaUri = '{{ eulaUri }}'
WHERE
collectorsId = '{{ collectorsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

DELETE example

Deletes the specified collectors resource.

/*+ delete */
DELETE FROM google.rapidmigrationassessment.collectors
WHERE collectorsId = '{{ collectorsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';