forked from aquasecurity/cloud-security-remediation-guides
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #93 from rtkwlf/AWN-194635
AWN-194635
- Loading branch information
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
[![CloudSploit](https://cloudsploit.com/img/logo-new-big-text-100.png "CloudSploit")](https://cloudsploit.com) | ||
|
||
# GOOGLE / Dataflow / Dataflow Hanged Jobs | ||
## Quick Info | ||
|
||
| | | | ||
|-|-| | ||
| **Plugin Title** | Dataflow Hanged Jobs | | ||
| **Cloud** | GOOGLE | | ||
| **Category** | Datflow | | ||
| **Description** | Ensure that Cloud Dataflow jobs are not in same state for more than defined amount of time. | | ||
| **More Info** | Cloud Dataflow jobs transit between different states and normally reach terminal state. If they stay in same state for abnormal amount of time, job administrator should stop such jobs to save unnecessary cost. | | ||
| **GOOGLE Link** | https://cloud.google.com/sdk/gcloud/reference/dataflow/jobs/cancel | | ||
| **Recommended Action** | Cancel/stop Dataflow jobs which are in same state for more than set amount of time. | | ||
|
||
## Detailed Remediation Steps | ||
1. The 'gcloud dataflow jobs cancel' commandlet cancels all jobs that match the command line arguments. | ||
|
||
2. To cancel jobs, log into the Google Cloud Console and open a cloud shell instance. See [Using Cloud Shell](#https://cloud.google.com/shell/docs/using-cloud-shell) for more details on access. | ||
|
||
3. Run the command in the following manner, replacing the variables with values corresponding to your organization: | ||
``` | ||
gcloud dataflow jobs cancel JOB_ID [JOB_ID …] [--force] [--region=REGION_ID] [GCLOUD_WIDE_FLAG …] | ||
``` | ||
|
||
4. This variant is also available: | ||
``` | ||
gcloud beta dataflow jobs cancel | ||
``` |