Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

feat(tasks): add support for stackdriver logging config; update retry config (via synth) #8

Merged
merged 1 commit into from Feb 21, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions google/cloud/tasks_v2/gapic/cloud_tasks_client_config.py
Expand Up @@ -59,7 +59,7 @@
},
"GetIamPolicy": {
"timeout_millis": 10000,
"retry_codes_name": "non_idempotent",
"retry_codes_name": "idempotent",
"retry_params_name": "default",
},
"SetIamPolicy": {
Expand All @@ -69,7 +69,7 @@
},
"TestIamPermissions": {
"timeout_millis": 10000,
"retry_codes_name": "non_idempotent",
"retry_codes_name": "idempotent",
"retry_params_name": "default",
},
"ListTasks": {
Expand All @@ -89,7 +89,7 @@
},
"DeleteTask": {
"timeout_millis": 10000,
"retry_codes_name": "non_idempotent",
"retry_codes_name": "idempotent",
"retry_params_name": "default",
},
"RunTask": {
Expand Down
15 changes: 15 additions & 0 deletions google/cloud/tasks_v2/proto/queue.proto
Expand Up @@ -166,6 +166,11 @@ message Queue {
// Purge time will be truncated to the nearest microsecond. Purge
// time will be unset if the queue has never been purged.
google.protobuf.Timestamp purge_time = 6;

// Configuration options for writing logs to
// [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
// field is unset, then no logs are written.
StackdriverLoggingConfig stackdriver_logging_config = 9;
}

// Rate limits.
Expand Down Expand Up @@ -344,3 +349,13 @@ message RetryConfig {
// queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
int32 max_doublings = 5;
}

// Configuration options for writing logs to
// [Stackdriver Logging](https://cloud.google.com/logging/docs/).
message StackdriverLoggingConfig {
// Specifies the fraction of operations to write to
// [Stackdriver Logging](https://cloud.google.com/logging/docs/).
// This field may contain any value between 0.0 and 1.0, inclusive.
// 0.0 is the default and means that no operations are logged.
double sampling_ratio = 1;
}
103 changes: 95 additions & 8 deletions google/cloud/tasks_v2/proto/queue_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions noxfile.py
Expand Up @@ -72,6 +72,7 @@ def default(session):
session.run(
"py.test",
"--quiet",
"--cov=google.cloud.cloudtasks",
"--cov=google.cloud",
"--cov=tests.unit",
"--cov-append",
Expand Down