-
Notifications
You must be signed in to change notification settings - Fork 59
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add support for pubsub for Dead Letter queue (#897)
* changes * change * linting * docs and tests * ui * changes * chages * change * changes
- Loading branch information
1 parent
07cff77
commit ae5535a
Showing
25 changed files
with
149 additions
and
48 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 |
---|---|---|
|
@@ -39,13 +39,14 @@ func TestMain(m *testing.M) { | |
|
||
func getParameters() map[string]string { | ||
return map[string]string{ | ||
"streamName": "my-stream", | ||
"instanceId": "my-instance", | ||
"databaseId": "my-dbName", | ||
"sessionFilePath": "gs://session.json", | ||
"deadLetterQueueDirectory": "gs://dlq", | ||
"transformationContextFilePath": "gs://transformationContext.json", | ||
"gcsPubSubSubscription": "projects/my-project/subscriptions/my-subscription", | ||
"streamName": "my-stream", | ||
"instanceId": "my-instance", | ||
"databaseId": "my-dbName", | ||
"sessionFilePath": "gs://session.json", | ||
"deadLetterQueueDirectory": "gs://dlq", | ||
"transformationContextFilePath": "gs://transformationContext.json", | ||
"dlqGcsPubSubSubscription": "projects/my-project/subscriptions/my-dlq-subscription", | ||
"gcsPubSubSubscription": "projects/my-project/subscriptions/my-subscription", | ||
} | ||
} | ||
|
||
|
@@ -105,6 +106,7 @@ func getExpectedGcloudCmd1() string { | |
"--dataflow-kms-key sample-kms-key --disable-public-ips " + | ||
"--enable-streaming-engine " + | ||
"--parameters databaseId=my-dbName,deadLetterQueueDirectory=gs://dlq," + | ||
"dlqGcsPubSubSubscription=projects/my-project/subscriptions/my-dlq-subscription," + | ||
"gcsPubSubSubscription=projects/my-project/subscriptions/my-subscription," + | ||
"instanceId=my-instance,sessionFilePath=gs://session.json,streamName=my-stream," + | ||
"transformationContextFilePath=gs://transformationContext.json" | ||
|
@@ -141,8 +143,8 @@ func getTemplateDfRequest2() *dataflowpb.LaunchFlexTemplateRequest { | |
} | ||
|
||
func getExpectedGcloudCmd2() string { | ||
return ""+ | ||
"gcloud dataflow flex-template run test-job " + | ||
return "" + | ||
"gcloud dataflow flex-template run test-job " + | ||
"--project=test-project --region=us-central1 " + | ||
"--template-file-gcs-location=gs://template/Cloud_Datastream_to_Spanner " + | ||
"--num-workers 10 --max-workers 50 --service-account-email [email protected] " + | ||
|
@@ -153,6 +155,7 @@ func getExpectedGcloudCmd2() string { | |
"--worker-zone test-worker-zone --enable-streaming-engine " + | ||
"--flexrs-goal FLEXRS_SPEED_OPTIMIZED --staging-location gs://staging-location " + | ||
"--parameters databaseId=my-dbName,deadLetterQueueDirectory=gs://dlq," + | ||
"dlqGcsPubSubSubscription=projects/my-project/subscriptions/my-dlq-subscription," + | ||
"gcsPubSubSubscription=projects/my-project/subscriptions/my-subscription," + | ||
"instanceId=my-instance,sessionFilePath=gs://session.json,streamName=my-stream," + | ||
"transformationContextFilePath=gs://transformationContext.json" | ||
|
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.