dlp_jobs
Creates, updates, deletes, gets or lists a dlp_jobs
resource.
Overview
Name | dlp_jobs |
Type | Resource |
Id | google.dlp.dlp_jobs |
Fields
The following fields are returned by SELECT
queries:
- projects_locations_dlp_jobs_get
- projects_locations_dlp_jobs_list
- projects_dlp_jobs_get
- organizations_locations_dlp_jobs_list
- projects_dlp_jobs_list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The server-assigned name. |
actionDetails | array | Events that should occur after the job has completed. |
createTime | string (google-datetime) | Time when the job was created. |
endTime | string (google-datetime) | Time when the job finished. |
errors | array | A stream of errors encountered running the job. |
inspectDetails | object | Results from inspecting a data source. (id: GooglePrivacyDlpV2InspectDataSourceDetails) |
jobTriggerName | string | If created by a job trigger, the resource name of the trigger that instantiated the job. |
lastModified | string (google-datetime) | Time when the job was last modified by the system. |
riskDetails | object | Results from analyzing risk of a data source. (id: GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails) |
startTime | string (google-datetime) | Time when the job started. |
state | string | State of a job. |
type | string | The type of job. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The server-assigned name. |
actionDetails | array | Events that should occur after the job has completed. |
createTime | string (google-datetime) | Time when the job was created. |
endTime | string (google-datetime) | Time when the job finished. |
errors | array | A stream of errors encountered running the job. |
inspectDetails | object | Results from inspecting a data source. (id: GooglePrivacyDlpV2InspectDataSourceDetails) |
jobTriggerName | string | If created by a job trigger, the resource name of the trigger that instantiated the job. |
lastModified | string (google-datetime) | Time when the job was last modified by the system. |
riskDetails | object | Results from analyzing risk of a data source. (id: GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails) |
startTime | string (google-datetime) | Time when the job started. |
state | string | State of a job. |
type | string | The type of job. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The server-assigned name. |
actionDetails | array | Events that should occur after the job has completed. |
createTime | string (google-datetime) | Time when the job was created. |
endTime | string (google-datetime) | Time when the job finished. |
errors | array | A stream of errors encountered running the job. |
inspectDetails | object | Results from inspecting a data source. (id: GooglePrivacyDlpV2InspectDataSourceDetails) |
jobTriggerName | string | If created by a job trigger, the resource name of the trigger that instantiated the job. |
lastModified | string (google-datetime) | Time when the job was last modified by the system. |
riskDetails | object | Results from analyzing risk of a data source. (id: GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails) |
startTime | string (google-datetime) | Time when the job started. |
state | string | State of a job. |
type | string | The type of job. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The server-assigned name. |
actionDetails | array | Events that should occur after the job has completed. |
createTime | string (google-datetime) | Time when the job was created. |
endTime | string (google-datetime) | Time when the job finished. |
errors | array | A stream of errors encountered running the job. |
inspectDetails | object | Results from inspecting a data source. (id: GooglePrivacyDlpV2InspectDataSourceDetails) |
jobTriggerName | string | If created by a job trigger, the resource name of the trigger that instantiated the job. |
lastModified | string (google-datetime) | Time when the job was last modified by the system. |
riskDetails | object | Results from analyzing risk of a data source. (id: GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails) |
startTime | string (google-datetime) | Time when the job started. |
state | string | State of a job. |
type | string | The type of job. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The server-assigned name. |
actionDetails | array | Events that should occur after the job has completed. |
createTime | string (google-datetime) | Time when the job was created. |
endTime | string (google-datetime) | Time when the job finished. |
errors | array | A stream of errors encountered running the job. |
inspectDetails | object | Results from inspecting a data source. (id: GooglePrivacyDlpV2InspectDataSourceDetails) |
jobTriggerName | string | If created by a job trigger, the resource name of the trigger that instantiated the job. |
lastModified | string (google-datetime) | Time when the job was last modified by the system. |
riskDetails | object | Results from analyzing risk of a data source. (id: GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails) |
startTime | string (google-datetime) | Time when the job started. |
state | string | State of a job. |
type | string | The type of job. |
Methods
The following methods are available for this resource:
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.
Name | Datatype | Description |
---|---|---|
dlpJobsId | string | |
locationsId | string | |
organizationsId | string | |
projectsId | string | |
filter | string | |
locationId | string | |
orderBy | string | |
pageSize | integer (int32) | |
pageToken | string | |
type | string |
SELECT
examples
- projects_locations_dlp_jobs_get
- projects_locations_dlp_jobs_list
- projects_dlp_jobs_get
- organizations_locations_dlp_jobs_list
- projects_dlp_jobs_list
Gets the latest state of a long-running DlpJob. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
SELECT
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
FROM google.dlp.dlp_jobs
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND dlpJobsId = '{{ dlpJobsId }}' -- required;
Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
SELECT
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
FROM google.dlp.dlp_jobs
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND filter = '{{ filter }}'
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND type = '{{ type }}'
AND orderBy = '{{ orderBy }}'
AND locationId = '{{ locationId }}';
Gets the latest state of a long-running DlpJob. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
SELECT
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
FROM google.dlp.dlp_jobs
WHERE projectsId = '{{ projectsId }}' -- required
AND dlpJobsId = '{{ dlpJobsId }}' -- required;
Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
SELECT
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
FROM google.dlp.dlp_jobs
WHERE organizationsId = '{{ organizationsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND filter = '{{ filter }}'
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND type = '{{ type }}'
AND orderBy = '{{ orderBy }}'
AND locationId = '{{ locationId }}';
Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
SELECT
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
FROM google.dlp.dlp_jobs
WHERE projectsId = '{{ projectsId }}' -- required
AND filter = '{{ filter }}'
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND type = '{{ type }}'
AND orderBy = '{{ orderBy }}'
AND locationId = '{{ locationId }}';
INSERT
examples
- projects_locations_dlp_jobs_create
- projects_dlp_jobs_create
- Manifest
Creates a new job to inspect storage or calculate risk metrics. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated.
INSERT INTO google.dlp.dlp_jobs (
data__inspectJob,
data__riskJob,
data__jobId,
data__locationId,
projectsId,
locationsId
)
SELECT
'{{ inspectJob }}',
'{{ riskJob }}',
'{{ jobId }}',
'{{ locationId }}',
'{{ projectsId }}',
'{{ locationsId }}'
RETURNING
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
;
Creates a new job to inspect storage or calculate risk metrics. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated.
INSERT INTO google.dlp.dlp_jobs (
data__inspectJob,
data__riskJob,
data__jobId,
data__locationId,
projectsId
)
SELECT
'{{ inspectJob }}',
'{{ riskJob }}',
'{{ jobId }}',
'{{ locationId }}',
'{{ projectsId }}'
RETURNING
name,
actionDetails,
createTime,
endTime,
errors,
inspectDetails,
jobTriggerName,
lastModified,
riskDetails,
startTime,
state,
type
;
# Description fields are for documentation purposes
- name: dlp_jobs
props:
- name: projectsId
value: string
description: Required parameter for the dlp_jobs resource.
- name: locationsId
value: string
description: Required parameter for the dlp_jobs resource.
- name: inspectJob
value: object
description: >
An inspection job scans a storage repository for InfoTypes.
- name: riskJob
value: object
description: >
A risk analysis job calculates re-identification risk metrics for a BigQuery table.
- name: jobId
value: string
description: >
The job id can contain uppercase and lowercase letters, numbers, and hyphens; that is, it must match the regular expression: `[a-zA-Z\d-_]+`. The maximum length is 100 characters. Can be empty to allow the system to generate one.
- name: locationId
value: string
description: >
Deprecated. This field has no effect.
DELETE
examples
- projects_locations_dlp_jobs_delete
- projects_dlp_jobs_delete
Deletes a long-running DlpJob. This method indicates that the client is no longer interested in the DlpJob result. The job will be canceled if possible. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
DELETE FROM google.dlp.dlp_jobs
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND dlpJobsId = '{{ dlpJobsId }}' --required;
Deletes a long-running DlpJob. This method indicates that the client is no longer interested in the DlpJob result. The job will be canceled if possible. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
DELETE FROM google.dlp.dlp_jobs
WHERE projectsId = '{{ projectsId }}' --required
AND dlpJobsId = '{{ dlpJobsId }}' --required;
Lifecycle Methods
- projects_locations_dlp_jobs_cancel
- projects_locations_dlp_jobs_hybrid_inspect
- projects_locations_dlp_jobs_finish
- projects_dlp_jobs_cancel
Starts asynchronous cancellation on a long-running DlpJob. The server makes a best effort to cancel the DlpJob, but success is not guaranteed. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
EXEC google.dlp.dlp_jobs.projects_locations_dlp_jobs_cancel
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@dlpJobsId='{{ dlpJobsId }}' --required;
Inspect hybrid content and store findings to a job. To review the findings, inspect the job. Inspection will occur asynchronously.
EXEC google.dlp.dlp_jobs.projects_locations_dlp_jobs_hybrid_inspect
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@dlpJobsId='{{ dlpJobsId }}' --required
@@json=
'{
"hybridItem": "{{ hybridItem }}"
}';
Finish a running hybrid DlpJob. Triggers the finalization steps and running of any enabled actions that have not yet run.
EXEC google.dlp.dlp_jobs.projects_locations_dlp_jobs_finish
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@dlpJobsId='{{ dlpJobsId }}' --required;
Starts asynchronous cancellation on a long-running DlpJob. The server makes a best effort to cancel the DlpJob, but success is not guaranteed. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more.
EXEC google.dlp.dlp_jobs.projects_dlp_jobs_cancel
@projectsId='{{ projectsId }}' --required,
@dlpJobsId='{{ dlpJobsId }}' --required;