Last active
October 30, 2018 18:08
-
-
Save allanbatista/3c5c617bf4fa11bfda3ca65652898e07 to your computer and use it in GitHub Desktop.
Create new Custom Template and Dataflow JOB from DataflowTemplates git repository
This file contains hidden or 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
| mvn compile exec:java \ | |
| -Dexec.mainClass=com.google.cloud.teleport.templates.PubSubToBigQuery \ | |
| -Dexec.cleanupDaemonThreads=false \ | |
| -Dexec.args=" \ | |
| --project=XXXXXXX \ | |
| --stagingLocation=gs://GPS_NAME/staging \ | |
| --tempLocation=gs://GPS_NAME/tmp \ | |
| --templateLocation=gs://GPS_NAME/PubSubToBigQuery.json \ | |
| --runner=DataflowRunner \ | |
| --subnetwork=https://www.googleapis.com/compute/v1/projects/PROJECT_NAME/regions/us-east1/subnetworks/NETWORK_NAME \ | |
| --workerMachineType=n1-standard-1" |
This file contains hidden or 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
| gcloud dataflow jobs run skyhub-messages-monitor-$(date +'%Y%m%d-%H%M') \ | |
| --gcs-location=gs://GPS_NAME/PubSubToBigQuery.json \ | |
| --max-workers=1 \ | |
| --region=us-east1 \ | |
| --zone=us-east1-b \ | |
| --staging-location=gs://GPS_NAME/staging \ | |
| --parameters "inputTopic=projects/PROJECT_NAME/topics/PUBSUB_TOPIC,outputTableSpec=PROJECT_NAME:dataset_name.table_name" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment