diff --git a/.flake8 b/.flake8 index 20fe9bda..ed931638 100644 --- a/.flake8 +++ b/.flake8 @@ -21,6 +21,8 @@ exclude = # Exclude generated code. **/proto/** **/gapic/** + **/services/** + **/types/** *_pb2.py # Standard linting exemptions. diff --git a/.gitignore b/.gitignore index 3fb06e09..b87e1ed5 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,7 @@ dist build eggs +.eggs parts bin var @@ -49,6 +50,7 @@ bigquery/docs/generated # Virtual environment env/ coverage.xml +sponge_log.xml # System test environment variables. system_tests/local_test_setup diff --git a/.kokoro/publish-docs.sh b/.kokoro/publish-docs.sh index 384aa72b..c1d14db9 100755 --- a/.kokoro/publish-docs.sh +++ b/.kokoro/publish-docs.sh @@ -13,8 +13,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -#!/bin/bash - set -eo pipefail # Disable buffering, so that the logs stream through. diff --git a/.kokoro/release.sh b/.kokoro/release.sh index 48009503..37bf8d3a 100755 --- a/.kokoro/release.sh +++ b/.kokoro/release.sh @@ -13,8 +13,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -#!/bin/bash - set -eo pipefail # Start the releasetool reporter diff --git a/.kokoro/samples/lint/common.cfg b/.kokoro/samples/lint/common.cfg new file mode 100644 index 00000000..59e867da --- /dev/null +++ b/.kokoro/samples/lint/common.cfg @@ -0,0 +1,34 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Specify which tests to run +env_vars: { + key: "RUN_TESTS_SESSION" + value: "lint" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/python-scheduler/.kokoro/test-samples.sh" +} + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker" +} + +# Download secrets for samples +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples" + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "python-scheduler/.kokoro/trampoline.sh" \ No newline at end of file diff --git a/.kokoro/samples/lint/continuous.cfg b/.kokoro/samples/lint/continuous.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/lint/continuous.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/lint/periodic.cfg b/.kokoro/samples/lint/periodic.cfg new file mode 100644 index 00000000..50fec964 --- /dev/null +++ b/.kokoro/samples/lint/periodic.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "False" +} \ No newline at end of file diff --git a/.kokoro/samples/lint/presubmit.cfg b/.kokoro/samples/lint/presubmit.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/lint/presubmit.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.6/common.cfg b/.kokoro/samples/python3.6/common.cfg new file mode 100644 index 00000000..64c95ed8 --- /dev/null +++ b/.kokoro/samples/python3.6/common.cfg @@ -0,0 +1,34 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Specify which tests to run +env_vars: { + key: "RUN_TESTS_SESSION" + value: "py-3.6" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/python-scheduler/.kokoro/test-samples.sh" +} + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker" +} + +# Download secrets for samples +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples" + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "python-scheduler/.kokoro/trampoline.sh" \ No newline at end of file diff --git a/.kokoro/samples/python3.6/continuous.cfg b/.kokoro/samples/python3.6/continuous.cfg new file mode 100644 index 00000000..7218af14 --- /dev/null +++ b/.kokoro/samples/python3.6/continuous.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} + diff --git a/.kokoro/samples/python3.6/periodic.cfg b/.kokoro/samples/python3.6/periodic.cfg new file mode 100644 index 00000000..50fec964 --- /dev/null +++ b/.kokoro/samples/python3.6/periodic.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "False" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.6/presubmit.cfg b/.kokoro/samples/python3.6/presubmit.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.6/presubmit.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.7/common.cfg b/.kokoro/samples/python3.7/common.cfg new file mode 100644 index 00000000..c7005b25 --- /dev/null +++ b/.kokoro/samples/python3.7/common.cfg @@ -0,0 +1,34 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Specify which tests to run +env_vars: { + key: "RUN_TESTS_SESSION" + value: "py-3.7" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/python-scheduler/.kokoro/test-samples.sh" +} + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker" +} + +# Download secrets for samples +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples" + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "python-scheduler/.kokoro/trampoline.sh" \ No newline at end of file diff --git a/.kokoro/samples/python3.7/continuous.cfg b/.kokoro/samples/python3.7/continuous.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.7/continuous.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.7/periodic.cfg b/.kokoro/samples/python3.7/periodic.cfg new file mode 100644 index 00000000..50fec964 --- /dev/null +++ b/.kokoro/samples/python3.7/periodic.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "False" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.7/presubmit.cfg b/.kokoro/samples/python3.7/presubmit.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.7/presubmit.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.8/common.cfg b/.kokoro/samples/python3.8/common.cfg new file mode 100644 index 00000000..e77d7bbf --- /dev/null +++ b/.kokoro/samples/python3.8/common.cfg @@ -0,0 +1,34 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Specify which tests to run +env_vars: { + key: "RUN_TESTS_SESSION" + value: "py-3.8" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/python-scheduler/.kokoro/test-samples.sh" +} + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker" +} + +# Download secrets for samples +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples" + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "python-scheduler/.kokoro/trampoline.sh" \ No newline at end of file diff --git a/.kokoro/samples/python3.8/continuous.cfg b/.kokoro/samples/python3.8/continuous.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.8/continuous.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.8/periodic.cfg b/.kokoro/samples/python3.8/periodic.cfg new file mode 100644 index 00000000..50fec964 --- /dev/null +++ b/.kokoro/samples/python3.8/periodic.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "False" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.8/presubmit.cfg b/.kokoro/samples/python3.8/presubmit.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.8/presubmit.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/test-samples.sh b/.kokoro/test-samples.sh new file mode 100755 index 00000000..4749d612 --- /dev/null +++ b/.kokoro/test-samples.sh @@ -0,0 +1,104 @@ +#!/bin/bash +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + + +# `-e` enables the script to automatically fail when a command fails +# `-o pipefail` sets the exit code to the rightmost comment to exit with a non-zero +set -eo pipefail +# Enables `**` to include files nested inside sub-folders +shopt -s globstar + +cd github/python-scheduler + +# Run periodic samples tests at latest release +if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"periodic"* ]]; then + LATEST_RELEASE=$(git describe --abbrev=0 --tags) + git checkout $LATEST_RELEASE +fi + +# Disable buffering, so that the logs stream through. +export PYTHONUNBUFFERED=1 + +# Debug: show build environment +env | grep KOKORO + +# Install nox +python3.6 -m pip install --upgrade --quiet nox + +# Use secrets acessor service account to get secrets +if [[ -f "${KOKORO_GFILE_DIR}/secrets_viewer_service_account.json" ]]; then + gcloud auth activate-service-account \ + --key-file="${KOKORO_GFILE_DIR}/secrets_viewer_service_account.json" \ + --project="cloud-devrel-kokoro-resources" +fi + +# This script will create 3 files: +# - testing/test-env.sh +# - testing/service-account.json +# - testing/client-secrets.json +./scripts/decrypt-secrets.sh + +source ./testing/test-env.sh +export GOOGLE_APPLICATION_CREDENTIALS=$(pwd)/testing/service-account.json + +# For cloud-run session, we activate the service account for gcloud sdk. +gcloud auth activate-service-account \ + --key-file "${GOOGLE_APPLICATION_CREDENTIALS}" + +export GOOGLE_CLIENT_SECRETS=$(pwd)/testing/client-secrets.json + +echo -e "\n******************** TESTING PROJECTS ********************" + +# Switch to 'fail at end' to allow all tests to complete before exiting. +set +e +# Use RTN to return a non-zero value if the test fails. +RTN=0 +ROOT=$(pwd) +# Find all requirements.txt in the samples directory (may break on whitespace). +for file in samples/**/requirements.txt; do + cd "$ROOT" + # Navigate to the project folder. + file=$(dirname "$file") + cd "$file" + + echo "------------------------------------------------------------" + echo "- testing $file" + echo "------------------------------------------------------------" + + # Use nox to execute the tests for the project. + python3.6 -m nox -s "$RUN_TESTS_SESSION" + EXIT=$? + + # If this is a periodic build, send the test log to the Build Cop Bot. + # See https://github.com/googleapis/repo-automation-bots/tree/master/packages/buildcop. + if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"periodic"* ]]; then + chmod +x $KOKORO_GFILE_DIR/linux_amd64/buildcop + $KOKORO_GFILE_DIR/linux_amd64/buildcop + fi + + if [[ $EXIT -ne 0 ]]; then + RTN=1 + echo -e "\n Testing failed: Nox returned a non-zero exit code. \n" + else + echo -e "\n Testing completed.\n" + fi + +done +cd "$ROOT" + +# Workaround for Kokoro permissions issue: delete secrets +rm testing/{test-env.sh,client-secrets.json,service-account.json} + +exit "$RTN" \ No newline at end of file diff --git a/MANIFEST.in b/MANIFEST.in index 68855abc..e9e29d12 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -20,3 +20,6 @@ recursive-include google *.json *.proto recursive-include tests * global-exclude *.py[co] global-exclude __pycache__ + +# Exclude scripts for samples readmegen +prune scripts/readme-gen \ No newline at end of file diff --git a/docs/conf.py b/docs/conf.py index 8e0733f4..54308409 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -38,21 +38,18 @@ "sphinx.ext.napoleon", "sphinx.ext.todo", "sphinx.ext.viewcode", + "recommonmark", ] # autodoc/autosummary flags autoclass_content = "both" -autodoc_default_flags = ["members"] +autodoc_default_options = {"members": True} autosummary_generate = True # Add any paths that contain templates here, relative to this directory. templates_path = ["_templates"] -# Allow markdown includes (so releases.md can include CHANGLEOG.md) -# http://www.sphinx-doc.org/en/master/markdown.html -source_parsers = {".md": "recommonmark.parser.CommonMarkParser"} - # The suffix(es) of source filenames. # You can specify multiple suffix as a list of string: # source_suffix = ['.rst', '.md'] @@ -340,7 +337,7 @@ intersphinx_mapping = { "python": ("http://python.readthedocs.org/en/latest/", None), "google-auth": ("https://google-auth.readthedocs.io/en/stable", None), - "google.api_core": ("https://googleapis.dev/python/google-api-core/latest/", None), + "google.api_core": ("https://googleapis.dev/python/google-api-core/latest/", None,), "grpc": ("https://grpc.io/grpc/python/", None), } diff --git a/docs/index.rst b/docs/index.rst index 8b86e0b9..87317a2d 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,5 +1,7 @@ .. include:: README.rst +.. include:: multiprocessing.rst + This package includes clients for multiple versions of the Cloud Scheduler API. By default, you will get ``v1``, the latest stable version. diff --git a/docs/multiprocessing.rst b/docs/multiprocessing.rst new file mode 100644 index 00000000..1cb29d4c --- /dev/null +++ b/docs/multiprocessing.rst @@ -0,0 +1,7 @@ +.. note:: + + Because this client uses :mod:`grpcio` library, it is safe to + share instances across threads. In multiprocessing scenarios, the best + practice is to create client instances *after* the invocation of + :func:`os.fork` by :class:`multiprocessing.Pool` or + :class:`multiprocessing.Process`. diff --git a/google/cloud/scheduler.py b/google/cloud/scheduler.py index bfa82a79..b6c1c733 100644 --- a/google/cloud/scheduler.py +++ b/google/cloud/scheduler.py @@ -22,4 +22,8 @@ from google.cloud.scheduler_v1 import types -__all__ = ("enums", "types", "CloudSchedulerClient") +__all__ = ( + "enums", + "types", + "CloudSchedulerClient", +) diff --git a/google/cloud/scheduler_v1/__init__.py b/google/cloud/scheduler_v1/__init__.py index e8f1301b..a50e1f31 100644 --- a/google/cloud/scheduler_v1/__init__.py +++ b/google/cloud/scheduler_v1/__init__.py @@ -26,8 +26,8 @@ if sys.version_info[:2] == (2, 7): message = ( - "A future version of this library will drop support for Python 2.7." - "More details about Python 2 support for Google Cloud Client Libraries" + "A future version of this library will drop support for Python 2.7. " + "More details about Python 2 support for Google Cloud Client Libraries " "can be found at https://cloud.google.com/python/docs/python2-sunset/" ) warnings.warn(message, DeprecationWarning) @@ -38,4 +38,8 @@ class CloudSchedulerClient(cloud_scheduler_client.CloudSchedulerClient): enums = enums -__all__ = ("enums", "types", "CloudSchedulerClient") +__all__ = ( + "enums", + "types", + "CloudSchedulerClient", +) diff --git a/google/cloud/scheduler_v1/gapic/cloud_scheduler_client.py b/google/cloud/scheduler_v1/gapic/cloud_scheduler_client.py index b7eda181..ac9c52c4 100644 --- a/google/cloud/scheduler_v1/gapic/cloud_scheduler_client.py +++ b/google/cloud/scheduler_v1/gapic/cloud_scheduler_client.py @@ -42,7 +42,7 @@ _GAPIC_LIBRARY_VERSION = pkg_resources.get_distribution( - "google-cloud-scheduler" + "google-cloud-scheduler", ).version @@ -185,12 +185,12 @@ def __init__( self.transport = transport else: self.transport = cloud_scheduler_grpc_transport.CloudSchedulerGrpcTransport( - address=api_endpoint, channel=channel, credentials=credentials + address=api_endpoint, channel=channel, credentials=credentials, ) if client_info is None: client_info = google.api_core.gapic_v1.client_info.ClientInfo( - gapic_version=_GAPIC_LIBRARY_VERSION + gapic_version=_GAPIC_LIBRARY_VERSION, ) else: client_info.gapic_version = _GAPIC_LIBRARY_VERSION @@ -201,7 +201,7 @@ def __init__( # (Ordinarily, these are the defaults specified in the `*_config.py` # file next to this one.) self._method_configs = google.api_core.gapic_v1.config.parse_method_configs( - client_config["interfaces"][self._INTERFACE_NAME] + client_config["interfaces"][self._INTERFACE_NAME], ) # Save a dictionary of cached API call functions. @@ -284,7 +284,9 @@ def list_jobs( client_info=self._client_info, ) - request = cloudscheduler_pb2.ListJobsRequest(parent=parent, page_size=page_size) + request = cloudscheduler_pb2.ListJobsRequest( + parent=parent, page_size=page_size, + ) if metadata is None: metadata = [] metadata = list(metadata) @@ -365,7 +367,7 @@ def get_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.GetJobRequest(name=name) + request = cloudscheduler_pb2.GetJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -409,10 +411,10 @@ def create_job( Args: parent (str): Required. The location name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID``. - job (Union[dict, ~google.cloud.scheduler_v1.types.Job]): Required. The job to add. The user can optionally specify a name for the - job in ``name``. ``name`` cannot be the same as an existing job. If a - name is not specified then the system will generate a random unique name - that will be returned (``name``) in the response. + job (Union[dict, ~google.cloud.scheduler_v1.types.Job]): Required. The job to add. The user can optionally specify a name for + the job in ``name``. ``name`` cannot be the same as an existing job. If + a name is not specified then the system will generate a random unique + name that will be returned (``name``) in the response. If a dict is provided, it must be of the same form as the protobuf message :class:`~google.cloud.scheduler_v1.types.Job` @@ -446,7 +448,7 @@ def create_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.CreateJobRequest(parent=parent, job=job) + request = cloudscheduler_pb2.CreateJobRequest(parent=parent, job=job,) if metadata is None: metadata = [] metadata = list(metadata) @@ -538,7 +540,7 @@ def update_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.UpdateJobRequest(job=job, update_mask=update_mask) + request = cloudscheduler_pb2.UpdateJobRequest(job=job, update_mask=update_mask,) if metadata is None: metadata = [] metadata = list(metadata) @@ -605,7 +607,7 @@ def delete_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.DeleteJobRequest(name=name) + request = cloudscheduler_pb2.DeleteJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -680,7 +682,7 @@ def pause_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.PauseJobRequest(name=name) + request = cloudscheduler_pb2.PauseJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -755,7 +757,7 @@ def resume_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.ResumeJobRequest(name=name) + request = cloudscheduler_pb2.ResumeJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -828,7 +830,7 @@ def run_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.RunJobRequest(name=name) + request = cloudscheduler_pb2.RunJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) diff --git a/google/cloud/scheduler_v1/gapic/cloud_scheduler_client_config.py b/google/cloud/scheduler_v1/gapic/cloud_scheduler_client_config.py index da963b9d..0924941d 100644 --- a/google/cloud/scheduler_v1/gapic/cloud_scheduler_client_config.py +++ b/google/cloud/scheduler_v1/gapic/cloud_scheduler_client_config.py @@ -2,60 +2,79 @@ "interfaces": { "google.cloud.scheduler.v1.CloudScheduler": { "retry_codes": { - "idempotent": ["DEADLINE_EXCEEDED", "UNAVAILABLE"], - "non_idempotent": [], + "retry_policy_1_codes": ["DEADLINE_EXCEEDED", "UNAVAILABLE"], + "no_retry_codes": [], + "no_retry_1_codes": [], }, "retry_params": { - "default": { + "retry_policy_1_params": { "initial_retry_delay_millis": 100, "retry_delay_multiplier": 1.3, "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 20000, + "initial_rpc_timeout_millis": 600000, "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 20000, + "max_rpc_timeout_millis": 600000, "total_timeout_millis": 600000, - } + }, + "no_retry_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 0, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 0, + "total_timeout_millis": 0, + }, + "no_retry_1_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 600000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 600000, + "total_timeout_millis": 600000, + }, }, "methods": { "ListJobs": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "GetJob": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "CreateJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, "UpdateJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, "DeleteJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "PauseJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, "ResumeJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, "RunJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, }, } diff --git a/google/cloud/scheduler_v1/gapic/transports/cloud_scheduler_grpc_transport.py b/google/cloud/scheduler_v1/gapic/transports/cloud_scheduler_grpc_transport.py index 5b14b6c8..85df9939 100644 --- a/google/cloud/scheduler_v1/gapic/transports/cloud_scheduler_grpc_transport.py +++ b/google/cloud/scheduler_v1/gapic/transports/cloud_scheduler_grpc_transport.py @@ -56,7 +56,7 @@ def __init__( # exception (channels come with credentials baked in already). if channel is not None and credentials is not None: raise ValueError( - "The `channel` and `credentials` arguments are mutually " "exclusive." + "The `channel` and `credentials` arguments are mutually " "exclusive.", ) # Create the channel. @@ -75,7 +75,7 @@ def __init__( # gRPC uses objects called "stubs" that are bound to the # channel and provide a basic method for each RPC. self._stubs = { - "cloud_scheduler_stub": cloudscheduler_pb2_grpc.CloudSchedulerStub(channel) + "cloud_scheduler_stub": cloudscheduler_pb2_grpc.CloudSchedulerStub(channel), } @classmethod diff --git a/google/cloud/scheduler_v1/proto/cloudscheduler_pb2.py b/google/cloud/scheduler_v1/proto/cloudscheduler_pb2.py index b604f9ce..c417b7e7 100644 --- a/google/cloud/scheduler_v1/proto/cloudscheduler_pb2.py +++ b/google/cloud/scheduler_v1/proto/cloudscheduler_pb2.py @@ -2,9 +2,6 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/scheduler_v1/proto/cloudscheduler.proto -import sys - -_b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection @@ -30,12 +27,9 @@ name="google/cloud/scheduler_v1/proto/cloudscheduler.proto", package="google.cloud.scheduler.v1", syntax="proto3", - serialized_options=_b( - "\n\035com.google.cloud.scheduler.v1B\016SchedulerProtoP\001ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\242\002\tSCHEDULER" - ), - serialized_pb=_b( - '\n4google/cloud/scheduler_v1/proto/cloudscheduler.proto\x12\x19google.cloud.scheduler.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a)google/cloud/scheduler_v1/proto/job.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto"s\n\x0fListJobsRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x11\n\tpage_size\x18\x05 \x01(\x05\x12\x12\n\npage_token\x18\x06 \x01(\t"Y\n\x10ListJobsResponse\x12,\n\x04jobs\x18\x01 \x03(\x0b\x32\x1e.google.cloud.scheduler.v1.Job\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t"H\n\rGetJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"\x7f\n\x10\x43reateJobRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x30\n\x03job\x18\x02 \x01(\x0b\x32\x1e.google.cloud.scheduler.v1.JobB\x03\xe0\x41\x02"z\n\x10UpdateJobRequest\x12\x30\n\x03job\x18\x01 \x01(\x0b\x32\x1e.google.cloud.scheduler.v1.JobB\x03\xe0\x41\x02\x12\x34\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02"K\n\x10\x44\x65leteJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"J\n\x0fPauseJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"K\n\x10ResumeJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"H\n\rRunJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job2\xb3\n\n\x0e\x43loudScheduler\x12\x9e\x01\n\x08ListJobs\x12*.google.cloud.scheduler.v1.ListJobsRequest\x1a+.google.cloud.scheduler.v1.ListJobsResponse"9\x82\xd3\xe4\x93\x02*\x12(/v1/{parent=projects/*/locations/*}/jobs\xda\x41\x06parent\x12\x8b\x01\n\x06GetJob\x12(.google.cloud.scheduler.v1.GetJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"7\x82\xd3\xe4\x93\x02*\x12(/v1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\x9c\x01\n\tCreateJob\x12+.google.cloud.scheduler.v1.CreateJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"B\x82\xd3\xe4\x93\x02/"(/v1/{parent=projects/*/locations/*}/jobs:\x03job\xda\x41\nparent,job\x12\xa5\x01\n\tUpdateJob\x12+.google.cloud.scheduler.v1.UpdateJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"K\x82\xd3\xe4\x93\x02\x33\x32,/v1/{job.name=projects/*/locations/*/jobs/*}:\x03job\xda\x41\x0fjob,update_mask\x12\x89\x01\n\tDeleteJob\x12+.google.cloud.scheduler.v1.DeleteJobRequest\x1a\x16.google.protobuf.Empty"7\x82\xd3\xe4\x93\x02**(/v1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\x98\x01\n\x08PauseJob\x12*.google.cloud.scheduler.v1.PauseJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"@\x82\xd3\xe4\x93\x02\x33"./v1/{name=projects/*/locations/*/jobs/*}:pause:\x01*\xda\x41\x04name\x12\x9b\x01\n\tResumeJob\x12+.google.cloud.scheduler.v1.ResumeJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"A\x82\xd3\xe4\x93\x02\x34"//v1/{name=projects/*/locations/*/jobs/*}:resume:\x01*\xda\x41\x04name\x12\x92\x01\n\x06RunJob\x12(.google.cloud.scheduler.v1.RunJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job">\x82\xd3\xe4\x93\x02\x31",/v1/{name=projects/*/locations/*/jobs/*}:run:\x01*\xda\x41\x04name\x1aQ\xca\x41\x1d\x63loudscheduler.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\x81\x01\n\x1d\x63om.google.cloud.scheduler.v1B\x0eSchedulerProtoP\x01ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\xa2\x02\tSCHEDULERb\x06proto3' - ), + serialized_options=b"\n\035com.google.cloud.scheduler.v1B\016SchedulerProtoP\001ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\242\002\tSCHEDULER", + create_key=_descriptor._internal_create_key, + serialized_pb=b'\n4google/cloud/scheduler_v1/proto/cloudscheduler.proto\x12\x19google.cloud.scheduler.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a)google/cloud/scheduler_v1/proto/job.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto"s\n\x0fListJobsRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x11\n\tpage_size\x18\x05 \x01(\x05\x12\x12\n\npage_token\x18\x06 \x01(\t"Y\n\x10ListJobsResponse\x12,\n\x04jobs\x18\x01 \x03(\x0b\x32\x1e.google.cloud.scheduler.v1.Job\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t"H\n\rGetJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"\x7f\n\x10\x43reateJobRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x30\n\x03job\x18\x02 \x01(\x0b\x32\x1e.google.cloud.scheduler.v1.JobB\x03\xe0\x41\x02"z\n\x10UpdateJobRequest\x12\x30\n\x03job\x18\x01 \x01(\x0b\x32\x1e.google.cloud.scheduler.v1.JobB\x03\xe0\x41\x02\x12\x34\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02"K\n\x10\x44\x65leteJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"J\n\x0fPauseJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"K\n\x10ResumeJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"H\n\rRunJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job2\xb3\n\n\x0e\x43loudScheduler\x12\x9e\x01\n\x08ListJobs\x12*.google.cloud.scheduler.v1.ListJobsRequest\x1a+.google.cloud.scheduler.v1.ListJobsResponse"9\x82\xd3\xe4\x93\x02*\x12(/v1/{parent=projects/*/locations/*}/jobs\xda\x41\x06parent\x12\x8b\x01\n\x06GetJob\x12(.google.cloud.scheduler.v1.GetJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"7\x82\xd3\xe4\x93\x02*\x12(/v1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\x9c\x01\n\tCreateJob\x12+.google.cloud.scheduler.v1.CreateJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"B\x82\xd3\xe4\x93\x02/"(/v1/{parent=projects/*/locations/*}/jobs:\x03job\xda\x41\nparent,job\x12\xa5\x01\n\tUpdateJob\x12+.google.cloud.scheduler.v1.UpdateJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"K\x82\xd3\xe4\x93\x02\x33\x32,/v1/{job.name=projects/*/locations/*/jobs/*}:\x03job\xda\x41\x0fjob,update_mask\x12\x89\x01\n\tDeleteJob\x12+.google.cloud.scheduler.v1.DeleteJobRequest\x1a\x16.google.protobuf.Empty"7\x82\xd3\xe4\x93\x02**(/v1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\x98\x01\n\x08PauseJob\x12*.google.cloud.scheduler.v1.PauseJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"@\x82\xd3\xe4\x93\x02\x33"./v1/{name=projects/*/locations/*/jobs/*}:pause:\x01*\xda\x41\x04name\x12\x9b\x01\n\tResumeJob\x12+.google.cloud.scheduler.v1.ResumeJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job"A\x82\xd3\xe4\x93\x02\x34"//v1/{name=projects/*/locations/*/jobs/*}:resume:\x01*\xda\x41\x04name\x12\x92\x01\n\x06RunJob\x12(.google.cloud.scheduler.v1.RunJobRequest\x1a\x1e.google.cloud.scheduler.v1.Job">\x82\xd3\xe4\x93\x02\x31",/v1/{name=projects/*/locations/*/jobs/*}:run:\x01*\xda\x41\x04name\x1aQ\xca\x41\x1d\x63loudscheduler.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\x81\x01\n\x1d\x63om.google.cloud.scheduler.v1B\x0eSchedulerProtoP\x01ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\xa2\x02\tSCHEDULERb\x06proto3', dependencies=[ google_dot_api_dot_annotations__pb2.DESCRIPTOR, google_dot_api_dot_client__pb2.DESCRIPTOR, @@ -54,6 +48,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="parent", @@ -64,16 +59,15 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\022!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\022!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="page_size", @@ -92,6 +86,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="page_token", @@ -102,7 +97,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -110,6 +105,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -131,6 +127,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="jobs", @@ -149,6 +146,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="next_page_token", @@ -159,7 +157,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -167,6 +165,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -188,6 +187,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -198,17 +198,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -229,6 +228,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="parent", @@ -239,16 +239,15 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\022!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\022!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="job", @@ -265,8 +264,9 @@ containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\340A\002"), + serialized_options=b"\340A\002", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -288,6 +288,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="job", @@ -304,8 +305,9 @@ containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\340A\002"), + serialized_options=b"\340A\002", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="update_mask", @@ -322,8 +324,9 @@ containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\340A\002"), + serialized_options=b"\340A\002", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -345,6 +348,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -355,17 +359,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -386,6 +389,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -396,17 +400,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -427,6 +430,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -437,17 +441,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -468,6 +471,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -478,17 +482,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -528,11 +531,12 @@ ListJobsRequest = _reflection.GeneratedProtocolMessageType( "ListJobsRequest", (_message.Message,), - dict( - DESCRIPTOR=_LISTJOBSREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for listing jobs using + { + "DESCRIPTOR": _LISTJOBSREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for listing jobs using [ListJobs][google.cloud.scheduler.v1.CloudScheduler.ListJobs]. + Attributes: parent: Required. The location name. For example: @@ -541,76 +545,78 @@ Requested page size. The maximum page size is 500. If unspecified, the page size will be the maximum. Fewer jobs than requested might be returned, even if more jobs exist; use - next\_page\_token to determine if more jobs exist. + next_page_token to determine if more jobs exist. page_token: A token identifying a page of results the server will return. - To request the first page results, page\_token must be empty. - To request the next page of results, page\_token must be the - value of [next\_page\_token][google.cloud.scheduler.v1.ListJob - sResponse.next\_page\_token] returned from the previous call - to + To request the first page results, page_token must be empty. + To request the next page of results, page_token must be the + value of [next_page_token][google.cloud.scheduler.v1.ListJobsR + esponse.next_page_token] returned from the previous call to [ListJobs][google.cloud.scheduler.v1.CloudScheduler.ListJobs]. It is an error to switch the value of - [filter][google.cloud.scheduler.v1.ListJobsRequest.filter] or - [order\_by][google.cloud.scheduler.v1.ListJobsRequest.order\_b - y] while iterating through pages. + [filter][google.cloud.scheduler.v1.ListJobsRequest.filter] or + [order_by][google.cloud.scheduler.v1.ListJobsRequest.order_by] + while iterating through pages. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.ListJobsRequest) - ), + }, ) _sym_db.RegisterMessage(ListJobsRequest) ListJobsResponse = _reflection.GeneratedProtocolMessageType( "ListJobsResponse", (_message.Message,), - dict( - DESCRIPTOR=_LISTJOBSRESPONSE, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Response message for listing jobs using + { + "DESCRIPTOR": _LISTJOBSRESPONSE, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Response message for listing jobs using [ListJobs][google.cloud.scheduler.v1.CloudScheduler.ListJobs]. + Attributes: jobs: The list of jobs. next_page_token: A token to retrieve next page of results. Pass this value in - the [page\_token][google.cloud.scheduler.v1.ListJobsRequest.pa - ge\_token] field in the subsequent call to + the [page_token][google.cloud.scheduler.v1.ListJobsRequest.pag + e_token] field in the subsequent call to [ListJobs][google.cloud.scheduler.v1.CloudScheduler.ListJobs] to retrieve the next page of results. If this is empty it indicates that there are no more results through which to paginate. The page token is valid for only 2 hours. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.ListJobsResponse) - ), + }, ) _sym_db.RegisterMessage(ListJobsResponse) GetJobRequest = _reflection.GeneratedProtocolMessageType( "GetJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_GETJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _GETJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [GetJob][google.cloud.scheduler.v1.CloudScheduler.GetJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.GetJobRequest) - ), + }, ) _sym_db.RegisterMessage(GetJobRequest) CreateJobRequest = _reflection.GeneratedProtocolMessageType( "CreateJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_CREATEJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _CREATEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [CreateJob][google.cloud.scheduler.v1.CloudScheduler.CreateJob]. + Attributes: parent: Required. The location name. For example: @@ -625,18 +631,19 @@ ([name][google.cloud.scheduler.v1.Job.name]) in the response. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.CreateJobRequest) - ), + }, ) _sym_db.RegisterMessage(CreateJobRequest) UpdateJobRequest = _reflection.GeneratedProtocolMessageType( "UpdateJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_UPDATEJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _UPDATEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [UpdateJob][google.cloud.scheduler.v1.CloudScheduler.UpdateJob]. + Attributes: job: Required. The new job properties. @@ -648,79 +655,83 @@ updated. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.UpdateJobRequest) - ), + }, ) _sym_db.RegisterMessage(UpdateJobRequest) DeleteJobRequest = _reflection.GeneratedProtocolMessageType( "DeleteJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_DELETEJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for deleting a job using + { + "DESCRIPTOR": _DELETEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for deleting a job using [DeleteJob][google.cloud.scheduler.v1.CloudScheduler.DeleteJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.DeleteJobRequest) - ), + }, ) _sym_db.RegisterMessage(DeleteJobRequest) PauseJobRequest = _reflection.GeneratedProtocolMessageType( "PauseJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_PAUSEJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _PAUSEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [PauseJob][google.cloud.scheduler.v1.CloudScheduler.PauseJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.PauseJobRequest) - ), + }, ) _sym_db.RegisterMessage(PauseJobRequest) ResumeJobRequest = _reflection.GeneratedProtocolMessageType( "ResumeJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_RESUMEJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _RESUMEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [ResumeJob][google.cloud.scheduler.v1.CloudScheduler.ResumeJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.ResumeJobRequest) - ), + }, ) _sym_db.RegisterMessage(ResumeJobRequest) RunJobRequest = _reflection.GeneratedProtocolMessageType( "RunJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_RUNJOBREQUEST, - __module__="google.cloud.scheduler_v1.proto.cloudscheduler_pb2", - __doc__="""Request message for forcing a job to run now using + { + "DESCRIPTOR": _RUNJOBREQUEST, + "__module__": "google.cloud.scheduler_v1.proto.cloudscheduler_pb2", + "__doc__": """Request message for forcing a job to run now using [RunJob][google.cloud.scheduler.v1.CloudScheduler.RunJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.RunJobRequest) - ), + }, ) _sym_db.RegisterMessage(RunJobRequest) @@ -742,9 +753,8 @@ full_name="google.cloud.scheduler.v1.CloudScheduler", file=DESCRIPTOR, index=0, - serialized_options=_b( - "\312A\035cloudscheduler.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platform" - ), + serialized_options=b"\312A\035cloudscheduler.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platform", + create_key=_descriptor._internal_create_key, serialized_start=1144, serialized_end=2475, methods=[ @@ -755,9 +765,8 @@ containing_service=None, input_type=_LISTJOBSREQUEST, output_type=_LISTJOBSRESPONSE, - serialized_options=_b( - "\202\323\344\223\002*\022(/v1/{parent=projects/*/locations/*}/jobs\332A\006parent" - ), + serialized_options=b"\202\323\344\223\002*\022(/v1/{parent=projects/*/locations/*}/jobs\332A\006parent", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="GetJob", @@ -766,9 +775,8 @@ containing_service=None, input_type=_GETJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - "\202\323\344\223\002*\022(/v1/{name=projects/*/locations/*/jobs/*}\332A\004name" - ), + serialized_options=b"\202\323\344\223\002*\022(/v1/{name=projects/*/locations/*/jobs/*}\332A\004name", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="CreateJob", @@ -777,9 +785,8 @@ containing_service=None, input_type=_CREATEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\002/"(/v1/{parent=projects/*/locations/*}/jobs:\003job\332A\nparent,job' - ), + serialized_options=b'\202\323\344\223\002/"(/v1/{parent=projects/*/locations/*}/jobs:\003job\332A\nparent,job', + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="UpdateJob", @@ -788,9 +795,8 @@ containing_service=None, input_type=_UPDATEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - "\202\323\344\223\00232,/v1/{job.name=projects/*/locations/*/jobs/*}:\003job\332A\017job,update_mask" - ), + serialized_options=b"\202\323\344\223\00232,/v1/{job.name=projects/*/locations/*/jobs/*}:\003job\332A\017job,update_mask", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="DeleteJob", @@ -799,9 +805,8 @@ containing_service=None, input_type=_DELETEJOBREQUEST, output_type=google_dot_protobuf_dot_empty__pb2._EMPTY, - serialized_options=_b( - "\202\323\344\223\002**(/v1/{name=projects/*/locations/*/jobs/*}\332A\004name" - ), + serialized_options=b"\202\323\344\223\002**(/v1/{name=projects/*/locations/*/jobs/*}\332A\004name", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="PauseJob", @@ -810,9 +815,8 @@ containing_service=None, input_type=_PAUSEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0023"./v1/{name=projects/*/locations/*/jobs/*}:pause:\001*\332A\004name' - ), + serialized_options=b'\202\323\344\223\0023"./v1/{name=projects/*/locations/*/jobs/*}:pause:\001*\332A\004name', + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="ResumeJob", @@ -821,9 +825,8 @@ containing_service=None, input_type=_RESUMEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0024"//v1/{name=projects/*/locations/*/jobs/*}:resume:\001*\332A\004name' - ), + serialized_options=b'\202\323\344\223\0024"//v1/{name=projects/*/locations/*/jobs/*}:resume:\001*\332A\004name', + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="RunJob", @@ -832,9 +835,8 @@ containing_service=None, input_type=_RUNJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0021",/v1/{name=projects/*/locations/*/jobs/*}:run:\001*\332A\004name' - ), + serialized_options=b'\202\323\344\223\0021",/v1/{name=projects/*/locations/*/jobs/*}:run:\001*\332A\004name', + create_key=_descriptor._internal_create_key, ), ], ) diff --git a/google/cloud/scheduler_v1/proto/job_pb2.py b/google/cloud/scheduler_v1/proto/job_pb2.py index 55d509c0..83051639 100644 --- a/google/cloud/scheduler_v1/proto/job_pb2.py +++ b/google/cloud/scheduler_v1/proto/job_pb2.py @@ -2,9 +2,6 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/scheduler_v1/proto/job.proto -import sys - -_b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection @@ -29,12 +26,9 @@ name="google/cloud/scheduler_v1/proto/job.proto", package="google.cloud.scheduler.v1", syntax="proto3", - serialized_options=_b( - "\n\035com.google.cloud.scheduler.v1B\010JobProtoP\001ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler" - ), - serialized_pb=_b( - '\n)google/cloud/scheduler_v1/proto/job.proto\x12\x19google.cloud.scheduler.v1\x1a\x19google/api/resource.proto\x1a,google/cloud/scheduler_v1/proto/target.proto\x1a\x1egoogle/protobuf/duration.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17google/rpc/status.proto\x1a\x1cgoogle/api/annotations.proto"\xcb\x06\n\x03Job\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x02 \x01(\t\x12@\n\rpubsub_target\x18\x04 \x01(\x0b\x32\'.google.cloud.scheduler.v1.PubsubTargetH\x00\x12P\n\x16\x61pp_engine_http_target\x18\x05 \x01(\x0b\x32..google.cloud.scheduler.v1.AppEngineHttpTargetH\x00\x12<\n\x0bhttp_target\x18\x06 \x01(\x0b\x32%.google.cloud.scheduler.v1.HttpTargetH\x00\x12\x10\n\x08schedule\x18\x14 \x01(\t\x12\x11\n\ttime_zone\x18\x15 \x01(\t\x12\x34\n\x10user_update_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x33\n\x05state\x18\n \x01(\x0e\x32$.google.cloud.scheduler.v1.Job.State\x12"\n\x06status\x18\x0b \x01(\x0b\x32\x12.google.rpc.Status\x12\x31\n\rschedule_time\x18\x11 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x35\n\x11last_attempt_time\x18\x12 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12<\n\x0cretry_config\x18\x13 \x01(\x0b\x32&.google.cloud.scheduler.v1.RetryConfig\x12\x33\n\x10\x61ttempt_deadline\x18\x16 \x01(\x0b\x32\x19.google.protobuf.Duration"X\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x0b\n\x07\x45NABLED\x10\x01\x12\n\n\x06PAUSED\x10\x02\x12\x0c\n\x08\x44ISABLED\x10\x03\x12\x11\n\rUPDATE_FAILED\x10\x04:Z\xea\x41W\n!cloudscheduler.googleapis.com/Job\x12\x32projects/{project}/locations/{location}/jobs/{job}B\x08\n\x06target"\xe2\x01\n\x0bRetryConfig\x12\x13\n\x0bretry_count\x18\x01 \x01(\x05\x12\x35\n\x12max_retry_duration\x18\x02 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14min_backoff_duration\x18\x03 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14max_backoff_duration\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x15\n\rmax_doublings\x18\x05 \x01(\x05\x42o\n\x1d\x63om.google.cloud.scheduler.v1B\x08JobProtoP\x01ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;schedulerb\x06proto3' - ), + serialized_options=b"\n\035com.google.cloud.scheduler.v1B\010JobProtoP\001ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler", + create_key=_descriptor._internal_create_key, + serialized_pb=b'\n)google/cloud/scheduler_v1/proto/job.proto\x12\x19google.cloud.scheduler.v1\x1a\x19google/api/resource.proto\x1a,google/cloud/scheduler_v1/proto/target.proto\x1a\x1egoogle/protobuf/duration.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17google/rpc/status.proto\x1a\x1cgoogle/api/annotations.proto"\xcb\x06\n\x03Job\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x02 \x01(\t\x12@\n\rpubsub_target\x18\x04 \x01(\x0b\x32\'.google.cloud.scheduler.v1.PubsubTargetH\x00\x12P\n\x16\x61pp_engine_http_target\x18\x05 \x01(\x0b\x32..google.cloud.scheduler.v1.AppEngineHttpTargetH\x00\x12<\n\x0bhttp_target\x18\x06 \x01(\x0b\x32%.google.cloud.scheduler.v1.HttpTargetH\x00\x12\x10\n\x08schedule\x18\x14 \x01(\t\x12\x11\n\ttime_zone\x18\x15 \x01(\t\x12\x34\n\x10user_update_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x33\n\x05state\x18\n \x01(\x0e\x32$.google.cloud.scheduler.v1.Job.State\x12"\n\x06status\x18\x0b \x01(\x0b\x32\x12.google.rpc.Status\x12\x31\n\rschedule_time\x18\x11 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x35\n\x11last_attempt_time\x18\x12 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12<\n\x0cretry_config\x18\x13 \x01(\x0b\x32&.google.cloud.scheduler.v1.RetryConfig\x12\x33\n\x10\x61ttempt_deadline\x18\x16 \x01(\x0b\x32\x19.google.protobuf.Duration"X\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x0b\n\x07\x45NABLED\x10\x01\x12\n\n\x06PAUSED\x10\x02\x12\x0c\n\x08\x44ISABLED\x10\x03\x12\x11\n\rUPDATE_FAILED\x10\x04:Z\xea\x41W\n!cloudscheduler.googleapis.com/Job\x12\x32projects/{project}/locations/{location}/jobs/{job}B\x08\n\x06target"\xe2\x01\n\x0bRetryConfig\x12\x13\n\x0bretry_count\x18\x01 \x01(\x05\x12\x35\n\x12max_retry_duration\x18\x02 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14min_backoff_duration\x18\x03 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14max_backoff_duration\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x15\n\rmax_doublings\x18\x05 \x01(\x05\x42o\n\x1d\x63om.google.cloud.scheduler.v1B\x08JobProtoP\x01ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;schedulerb\x06proto3', dependencies=[ google_dot_api_dot_resource__pb2.DESCRIPTOR, google_dot_cloud_dot_scheduler__v1_dot_proto_dot_target__pb2.DESCRIPTOR, @@ -51,6 +45,7 @@ full_name="google.cloud.scheduler.v1.Job.State", filename=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, values=[ _descriptor.EnumValueDescriptor( name="STATE_UNSPECIFIED", @@ -58,18 +53,39 @@ number=0, serialized_options=None, type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="ENABLED", index=1, number=1, serialized_options=None, type=None + name="ENABLED", + index=1, + number=1, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="PAUSED", index=2, number=2, serialized_options=None, type=None + name="PAUSED", + index=2, + number=2, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="DISABLED", index=3, number=3, serialized_options=None, type=None + name="DISABLED", + index=3, + number=3, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="UPDATE_FAILED", index=4, number=4, serialized_options=None, type=None + name="UPDATE_FAILED", + index=4, + number=4, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), ], containing_type=None, @@ -86,6 +102,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -96,7 +113,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -104,6 +121,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="description", @@ -114,7 +132,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -122,6 +140,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="pubsub_target", @@ -140,6 +159,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="app_engine_http_target", @@ -158,6 +178,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="http_target", @@ -176,6 +197,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="schedule", @@ -186,7 +208,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -194,6 +216,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="time_zone", @@ -204,7 +227,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -212,6 +235,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="user_update_time", @@ -230,6 +254,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="state", @@ -248,6 +273,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="status", @@ -266,6 +292,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="schedule_time", @@ -284,6 +311,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="last_attempt_time", @@ -302,6 +330,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="retry_config", @@ -320,6 +349,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="attempt_deadline", @@ -338,14 +368,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], - enum_types=[_JOB_STATE], - serialized_options=_b( - "\352AW\n!cloudscheduler.googleapis.com/Job\0222projects/{project}/locations/{location}/jobs/{job}" - ), + enum_types=[_JOB_STATE,], + serialized_options=b"\352AW\n!cloudscheduler.googleapis.com/Job\0222projects/{project}/locations/{location}/jobs/{job}", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -355,8 +384,9 @@ full_name="google.cloud.scheduler.v1.Job.target", index=0, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[], - ) + ), ], serialized_start=266, serialized_end=1109, @@ -369,6 +399,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="retry_count", @@ -387,6 +418,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="max_retry_duration", @@ -405,6 +437,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="min_backoff_duration", @@ -423,6 +456,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="max_backoff_duration", @@ -441,6 +475,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="max_doublings", @@ -459,6 +494,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -530,10 +566,11 @@ Job = _reflection.GeneratedProtocolMessageType( "Job", (_message.Message,), - dict( - DESCRIPTOR=_JOB, - __module__="google.cloud.scheduler_v1.proto.job_pb2", - __doc__="""Configuration for a job. The maximum allowed size for a job is 100KB. + { + "DESCRIPTOR": _JOB, + "__module__": "google.cloud.scheduler_v1.proto.job_pb2", + "__doc__": """Configuration for a job. The maximum allowed size for a job is 100KB. + Attributes: name: Optionally caller-specified in [CreateJob][google.cloud.schedu @@ -545,13 +582,13 @@ information, see `Identifying projects `__ - ``LOCATION_ID`` - is the canonical ID for the job's location. The list of + is the canonical ID for the job’s location. The list of available locations can be obtained by calling [ListLocatio ns][google.cloud.location.Locations.ListLocations]. For more information, see https://cloud.google.com/about/locations/. - ``JOB_ID`` can contain only letters ([A-Za-z]), numbers ([0-9]), hyphens - (-), or underscores (\_). The maximum length is 500 + (-), or underscores (_). The maximum length is 500 characters. description: Optionally caller-specified in [CreateJob][google.cloud.schedu @@ -584,10 +621,10 @@ execution takes until 16:15, the ``n+1``\ th execution will not start until ``16:15``. A scheduled start time will be delayed if the previous execution has not ended when its - scheduled time occurs. If [retry\_count][google.cloud.schedul - er.v1.RetryConfig.retry\_count] > 0 and a job attempt fails, - the job will be tried a total of [retry\_count][google.cloud.s - cheduler.v1.RetryConfig.retry\_count] times, with exponential + scheduled time occurs. If [retry_count][google.cloud.schedule + r.v1.RetryConfig.retry_count] > 0 and a job attempt fails, the + job will be tried a total of [retry_count][google.cloud.schedu + ler.v1.RetryConfig.retry_count] times, with exponential backoff, until the next scheduled start time. time_zone: Specifies the time zone to be used in interpreting @@ -596,7 +633,7 @@ `__. Note that some time zones include a provision for daylight savings time. The rules for daylight saving time are determined by the chosen - tz. For UTC use the string "utc". If a time zone is not + tz. For UTC use the string “utc”. If a time zone is not specified, the default will be in UTC (also known as GMT). user_update_time: Output only. The creation time of the job. @@ -621,46 +658,47 @@ Scheduler will retry the job according to the [RetryConfig][google.cloud.scheduler.v1.RetryConfig]. The allowed duration for this deadline is: \* For [HTTP - targets][google.cloud.scheduler.v1.Job.http\_target], between + targets][google.cloud.scheduler.v1.Job.http_target], between 15 seconds and 30 minutes. \* For [App Engine HTTP targets][go - ogle.cloud.scheduler.v1.Job.app\_engine\_http\_target], - between 15 seconds and 24 hours. + ogle.cloud.scheduler.v1.Job.app_engine_http_target], between + 15 seconds and 24 hours. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.Job) - ), + }, ) _sym_db.RegisterMessage(Job) RetryConfig = _reflection.GeneratedProtocolMessageType( "RetryConfig", (_message.Message,), - dict( - DESCRIPTOR=_RETRYCONFIG, - __module__="google.cloud.scheduler_v1.proto.job_pb2", - __doc__="""Settings that determine the retry behavior. By default, if a job does + { + "DESCRIPTOR": _RETRYCONFIG, + "__module__": "google.cloud.scheduler_v1.proto.job_pb2", + "__doc__": """Settings that determine the retry behavior. By default, if a job does not complete successfully (meaning that an acknowledgement is not received from the handler, then it will be retried with exponential backoff according to the settings in [RetryConfig][google.cloud.scheduler.v1.RetryConfig]. + Attributes: retry_count: The number of attempts that the system will make to run a job - using the exponential backoff procedure described by [max\_dou - blings][google.cloud.scheduler.v1.RetryConfig.max\_doublings]. - The default value of retry\_count is zero. If retry\_count is + using the exponential backoff procedure described by [max_doub + lings][google.cloud.scheduler.v1.RetryConfig.max_doublings]. + The default value of retry_count is zero. If retry_count is zero, a job attempt will *not* be retried if it fails. Instead the Cloud Scheduler system will wait for the next scheduled - execution time. If retry\_count is set to a non-zero number + execution time. If retry_count is set to a non-zero number then Cloud Scheduler will retry failed attempts, using - exponential backoff, retry\_count times, or until the next + exponential backoff, retry_count times, or until the next scheduled execution time, whichever comes first. Values greater than 5 and negative values are not allowed. max_retry_duration: The time limit for retrying a failed job, measured from time when an execution was first attempted. If specified with [retr - y\_count][google.cloud.scheduler.v1.RetryConfig.retry\_count], + y_count][google.cloud.scheduler.v1.RetryConfig.retry_count], the job will be retried until both limits are reached. The - default value for max\_retry\_duration is zero, which means + default value for max_retry_duration is zero, which means retry duration is unlimited. min_backoff_duration: The minimum amount of time to wait before retrying a job after @@ -670,28 +708,27 @@ it fails. The default value of this field is 1 hour. max_doublings: The time between retries will double ``max_doublings`` times. - A job's retry interval starts at [min\_backoff\_duration][goog - le.cloud.scheduler.v1.RetryConfig.min\_backoff\_duration], - then doubles ``max_doublings`` times, then increases linearly, - and finally retries retries at intervals of [max\_backoff\_dur - ation][google.cloud.scheduler.v1.RetryConfig.max\_backoff\_dur - ation] up to [retry\_count][google.cloud.scheduler.v1.RetryCon - fig.retry\_count] times. For example, if [min\_backoff\_durat - ion][google.cloud.scheduler.v1.RetryConfig.min\_backoff\_durat - ion] is 10s, [max\_backoff\_duration][google.cloud.scheduler.v - 1.RetryConfig.max\_backoff\_duration] is 300s, and - ``max_doublings`` is 3, then the a job will first be retried - in 10s. The retry interval will double three times, and then - increase linearly by 2^3 \* 10s. Finally, the job will retry - at intervals of [max\_backoff\_duration][google.cloud.schedule - r.v1.RetryConfig.max\_backoff\_duration] until the job has - been attempted [retry\_count][google.cloud.scheduler.v1.RetryC - onfig.retry\_count] times. Thus, the requests will retry at - 10s, 20s, 40s, 80s, 160s, 240s, 300s, 300s, .... The default - value of this field is 5. + A job’s retry interval starts at [min_backoff_duration][google + .cloud.scheduler.v1.RetryConfig.min_backoff_duration], then + doubles ``max_doublings`` times, then increases linearly, and + finally retries retries at intervals of [max_backoff_duration] + [google.cloud.scheduler.v1.RetryConfig.max_backoff_duration] + up to [retry_count][google.cloud.scheduler.v1.RetryConfig.retr + y_count] times. For example, if [min_backoff_duration][google + .cloud.scheduler.v1.RetryConfig.min_backoff_duration] is 10s, + [max_backoff_duration][google.cloud.scheduler.v1.RetryConfig.m + ax_backoff_duration] is 300s, and ``max_doublings`` is 3, then + the a job will first be retried in 10s. The retry interval + will double three times, and then increase linearly by 2^3 \* + 10s. Finally, the job will retry at intervals of [max_backoff\_ + duration][google.cloud.scheduler.v1.RetryConfig.max_backoff_du + ration] until the job has been attempted [retry_count][google. + cloud.scheduler.v1.RetryConfig.retry_count] times. Thus, the + requests will retry at 10s, 20s, 40s, 80s, 160s, 240s, 300s, + 300s, …. The default value of this field is 5. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.RetryConfig) - ), + }, ) _sym_db.RegisterMessage(RetryConfig) diff --git a/google/cloud/scheduler_v1/proto/target_pb2.py b/google/cloud/scheduler_v1/proto/target_pb2.py index 3baad34c..9a8e6645 100644 --- a/google/cloud/scheduler_v1/proto/target_pb2.py +++ b/google/cloud/scheduler_v1/proto/target_pb2.py @@ -2,9 +2,6 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/scheduler_v1/proto/target.proto -import sys - -_b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message @@ -24,12 +21,9 @@ name="google/cloud/scheduler_v1/proto/target.proto", package="google.cloud.scheduler.v1", syntax="proto3", - serialized_options=_b( - "\n\035com.google.cloud.scheduler.v1B\013TargetProtoP\001ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\352A@\n\033pubsub.googleapis.com/Topic\022!projects/{project}/topics/{topic}" - ), - serialized_pb=_b( - '\n,google/cloud/scheduler_v1/proto/target.proto\x12\x19google.cloud.scheduler.v1\x1a\x19google/api/resource.proto\x1a\x1cgoogle/api/annotations.proto"\xea\x02\n\nHttpTarget\x12\x0b\n\x03uri\x18\x01 \x01(\t\x12:\n\x0bhttp_method\x18\x02 \x01(\x0e\x32%.google.cloud.scheduler.v1.HttpMethod\x12\x43\n\x07headers\x18\x03 \x03(\x0b\x32\x32.google.cloud.scheduler.v1.HttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x04 \x01(\x0c\x12<\n\x0boauth_token\x18\x05 \x01(\x0b\x32%.google.cloud.scheduler.v1.OAuthTokenH\x00\x12:\n\noidc_token\x18\x06 \x01(\x0b\x32$.google.cloud.scheduler.v1.OidcTokenH\x00\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x16\n\x14\x61uthorization_header"\xbc\x02\n\x13\x41ppEngineHttpTarget\x12:\n\x0bhttp_method\x18\x01 \x01(\x0e\x32%.google.cloud.scheduler.v1.HttpMethod\x12G\n\x12\x61pp_engine_routing\x18\x02 \x01(\x0b\x32+.google.cloud.scheduler.v1.AppEngineRouting\x12\x14\n\x0crelative_uri\x18\x03 \x01(\t\x12L\n\x07headers\x18\x04 \x03(\x0b\x32;.google.cloud.scheduler.v1.AppEngineHttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x05 \x01(\x0c\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"\xd2\x01\n\x0cPubsubTarget\x12\x34\n\ntopic_name\x18\x01 \x01(\tB \xfa\x41\x1d\n\x1bpubsub.googleapis.com/Topic\x12\x0c\n\x04\x64\x61ta\x18\x03 \x01(\x0c\x12K\n\nattributes\x18\x04 \x03(\x0b\x32\x37.google.cloud.scheduler.v1.PubsubTarget.AttributesEntry\x1a\x31\n\x0f\x41ttributesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"T\n\x10\x41ppEngineRouting\x12\x0f\n\x07service\x18\x01 \x01(\t\x12\x0f\n\x07version\x18\x02 \x01(\t\x12\x10\n\x08instance\x18\x03 \x01(\t\x12\x0c\n\x04host\x18\x04 \x01(\t":\n\nOAuthToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\r\n\x05scope\x18\x02 \x01(\t"<\n\tOidcToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\x10\n\x08\x61udience\x18\x02 \x01(\t*s\n\nHttpMethod\x12\x1b\n\x17HTTP_METHOD_UNSPECIFIED\x10\x00\x12\x08\n\x04POST\x10\x01\x12\x07\n\x03GET\x10\x02\x12\x08\n\x04HEAD\x10\x03\x12\x07\n\x03PUT\x10\x04\x12\n\n\x06\x44\x45LETE\x10\x05\x12\t\n\x05PATCH\x10\x06\x12\x0b\n\x07OPTIONS\x10\x07\x42\xb5\x01\n\x1d\x63om.google.cloud.scheduler.v1B\x0bTargetProtoP\x01ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\xea\x41@\n\x1bpubsub.googleapis.com/Topic\x12!projects/{project}/topics/{topic}b\x06proto3' - ), + serialized_options=b"\n\035com.google.cloud.scheduler.v1B\013TargetProtoP\001ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\352A@\n\033pubsub.googleapis.com/Topic\022!projects/{project}/topics/{topic}", + create_key=_descriptor._internal_create_key, + serialized_pb=b'\n,google/cloud/scheduler_v1/proto/target.proto\x12\x19google.cloud.scheduler.v1\x1a\x19google/api/resource.proto\x1a\x1cgoogle/api/annotations.proto"\xea\x02\n\nHttpTarget\x12\x0b\n\x03uri\x18\x01 \x01(\t\x12:\n\x0bhttp_method\x18\x02 \x01(\x0e\x32%.google.cloud.scheduler.v1.HttpMethod\x12\x43\n\x07headers\x18\x03 \x03(\x0b\x32\x32.google.cloud.scheduler.v1.HttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x04 \x01(\x0c\x12<\n\x0boauth_token\x18\x05 \x01(\x0b\x32%.google.cloud.scheduler.v1.OAuthTokenH\x00\x12:\n\noidc_token\x18\x06 \x01(\x0b\x32$.google.cloud.scheduler.v1.OidcTokenH\x00\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x16\n\x14\x61uthorization_header"\xbc\x02\n\x13\x41ppEngineHttpTarget\x12:\n\x0bhttp_method\x18\x01 \x01(\x0e\x32%.google.cloud.scheduler.v1.HttpMethod\x12G\n\x12\x61pp_engine_routing\x18\x02 \x01(\x0b\x32+.google.cloud.scheduler.v1.AppEngineRouting\x12\x14\n\x0crelative_uri\x18\x03 \x01(\t\x12L\n\x07headers\x18\x04 \x03(\x0b\x32;.google.cloud.scheduler.v1.AppEngineHttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x05 \x01(\x0c\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"\xd2\x01\n\x0cPubsubTarget\x12\x34\n\ntopic_name\x18\x01 \x01(\tB \xfa\x41\x1d\n\x1bpubsub.googleapis.com/Topic\x12\x0c\n\x04\x64\x61ta\x18\x03 \x01(\x0c\x12K\n\nattributes\x18\x04 \x03(\x0b\x32\x37.google.cloud.scheduler.v1.PubsubTarget.AttributesEntry\x1a\x31\n\x0f\x41ttributesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"T\n\x10\x41ppEngineRouting\x12\x0f\n\x07service\x18\x01 \x01(\t\x12\x0f\n\x07version\x18\x02 \x01(\t\x12\x10\n\x08instance\x18\x03 \x01(\t\x12\x0c\n\x04host\x18\x04 \x01(\t":\n\nOAuthToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\r\n\x05scope\x18\x02 \x01(\t"<\n\tOidcToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\x10\n\x08\x61udience\x18\x02 \x01(\t*s\n\nHttpMethod\x12\x1b\n\x17HTTP_METHOD_UNSPECIFIED\x10\x00\x12\x08\n\x04POST\x10\x01\x12\x07\n\x03GET\x10\x02\x12\x08\n\x04HEAD\x10\x03\x12\x07\n\x03PUT\x10\x04\x12\n\n\x06\x44\x45LETE\x10\x05\x12\t\n\x05PATCH\x10\x06\x12\x0b\n\x07OPTIONS\x10\x07\x42\xb5\x01\n\x1d\x63om.google.cloud.scheduler.v1B\x0bTargetProtoP\x01ZBgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1;scheduler\xea\x41@\n\x1bpubsub.googleapis.com/Topic\x12!projects/{project}/topics/{topic}b\x06proto3', dependencies=[ google_dot_api_dot_resource__pb2.DESCRIPTOR, google_dot_api_dot_annotations__pb2.DESCRIPTOR, @@ -41,6 +35,7 @@ full_name="google.cloud.scheduler.v1.HttpMethod", filename=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, values=[ _descriptor.EnumValueDescriptor( name="HTTP_METHOD_UNSPECIFIED", @@ -48,27 +43,63 @@ number=0, serialized_options=None, type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="POST", index=1, number=1, serialized_options=None, type=None + name="POST", + index=1, + number=1, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="GET", index=2, number=2, serialized_options=None, type=None + name="GET", + index=2, + number=2, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="HEAD", index=3, number=3, serialized_options=None, type=None + name="HEAD", + index=3, + number=3, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="PUT", index=4, number=4, serialized_options=None, type=None + name="PUT", + index=4, + number=4, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="DELETE", index=5, number=5, serialized_options=None, type=None + name="DELETE", + index=5, + number=5, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="PATCH", index=6, number=6, serialized_options=None, type=None + name="PATCH", + index=6, + number=6, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="OPTIONS", index=7, number=7, serialized_options=None, type=None + name="OPTIONS", + index=7, + number=7, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), ], containing_type=None, @@ -95,6 +126,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="key", @@ -105,7 +137,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -113,6 +145,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="value", @@ -123,7 +156,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -131,12 +164,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], enum_types=[], - serialized_options=_b("8\001"), + serialized_options=b"8\001", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -151,6 +185,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="uri", @@ -161,7 +196,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -169,6 +204,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="http_method", @@ -187,6 +223,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="headers", @@ -205,6 +242,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="body", @@ -215,7 +253,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b(""), + default_value=b"", message_type=None, enum_type=None, containing_type=None, @@ -223,6 +261,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="oauth_token", @@ -241,6 +280,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="oidc_token", @@ -259,10 +299,11 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], - nested_types=[_HTTPTARGET_HEADERSENTRY], + nested_types=[_HTTPTARGET_HEADERSENTRY,], enum_types=[], serialized_options=None, is_extendable=False, @@ -274,8 +315,9 @@ full_name="google.cloud.scheduler.v1.HttpTarget.authorization_header", index=0, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[], - ) + ), ], serialized_start=133, serialized_end=495, @@ -288,6 +330,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="key", @@ -298,7 +341,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -306,6 +349,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="value", @@ -316,7 +360,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -324,12 +368,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], enum_types=[], - serialized_options=_b("8\001"), + serialized_options=b"8\001", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -344,6 +389,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="http_method", @@ -362,6 +408,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="app_engine_routing", @@ -380,6 +427,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="relative_uri", @@ -390,7 +438,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -398,6 +446,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="headers", @@ -416,6 +465,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="body", @@ -426,7 +476,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b(""), + default_value=b"", message_type=None, enum_type=None, containing_type=None, @@ -434,10 +484,11 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], - nested_types=[_APPENGINEHTTPTARGET_HEADERSENTRY], + nested_types=[_APPENGINEHTTPTARGET_HEADERSENTRY,], enum_types=[], serialized_options=None, is_extendable=False, @@ -455,6 +506,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="key", @@ -465,7 +517,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -473,6 +525,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="value", @@ -483,7 +536,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -491,12 +544,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], enum_types=[], - serialized_options=_b("8\001"), + serialized_options=b"8\001", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -511,6 +565,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="topic_name", @@ -521,14 +576,15 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\372A\035\n\033pubsub.googleapis.com/Topic"), + serialized_options=b"\372A\035\n\033pubsub.googleapis.com/Topic", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="data", @@ -539,7 +595,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b(""), + default_value=b"", message_type=None, enum_type=None, containing_type=None, @@ -547,6 +603,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="attributes", @@ -565,10 +622,11 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], - nested_types=[_PUBSUBTARGET_ATTRIBUTESENTRY], + nested_types=[_PUBSUBTARGET_ATTRIBUTESENTRY,], enum_types=[], serialized_options=None, is_extendable=False, @@ -586,6 +644,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="service", @@ -596,7 +655,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -604,6 +663,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="version", @@ -614,7 +674,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -622,6 +682,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="instance", @@ -632,7 +693,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -640,6 +701,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="host", @@ -650,7 +712,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -658,6 +720,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -679,6 +742,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="service_account_email", @@ -689,7 +753,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -697,6 +761,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="scope", @@ -707,7 +772,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -715,6 +780,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -736,6 +802,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="service_account_email", @@ -746,7 +813,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -754,6 +821,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="audience", @@ -764,7 +832,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -772,6 +840,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -825,29 +894,30 @@ HttpTarget = _reflection.GeneratedProtocolMessageType( "HttpTarget", (_message.Message,), - dict( - HeadersEntry=_reflection.GeneratedProtocolMessageType( + { + "HeadersEntry": _reflection.GeneratedProtocolMessageType( "HeadersEntry", (_message.Message,), - dict( - DESCRIPTOR=_HTTPTARGET_HEADERSENTRY, - __module__="google.cloud.scheduler_v1.proto.target_pb2" + { + "DESCRIPTOR": _HTTPTARGET_HEADERSENTRY, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2" # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.HttpTarget.HeadersEntry) - ), + }, ), - DESCRIPTOR=_HTTPTARGET, - __module__="google.cloud.scheduler_v1.proto.target_pb2", - __doc__="""Http target. The job will be pushed to the job handler by means of an + "DESCRIPTOR": _HTTPTARGET, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2", + "__doc__": """Http target. The job will be pushed to the job handler by means of an HTTP request via an - [http\_method][google.cloud.scheduler.v1.HttpTarget.http\_method] such + [http_method][google.cloud.scheduler.v1.HttpTarget.http_method] such as HTTP POST, HTTP GET, etc. The job is acknowledged by means of an HTTP response code in the range [200 - 299]. A failure to receive a response constitutes a failed execution. For a redirected request, the response returned by the redirected request is considered. + Attributes: uri: Required. The full URI path that the request will be sent to. - This string must begin with either "http://" or "https://". + This string must begin with either “http://” or “https://”. Some examples of valid values for [uri][google.cloud.scheduler.v1.HttpTarget.uri] are: ``http://acme.com`` and ``https://acme.com/sales:8080``. Cloud @@ -858,10 +928,10 @@ Which HTTP method to use for the request. headers: The user can specify HTTP request headers to send with the - job's HTTP request. This map contains the header field names + job’s HTTP request. This map contains the header field names and values. Repeated headers are not supported, but a header value can contain commas. These headers represent a subset of - the headers that will accompany the job's HTTP request. Some + the headers that will accompany the job’s HTTP request. Some HTTP request headers will be ignored or replaced. A partial list of headers that will be ignored or replaced is below: - Host: This will be computed by Cloud Scheduler and derived @@ -883,7 +953,7 @@ ers] field will be overridden. oauth_token: If specified, an `OAuth token - `__ + `_\_ will be generated and attached as an ``Authorization`` header in the HTTP request. This type of authorization should generally only be used when calling Google APIs hosted on @@ -897,7 +967,7 @@ validate the token yourself. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.HttpTarget) - ), + }, ) _sym_db.RegisterMessage(HttpTarget) _sym_db.RegisterMessage(HttpTarget.HeadersEntry) @@ -905,27 +975,28 @@ AppEngineHttpTarget = _reflection.GeneratedProtocolMessageType( "AppEngineHttpTarget", (_message.Message,), - dict( - HeadersEntry=_reflection.GeneratedProtocolMessageType( + { + "HeadersEntry": _reflection.GeneratedProtocolMessageType( "HeadersEntry", (_message.Message,), - dict( - DESCRIPTOR=_APPENGINEHTTPTARGET_HEADERSENTRY, - __module__="google.cloud.scheduler_v1.proto.target_pb2" + { + "DESCRIPTOR": _APPENGINEHTTPTARGET_HEADERSENTRY, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2" # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.AppEngineHttpTarget.HeadersEntry) - ), + }, ), - DESCRIPTOR=_APPENGINEHTTPTARGET, - __module__="google.cloud.scheduler_v1.proto.target_pb2", - __doc__="""App Engine target. The job will be pushed to a job handler by means of - an HTTP request via an [http\_method][google.cloud.scheduler.v1.AppEng - ineHttpTarget.http\_method] such as HTTP POST, HTTP GET, etc. The job - is acknowledged by means of an HTTP response code in the range [200 - + "DESCRIPTOR": _APPENGINEHTTPTARGET, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2", + "__doc__": """App Engine target. The job will be pushed to a job handler by means of + an HTTP request via an [http_method][google.cloud.scheduler.v1.AppEngi + neHttpTarget.http_method] such as HTTP POST, HTTP GET, etc. The job is + acknowledged by means of an HTTP response code in the range [200 - 299]. Error 503 is considered an App Engine system error instead of an application error. Requests returning error 503 will be retried regardless of retry configuration and not counted against retry counts. Any other response code, or a failure to receive a response before the deadline, constitutes a failed attempt. + Attributes: http_method: The HTTP method to use for the request. PATCH and OPTIONS are @@ -933,10 +1004,10 @@ app_engine_routing: App Engine Routing setting for the job. relative_uri: - The relative URI. The relative URL must begin with "/" and + The relative URI. The relative URL must begin with “/” and must be a valid HTTP relative URL. It can contain a path, query string arguments, and ``#`` fragments. If the relative - URL is empty, then the root path "/" will be used. No spaces + URL is empty, then the root path “/” will be used. No spaces are allowed, and the maximum length allowed is 2083 characters. headers: @@ -970,7 +1041,7 @@ [HttpMethod][google.cloud.scheduler.v1.HttpMethod]. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.AppEngineHttpTarget) - ), + }, ) _sym_db.RegisterMessage(AppEngineHttpTarget) _sym_db.RegisterMessage(AppEngineHttpTarget.HeadersEntry) @@ -978,25 +1049,26 @@ PubsubTarget = _reflection.GeneratedProtocolMessageType( "PubsubTarget", (_message.Message,), - dict( - AttributesEntry=_reflection.GeneratedProtocolMessageType( + { + "AttributesEntry": _reflection.GeneratedProtocolMessageType( "AttributesEntry", (_message.Message,), - dict( - DESCRIPTOR=_PUBSUBTARGET_ATTRIBUTESENTRY, - __module__="google.cloud.scheduler_v1.proto.target_pb2" + { + "DESCRIPTOR": _PUBSUBTARGET_ATTRIBUTESENTRY, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2" # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.PubsubTarget.AttributesEntry) - ), + }, ), - DESCRIPTOR=_PUBSUBTARGET, - __module__="google.cloud.scheduler_v1.proto.target_pb2", - __doc__="""Pub/Sub target. The job will be delivered by publishing a message to + "DESCRIPTOR": _PUBSUBTARGET, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2", + "__doc__": """Pub/Sub target. The job will be delivered by publishing a message to the given Pub/Sub topic. + Attributes: topic_name: Required. The name of the Cloud Pub/Sub topic to which messages will be published when a job is delivered. The topic - name must be in the same format as required by PubSub's + name must be in the same format as required by PubSub’s `PublishRequest.name `__, for example ``projects/PROJECT_ID/topics/TOPIC_ID``. The topic must be in @@ -1009,7 +1081,7 @@ either non-empty data, or at least one attribute. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.PubsubTarget) - ), + }, ) _sym_db.RegisterMessage(PubsubTarget) _sym_db.RegisterMessage(PubsubTarget.AttributesEntry) @@ -1017,10 +1089,10 @@ AppEngineRouting = _reflection.GeneratedProtocolMessageType( "AppEngineRouting", (_message.Message,), - dict( - DESCRIPTOR=_APPENGINEROUTING, - __module__="google.cloud.scheduler_v1.proto.target_pb2", - __doc__="""App Engine Routing. For more information about services, versions, + { + "DESCRIPTOR": _APPENGINEROUTING, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2", + "__doc__": """App Engine Routing. For more information about services, versions, and instances see `An Overview of App Engine `__, `Microservices Architecture on Google App Engine @@ -1030,6 +1102,7 @@ are-routed>`__, and `App Engine Flex request routing `__. + Attributes: service: App service. By default, the job is sent to the service which @@ -1066,7 +1139,7 @@ ``| [instance_dot_version_dot_service] + '.' + [application_domain_name]`` - ``application_domain_name`` = The domain name of the app, for example .appspot.com, which - is associated with the job's project ID. - ``service =`` + is associated with the job’s project ID. - ``service =`` [service][google.cloud.scheduler.v1.AppEngineRouting.service] - ``version =`` [version][google.cloud.scheduler.v1.AppEngineRouting.version] @@ -1104,20 +1177,21 @@ version of the default service when the job is attempted. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.AppEngineRouting) - ), + }, ) _sym_db.RegisterMessage(AppEngineRouting) OAuthToken = _reflection.GeneratedProtocolMessageType( "OAuthToken", (_message.Message,), - dict( - DESCRIPTOR=_OAUTHTOKEN, - __module__="google.cloud.scheduler_v1.proto.target_pb2", - __doc__="""Contains information needed for generating an `OAuth token + { + "DESCRIPTOR": _OAUTHTOKEN, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2", + "__doc__": """Contains information needed for generating an `OAuth token `__. This type of authorization should generally only be used when calling Google APIs hosted on \*.googleapis.com. + Attributes: service_account_email: \ `Service account email @@ -1127,25 +1201,26 @@ iam.serviceAccounts.actAs permission for the service account. scope: OAuth scope to be used for generating OAuth access token. If - not specified, "https://www.googleapis.com/auth/cloud- - platform" will be used. + not specified, “https://www.googleapis.com/auth/cloud- + platform” will be used. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.OAuthToken) - ), + }, ) _sym_db.RegisterMessage(OAuthToken) OidcToken = _reflection.GeneratedProtocolMessageType( "OidcToken", (_message.Message,), - dict( - DESCRIPTOR=_OIDCTOKEN, - __module__="google.cloud.scheduler_v1.proto.target_pb2", - __doc__="""Contains information needed for generating an `OpenID Connect token + { + "DESCRIPTOR": _OIDCTOKEN, + "__module__": "google.cloud.scheduler_v1.proto.target_pb2", + "__doc__": """Contains information needed for generating an `OpenID Connect token `__. This type of authorization can be used for many scenarios, including calling Cloud Run, or endpoints where you intend to validate the token yourself. + Attributes: service_account_email: \ `Service account email @@ -1158,7 +1233,7 @@ specified, the URI specified in target will be used. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1.OidcToken) - ), + }, ) _sym_db.RegisterMessage(OidcToken) diff --git a/google/cloud/scheduler_v1/types.py b/google/cloud/scheduler_v1/types.py index 8646c06b..74858d86 100644 --- a/google/cloud/scheduler_v1/types.py +++ b/google/cloud/scheduler_v1/types.py @@ -40,7 +40,11 @@ status_pb2, ] -_local_modules = [cloudscheduler_pb2, job_pb2, target_pb2] +_local_modules = [ + cloudscheduler_pb2, + job_pb2, + target_pb2, +] names = [] diff --git a/google/cloud/scheduler_v1beta1/__init__.py b/google/cloud/scheduler_v1beta1/__init__.py index a23cbd79..91dd8aec 100644 --- a/google/cloud/scheduler_v1beta1/__init__.py +++ b/google/cloud/scheduler_v1beta1/__init__.py @@ -26,8 +26,8 @@ if sys.version_info[:2] == (2, 7): message = ( - "A future version of this library will drop support for Python 2.7." - "More details about Python 2 support for Google Cloud Client Libraries" + "A future version of this library will drop support for Python 2.7. " + "More details about Python 2 support for Google Cloud Client Libraries " "can be found at https://cloud.google.com/python/docs/python2-sunset/" ) warnings.warn(message, DeprecationWarning) @@ -38,4 +38,8 @@ class CloudSchedulerClient(cloud_scheduler_client.CloudSchedulerClient): enums = enums -__all__ = ("enums", "types", "CloudSchedulerClient") +__all__ = ( + "enums", + "types", + "CloudSchedulerClient", +) diff --git a/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client.py b/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client.py index f0ae1140..355ccf2d 100644 --- a/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client.py +++ b/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client.py @@ -44,7 +44,7 @@ _GAPIC_LIBRARY_VERSION = pkg_resources.get_distribution( - "google-cloud-scheduler" + "google-cloud-scheduler", ).version @@ -187,12 +187,12 @@ def __init__( self.transport = transport else: self.transport = cloud_scheduler_grpc_transport.CloudSchedulerGrpcTransport( - address=api_endpoint, channel=channel, credentials=credentials + address=api_endpoint, channel=channel, credentials=credentials, ) if client_info is None: client_info = google.api_core.gapic_v1.client_info.ClientInfo( - gapic_version=_GAPIC_LIBRARY_VERSION + gapic_version=_GAPIC_LIBRARY_VERSION, ) else: client_info.gapic_version = _GAPIC_LIBRARY_VERSION @@ -203,7 +203,7 @@ def __init__( # (Ordinarily, these are the defaults specified in the `*_config.py` # file next to this one.) self._method_configs = google.api_core.gapic_v1.config.parse_method_configs( - client_config["interfaces"][self._INTERFACE_NAME] + client_config["interfaces"][self._INTERFACE_NAME], ) # Save a dictionary of cached API call functions. @@ -286,7 +286,9 @@ def list_jobs( client_info=self._client_info, ) - request = cloudscheduler_pb2.ListJobsRequest(parent=parent, page_size=page_size) + request = cloudscheduler_pb2.ListJobsRequest( + parent=parent, page_size=page_size, + ) if metadata is None: metadata = [] metadata = list(metadata) @@ -367,7 +369,7 @@ def get_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.GetJobRequest(name=name) + request = cloudscheduler_pb2.GetJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -411,10 +413,10 @@ def create_job( Args: parent (str): Required. The location name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID``. - job (Union[dict, ~google.cloud.scheduler_v1beta1.types.Job]): Required. The job to add. The user can optionally specify a name for the - job in ``name``. ``name`` cannot be the same as an existing job. If a - name is not specified then the system will generate a random unique name - that will be returned (``name``) in the response. + job (Union[dict, ~google.cloud.scheduler_v1beta1.types.Job]): Required. The job to add. The user can optionally specify a name for + the job in ``name``. ``name`` cannot be the same as an existing job. If + a name is not specified then the system will generate a random unique + name that will be returned (``name``) in the response. If a dict is provided, it must be of the same form as the protobuf message :class:`~google.cloud.scheduler_v1beta1.types.Job` @@ -448,7 +450,7 @@ def create_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.CreateJobRequest(parent=parent, job=job) + request = cloudscheduler_pb2.CreateJobRequest(parent=parent, job=job,) if metadata is None: metadata = [] metadata = list(metadata) @@ -537,7 +539,7 @@ def update_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.UpdateJobRequest(job=job, update_mask=update_mask) + request = cloudscheduler_pb2.UpdateJobRequest(job=job, update_mask=update_mask,) if metadata is None: metadata = [] metadata = list(metadata) @@ -604,7 +606,7 @@ def delete_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.DeleteJobRequest(name=name) + request = cloudscheduler_pb2.DeleteJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -679,7 +681,7 @@ def pause_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.PauseJobRequest(name=name) + request = cloudscheduler_pb2.PauseJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -754,7 +756,7 @@ def resume_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.ResumeJobRequest(name=name) + request = cloudscheduler_pb2.ResumeJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) @@ -827,7 +829,7 @@ def run_job( client_info=self._client_info, ) - request = cloudscheduler_pb2.RunJobRequest(name=name) + request = cloudscheduler_pb2.RunJobRequest(name=name,) if metadata is None: metadata = [] metadata = list(metadata) diff --git a/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client_config.py b/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client_config.py index f2dce757..cb3b1f48 100644 --- a/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client_config.py +++ b/google/cloud/scheduler_v1beta1/gapic/cloud_scheduler_client_config.py @@ -2,60 +2,79 @@ "interfaces": { "google.cloud.scheduler.v1beta1.CloudScheduler": { "retry_codes": { - "idempotent": ["DEADLINE_EXCEEDED", "UNAVAILABLE"], - "non_idempotent": [], + "retry_policy_1_codes": ["DEADLINE_EXCEEDED", "UNAVAILABLE"], + "no_retry_codes": [], + "no_retry_1_codes": [], }, "retry_params": { - "default": { + "retry_policy_1_params": { "initial_retry_delay_millis": 100, "retry_delay_multiplier": 1.3, "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 20000, + "initial_rpc_timeout_millis": 600000, "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 20000, + "max_rpc_timeout_millis": 600000, "total_timeout_millis": 600000, - } + }, + "no_retry_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 0, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 0, + "total_timeout_millis": 0, + }, + "no_retry_1_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 600000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 600000, + "total_timeout_millis": 600000, + }, }, "methods": { "ListJobs": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "GetJob": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "CreateJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, "UpdateJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, "DeleteJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "PauseJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "ResumeJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params", }, "RunJob": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default", + "timeout_millis": 600000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params", }, }, } diff --git a/google/cloud/scheduler_v1beta1/gapic/transports/cloud_scheduler_grpc_transport.py b/google/cloud/scheduler_v1beta1/gapic/transports/cloud_scheduler_grpc_transport.py index 5c7c75bc..ac6585c2 100644 --- a/google/cloud/scheduler_v1beta1/gapic/transports/cloud_scheduler_grpc_transport.py +++ b/google/cloud/scheduler_v1beta1/gapic/transports/cloud_scheduler_grpc_transport.py @@ -56,7 +56,7 @@ def __init__( # exception (channels come with credentials baked in already). if channel is not None and credentials is not None: raise ValueError( - "The `channel` and `credentials` arguments are mutually " "exclusive." + "The `channel` and `credentials` arguments are mutually " "exclusive.", ) # Create the channel. @@ -75,7 +75,7 @@ def __init__( # gRPC uses objects called "stubs" that are bound to the # channel and provide a basic method for each RPC. self._stubs = { - "cloud_scheduler_stub": cloudscheduler_pb2_grpc.CloudSchedulerStub(channel) + "cloud_scheduler_stub": cloudscheduler_pb2_grpc.CloudSchedulerStub(channel), } @classmethod diff --git a/google/cloud/scheduler_v1beta1/proto/cloudscheduler_pb2.py b/google/cloud/scheduler_v1beta1/proto/cloudscheduler_pb2.py index 20bb4cd0..d80fb58c 100644 --- a/google/cloud/scheduler_v1beta1/proto/cloudscheduler_pb2.py +++ b/google/cloud/scheduler_v1beta1/proto/cloudscheduler_pb2.py @@ -2,9 +2,6 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/scheduler_v1beta1/proto/cloudscheduler.proto -import sys - -_b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection @@ -30,12 +27,9 @@ name="google/cloud/scheduler_v1beta1/proto/cloudscheduler.proto", package="google.cloud.scheduler.v1beta1", syntax="proto3", - serialized_options=_b( - '\n"com.google.cloud.scheduler.v1beta1B\016SchedulerProtoP\001ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\242\002\tSCHEDULER' - ), - serialized_pb=_b( - '\n9google/cloud/scheduler_v1beta1/proto/cloudscheduler.proto\x12\x1egoogle.cloud.scheduler.v1beta1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a.google/cloud/scheduler_v1beta1/proto/job.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto"s\n\x0fListJobsRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x11\n\tpage_size\x18\x05 \x01(\x05\x12\x12\n\npage_token\x18\x06 \x01(\t"^\n\x10ListJobsResponse\x12\x31\n\x04jobs\x18\x01 \x03(\x0b\x32#.google.cloud.scheduler.v1beta1.Job\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t"H\n\rGetJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"\x84\x01\n\x10\x43reateJobRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x35\n\x03job\x18\x02 \x01(\x0b\x32#.google.cloud.scheduler.v1beta1.JobB\x03\xe0\x41\x02"z\n\x10UpdateJobRequest\x12\x35\n\x03job\x18\x01 \x01(\x0b\x32#.google.cloud.scheduler.v1beta1.JobB\x03\xe0\x41\x02\x12/\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMask"K\n\x10\x44\x65leteJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"J\n\x0fPauseJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"K\n\x10ResumeJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"H\n\rRunJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job2\xa6\x0b\n\x0e\x43loudScheduler\x12\xad\x01\n\x08ListJobs\x12/.google.cloud.scheduler.v1beta1.ListJobsRequest\x1a\x30.google.cloud.scheduler.v1beta1.ListJobsResponse">\x82\xd3\xe4\x93\x02/\x12-/v1beta1/{parent=projects/*/locations/*}/jobs\xda\x41\x06parent\x12\x9a\x01\n\x06GetJob\x12-.google.cloud.scheduler.v1beta1.GetJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"<\x82\xd3\xe4\x93\x02/\x12-/v1beta1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\xab\x01\n\tCreateJob\x12\x30.google.cloud.scheduler.v1beta1.CreateJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"G\x82\xd3\xe4\x93\x02\x34"-/v1beta1/{parent=projects/*/locations/*}/jobs:\x03job\xda\x41\nparent,job\x12\xb4\x01\n\tUpdateJob\x12\x30.google.cloud.scheduler.v1beta1.UpdateJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"P\x82\xd3\xe4\x93\x02\x38\x32\x31/v1beta1/{job.name=projects/*/locations/*/jobs/*}:\x03job\xda\x41\x0fjob,update_mask\x12\x93\x01\n\tDeleteJob\x12\x30.google.cloud.scheduler.v1beta1.DeleteJobRequest\x1a\x16.google.protobuf.Empty"<\x82\xd3\xe4\x93\x02/*-/v1beta1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\xa7\x01\n\x08PauseJob\x12/.google.cloud.scheduler.v1beta1.PauseJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"E\x82\xd3\xe4\x93\x02\x38"3/v1beta1/{name=projects/*/locations/*/jobs/*}:pause:\x01*\xda\x41\x04name\x12\xaa\x01\n\tResumeJob\x12\x30.google.cloud.scheduler.v1beta1.ResumeJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"F\x82\xd3\xe4\x93\x02\x39"4/v1beta1/{name=projects/*/locations/*/jobs/*}:resume:\x01*\xda\x41\x04name\x12\xa1\x01\n\x06RunJob\x12-.google.cloud.scheduler.v1beta1.RunJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"C\x82\xd3\xe4\x93\x02\x36"1/v1beta1/{name=projects/*/locations/*/jobs/*}:run:\x01*\xda\x41\x04name\x1aQ\xca\x41\x1d\x63loudscheduler.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\x8b\x01\n"com.google.cloud.scheduler.v1beta1B\x0eSchedulerProtoP\x01ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\xa2\x02\tSCHEDULERb\x06proto3' - ), + serialized_options=b'\n"com.google.cloud.scheduler.v1beta1B\016SchedulerProtoP\001ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\242\002\tSCHEDULER', + create_key=_descriptor._internal_create_key, + serialized_pb=b'\n9google/cloud/scheduler_v1beta1/proto/cloudscheduler.proto\x12\x1egoogle.cloud.scheduler.v1beta1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a.google/cloud/scheduler_v1beta1/proto/job.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a google/protobuf/field_mask.proto"s\n\x0fListJobsRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x11\n\tpage_size\x18\x05 \x01(\x05\x12\x12\n\npage_token\x18\x06 \x01(\t"^\n\x10ListJobsResponse\x12\x31\n\x04jobs\x18\x01 \x03(\x0b\x32#.google.cloud.scheduler.v1beta1.Job\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t"H\n\rGetJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"\x84\x01\n\x10\x43reateJobRequest\x12\x39\n\x06parent\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\x12!cloudscheduler.googleapis.com/Job\x12\x35\n\x03job\x18\x02 \x01(\x0b\x32#.google.cloud.scheduler.v1beta1.JobB\x03\xe0\x41\x02"z\n\x10UpdateJobRequest\x12\x35\n\x03job\x18\x01 \x01(\x0b\x32#.google.cloud.scheduler.v1beta1.JobB\x03\xe0\x41\x02\x12/\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMask"K\n\x10\x44\x65leteJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"J\n\x0fPauseJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"K\n\x10ResumeJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job"H\n\rRunJobRequest\x12\x37\n\x04name\x18\x01 \x01(\tB)\xe0\x41\x02\xfa\x41#\n!cloudscheduler.googleapis.com/Job2\xa6\x0b\n\x0e\x43loudScheduler\x12\xad\x01\n\x08ListJobs\x12/.google.cloud.scheduler.v1beta1.ListJobsRequest\x1a\x30.google.cloud.scheduler.v1beta1.ListJobsResponse">\x82\xd3\xe4\x93\x02/\x12-/v1beta1/{parent=projects/*/locations/*}/jobs\xda\x41\x06parent\x12\x9a\x01\n\x06GetJob\x12-.google.cloud.scheduler.v1beta1.GetJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"<\x82\xd3\xe4\x93\x02/\x12-/v1beta1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\xab\x01\n\tCreateJob\x12\x30.google.cloud.scheduler.v1beta1.CreateJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"G\x82\xd3\xe4\x93\x02\x34"-/v1beta1/{parent=projects/*/locations/*}/jobs:\x03job\xda\x41\nparent,job\x12\xb4\x01\n\tUpdateJob\x12\x30.google.cloud.scheduler.v1beta1.UpdateJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"P\x82\xd3\xe4\x93\x02\x38\x32\x31/v1beta1/{job.name=projects/*/locations/*/jobs/*}:\x03job\xda\x41\x0fjob,update_mask\x12\x93\x01\n\tDeleteJob\x12\x30.google.cloud.scheduler.v1beta1.DeleteJobRequest\x1a\x16.google.protobuf.Empty"<\x82\xd3\xe4\x93\x02/*-/v1beta1/{name=projects/*/locations/*/jobs/*}\xda\x41\x04name\x12\xa7\x01\n\x08PauseJob\x12/.google.cloud.scheduler.v1beta1.PauseJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"E\x82\xd3\xe4\x93\x02\x38"3/v1beta1/{name=projects/*/locations/*/jobs/*}:pause:\x01*\xda\x41\x04name\x12\xaa\x01\n\tResumeJob\x12\x30.google.cloud.scheduler.v1beta1.ResumeJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"F\x82\xd3\xe4\x93\x02\x39"4/v1beta1/{name=projects/*/locations/*/jobs/*}:resume:\x01*\xda\x41\x04name\x12\xa1\x01\n\x06RunJob\x12-.google.cloud.scheduler.v1beta1.RunJobRequest\x1a#.google.cloud.scheduler.v1beta1.Job"C\x82\xd3\xe4\x93\x02\x36"1/v1beta1/{name=projects/*/locations/*/jobs/*}:run:\x01*\xda\x41\x04name\x1aQ\xca\x41\x1d\x63loudscheduler.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\x8b\x01\n"com.google.cloud.scheduler.v1beta1B\x0eSchedulerProtoP\x01ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\xa2\x02\tSCHEDULERb\x06proto3', dependencies=[ google_dot_api_dot_annotations__pb2.DESCRIPTOR, google_dot_api_dot_client__pb2.DESCRIPTOR, @@ -54,6 +48,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="parent", @@ -64,16 +59,15 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\022!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\022!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="page_size", @@ -92,6 +86,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="page_token", @@ -102,7 +97,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -110,6 +105,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -131,6 +127,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="jobs", @@ -149,6 +146,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="next_page_token", @@ -159,7 +157,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -167,6 +165,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -188,6 +187,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -198,17 +198,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -229,6 +228,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="parent", @@ -239,16 +239,15 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\022!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\022!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="job", @@ -265,8 +264,9 @@ containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\340A\002"), + serialized_options=b"\340A\002", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -288,6 +288,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="job", @@ -304,8 +305,9 @@ containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\340A\002"), + serialized_options=b"\340A\002", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="update_mask", @@ -324,6 +326,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -345,6 +348,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -355,17 +359,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -386,6 +389,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -396,17 +400,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -427,6 +430,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -437,17 +441,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -468,6 +471,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -478,17 +482,16 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b( - "\340A\002\372A#\n!cloudscheduler.googleapis.com/Job" - ), + serialized_options=b"\340A\002\372A#\n!cloudscheduler.googleapis.com/Job", file=DESCRIPTOR, - ) + create_key=_descriptor._internal_create_key, + ), ], extensions=[], nested_types=[], @@ -528,11 +531,12 @@ ListJobsRequest = _reflection.GeneratedProtocolMessageType( "ListJobsRequest", (_message.Message,), - dict( - DESCRIPTOR=_LISTJOBSREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for listing jobs using + { + "DESCRIPTOR": _LISTJOBSREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for listing jobs using [ListJobs][google.cloud.scheduler.v1beta1.CloudScheduler.ListJobs]. + Attributes: parent: Required. The location name. For example: @@ -541,75 +545,78 @@ Requested page size. The maximum page size is 500. If unspecified, the page size will be the maximum. Fewer jobs than requested might be returned, even if more jobs exist; use - next\_page\_token to determine if more jobs exist. + next_page_token to determine if more jobs exist. page_token: A token identifying a page of results the server will return. - To request the first page results, page\_token must be empty. - To request the next page of results, page\_token must be the - value of [next\_page\_token][google.cloud.scheduler.v1beta1.Li - stJobsResponse.next\_page\_token] returned from the previous - call to [ListJobs][google.cloud.scheduler.v1beta1.CloudSchedul - er.ListJobs]. It is an error to switch the value of [filter][g - oogle.cloud.scheduler.v1beta1.ListJobsRequest.filter] or [orde - r\_by][google.cloud.scheduler.v1beta1.ListJobsRequest.order\_b - y] while iterating through pages. + To request the first page results, page_token must be empty. + To request the next page of results, page_token must be the + value of [next_page_token][google.cloud.scheduler.v1beta1.List + JobsResponse.next_page_token] returned from the previous call + to [ListJobs][google.cloud.scheduler.v1beta1.CloudScheduler.Li + stJobs]. It is an error to switch the value of [filter][google + .cloud.scheduler.v1beta1.ListJobsRequest.filter] or [order_by] + [google.cloud.scheduler.v1beta1.ListJobsRequest.order_by] + while iterating through pages. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.ListJobsRequest) - ), + }, ) _sym_db.RegisterMessage(ListJobsRequest) ListJobsResponse = _reflection.GeneratedProtocolMessageType( "ListJobsResponse", (_message.Message,), - dict( - DESCRIPTOR=_LISTJOBSRESPONSE, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Response message for listing jobs using + { + "DESCRIPTOR": _LISTJOBSRESPONSE, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Response message for listing jobs using [ListJobs][google.cloud.scheduler.v1beta1.CloudScheduler.ListJobs]. + Attributes: jobs: The list of jobs. next_page_token: A token to retrieve next page of results. Pass this value in - the [page\_token][google.cloud.scheduler.v1beta1.ListJobsReque - st.page\_token] field in the subsequent call to [ListJobs][goo - gle.cloud.scheduler.v1beta1.CloudScheduler.ListJobs] to - retrieve the next page of results. If this is empty it - indicates that there are no more results through which to - paginate. The page token is valid for only 2 hours. + the [page_token][google.cloud.scheduler.v1beta1.ListJobsReques + t.page_token] field in the subsequent call to [ListJobs][googl + e.cloud.scheduler.v1beta1.CloudScheduler.ListJobs] to retrieve + the next page of results. If this is empty it indicates that + there are no more results through which to paginate. The page + token is valid for only 2 hours. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.ListJobsResponse) - ), + }, ) _sym_db.RegisterMessage(ListJobsResponse) GetJobRequest = _reflection.GeneratedProtocolMessageType( "GetJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_GETJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _GETJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [GetJob][google.cloud.scheduler.v1beta1.CloudScheduler.GetJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.GetJobRequest) - ), + }, ) _sym_db.RegisterMessage(GetJobRequest) CreateJobRequest = _reflection.GeneratedProtocolMessageType( "CreateJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_CREATEJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _CREATEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [CreateJob][google.cloud.scheduler.v1beta1.CloudScheduler.CreateJob]. + Attributes: parent: Required. The location name. For example: @@ -625,18 +632,19 @@ the response. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.CreateJobRequest) - ), + }, ) _sym_db.RegisterMessage(CreateJobRequest) UpdateJobRequest = _reflection.GeneratedProtocolMessageType( "UpdateJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_UPDATEJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _UPDATEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [UpdateJob][google.cloud.scheduler.v1beta1.CloudScheduler.UpdateJob]. + Attributes: job: Required. The new job properties. @@ -649,79 +657,83 @@ updated. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.UpdateJobRequest) - ), + }, ) _sym_db.RegisterMessage(UpdateJobRequest) DeleteJobRequest = _reflection.GeneratedProtocolMessageType( "DeleteJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_DELETEJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for deleting a job using + { + "DESCRIPTOR": _DELETEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for deleting a job using [DeleteJob][google.cloud.scheduler.v1beta1.CloudScheduler.DeleteJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.DeleteJobRequest) - ), + }, ) _sym_db.RegisterMessage(DeleteJobRequest) PauseJobRequest = _reflection.GeneratedProtocolMessageType( "PauseJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_PAUSEJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _PAUSEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [PauseJob][google.cloud.scheduler.v1beta1.CloudScheduler.PauseJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.PauseJobRequest) - ), + }, ) _sym_db.RegisterMessage(PauseJobRequest) ResumeJobRequest = _reflection.GeneratedProtocolMessageType( "ResumeJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_RESUMEJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for + { + "DESCRIPTOR": _RESUMEJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for [ResumeJob][google.cloud.scheduler.v1beta1.CloudScheduler.ResumeJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.ResumeJobRequest) - ), + }, ) _sym_db.RegisterMessage(ResumeJobRequest) RunJobRequest = _reflection.GeneratedProtocolMessageType( "RunJobRequest", (_message.Message,), - dict( - DESCRIPTOR=_RUNJOBREQUEST, - __module__="google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", - __doc__="""Request message for forcing a job to run now using + { + "DESCRIPTOR": _RUNJOBREQUEST, + "__module__": "google.cloud.scheduler_v1beta1.proto.cloudscheduler_pb2", + "__doc__": """Request message for forcing a job to run now using [RunJob][google.cloud.scheduler.v1beta1.CloudScheduler.RunJob]. + Attributes: name: Required. The job name. For example: ``projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID``. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.RunJobRequest) - ), + }, ) _sym_db.RegisterMessage(RunJobRequest) @@ -742,9 +754,8 @@ full_name="google.cloud.scheduler.v1beta1.CloudScheduler", file=DESCRIPTOR, index=0, - serialized_options=_b( - "\312A\035cloudscheduler.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platform" - ), + serialized_options=b"\312A\035cloudscheduler.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platform", + create_key=_descriptor._internal_create_key, serialized_start=1170, serialized_end=2616, methods=[ @@ -755,9 +766,8 @@ containing_service=None, input_type=_LISTJOBSREQUEST, output_type=_LISTJOBSRESPONSE, - serialized_options=_b( - "\202\323\344\223\002/\022-/v1beta1/{parent=projects/*/locations/*}/jobs\332A\006parent" - ), + serialized_options=b"\202\323\344\223\002/\022-/v1beta1/{parent=projects/*/locations/*}/jobs\332A\006parent", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="GetJob", @@ -766,9 +776,8 @@ containing_service=None, input_type=_GETJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - "\202\323\344\223\002/\022-/v1beta1/{name=projects/*/locations/*/jobs/*}\332A\004name" - ), + serialized_options=b"\202\323\344\223\002/\022-/v1beta1/{name=projects/*/locations/*/jobs/*}\332A\004name", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="CreateJob", @@ -777,9 +786,8 @@ containing_service=None, input_type=_CREATEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0024"-/v1beta1/{parent=projects/*/locations/*}/jobs:\003job\332A\nparent,job' - ), + serialized_options=b'\202\323\344\223\0024"-/v1beta1/{parent=projects/*/locations/*}/jobs:\003job\332A\nparent,job', + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="UpdateJob", @@ -788,9 +796,8 @@ containing_service=None, input_type=_UPDATEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - "\202\323\344\223\002821/v1beta1/{job.name=projects/*/locations/*/jobs/*}:\003job\332A\017job,update_mask" - ), + serialized_options=b"\202\323\344\223\002821/v1beta1/{job.name=projects/*/locations/*/jobs/*}:\003job\332A\017job,update_mask", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="DeleteJob", @@ -799,9 +806,8 @@ containing_service=None, input_type=_DELETEJOBREQUEST, output_type=google_dot_protobuf_dot_empty__pb2._EMPTY, - serialized_options=_b( - "\202\323\344\223\002/*-/v1beta1/{name=projects/*/locations/*/jobs/*}\332A\004name" - ), + serialized_options=b"\202\323\344\223\002/*-/v1beta1/{name=projects/*/locations/*/jobs/*}\332A\004name", + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="PauseJob", @@ -810,9 +816,8 @@ containing_service=None, input_type=_PAUSEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0028"3/v1beta1/{name=projects/*/locations/*/jobs/*}:pause:\001*\332A\004name' - ), + serialized_options=b'\202\323\344\223\0028"3/v1beta1/{name=projects/*/locations/*/jobs/*}:pause:\001*\332A\004name', + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="ResumeJob", @@ -821,9 +826,8 @@ containing_service=None, input_type=_RESUMEJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0029"4/v1beta1/{name=projects/*/locations/*/jobs/*}:resume:\001*\332A\004name' - ), + serialized_options=b'\202\323\344\223\0029"4/v1beta1/{name=projects/*/locations/*/jobs/*}:resume:\001*\332A\004name', + create_key=_descriptor._internal_create_key, ), _descriptor.MethodDescriptor( name="RunJob", @@ -832,9 +836,8 @@ containing_service=None, input_type=_RUNJOBREQUEST, output_type=google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_job__pb2._JOB, - serialized_options=_b( - '\202\323\344\223\0026"1/v1beta1/{name=projects/*/locations/*/jobs/*}:run:\001*\332A\004name' - ), + serialized_options=b'\202\323\344\223\0026"1/v1beta1/{name=projects/*/locations/*/jobs/*}:run:\001*\332A\004name', + create_key=_descriptor._internal_create_key, ), ], ) diff --git a/google/cloud/scheduler_v1beta1/proto/job_pb2.py b/google/cloud/scheduler_v1beta1/proto/job_pb2.py index 171aff15..3372aeaa 100644 --- a/google/cloud/scheduler_v1beta1/proto/job_pb2.py +++ b/google/cloud/scheduler_v1beta1/proto/job_pb2.py @@ -2,9 +2,6 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/scheduler_v1beta1/proto/job.proto -import sys - -_b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection @@ -29,12 +26,9 @@ name="google/cloud/scheduler_v1beta1/proto/job.proto", package="google.cloud.scheduler.v1beta1", syntax="proto3", - serialized_options=_b( - '\n"com.google.cloud.scheduler.v1beta1B\010JobProtoP\001ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler' - ), - serialized_pb=_b( - '\n.google/cloud/scheduler_v1beta1/proto/job.proto\x12\x1egoogle.cloud.scheduler.v1beta1\x1a\x19google/api/resource.proto\x1a\x31google/cloud/scheduler_v1beta1/proto/target.proto\x1a\x1egoogle/protobuf/duration.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17google/rpc/status.proto\x1a\x1cgoogle/api/annotations.proto"\xe4\x06\n\x03Job\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x02 \x01(\t\x12\x45\n\rpubsub_target\x18\x04 \x01(\x0b\x32,.google.cloud.scheduler.v1beta1.PubsubTargetH\x00\x12U\n\x16\x61pp_engine_http_target\x18\x05 \x01(\x0b\x32\x33.google.cloud.scheduler.v1beta1.AppEngineHttpTargetH\x00\x12\x41\n\x0bhttp_target\x18\x06 \x01(\x0b\x32*.google.cloud.scheduler.v1beta1.HttpTargetH\x00\x12\x10\n\x08schedule\x18\x14 \x01(\t\x12\x11\n\ttime_zone\x18\x15 \x01(\t\x12\x34\n\x10user_update_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x38\n\x05state\x18\n \x01(\x0e\x32).google.cloud.scheduler.v1beta1.Job.State\x12"\n\x06status\x18\x0b \x01(\x0b\x32\x12.google.rpc.Status\x12\x31\n\rschedule_time\x18\x11 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x35\n\x11last_attempt_time\x18\x12 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x41\n\x0cretry_config\x18\x13 \x01(\x0b\x32+.google.cloud.scheduler.v1beta1.RetryConfig\x12\x33\n\x10\x61ttempt_deadline\x18\x16 \x01(\x0b\x32\x19.google.protobuf.Duration"X\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x0b\n\x07\x45NABLED\x10\x01\x12\n\n\x06PAUSED\x10\x02\x12\x0c\n\x08\x44ISABLED\x10\x03\x12\x11\n\rUPDATE_FAILED\x10\x04:Z\xea\x41W\n!cloudscheduler.googleapis.com/Job\x12\x32projects/{project}/locations/{location}/jobs/{job}B\x08\n\x06target"\xe2\x01\n\x0bRetryConfig\x12\x13\n\x0bretry_count\x18\x01 \x01(\x05\x12\x35\n\x12max_retry_duration\x18\x02 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14min_backoff_duration\x18\x03 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14max_backoff_duration\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x15\n\rmax_doublings\x18\x05 \x01(\x05\x42y\n"com.google.cloud.scheduler.v1beta1B\x08JobProtoP\x01ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;schedulerb\x06proto3' - ), + serialized_options=b'\n"com.google.cloud.scheduler.v1beta1B\010JobProtoP\001ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler', + create_key=_descriptor._internal_create_key, + serialized_pb=b'\n.google/cloud/scheduler_v1beta1/proto/job.proto\x12\x1egoogle.cloud.scheduler.v1beta1\x1a\x19google/api/resource.proto\x1a\x31google/cloud/scheduler_v1beta1/proto/target.proto\x1a\x1egoogle/protobuf/duration.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17google/rpc/status.proto\x1a\x1cgoogle/api/annotations.proto"\xe4\x06\n\x03Job\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x02 \x01(\t\x12\x45\n\rpubsub_target\x18\x04 \x01(\x0b\x32,.google.cloud.scheduler.v1beta1.PubsubTargetH\x00\x12U\n\x16\x61pp_engine_http_target\x18\x05 \x01(\x0b\x32\x33.google.cloud.scheduler.v1beta1.AppEngineHttpTargetH\x00\x12\x41\n\x0bhttp_target\x18\x06 \x01(\x0b\x32*.google.cloud.scheduler.v1beta1.HttpTargetH\x00\x12\x10\n\x08schedule\x18\x14 \x01(\t\x12\x11\n\ttime_zone\x18\x15 \x01(\t\x12\x34\n\x10user_update_time\x18\t \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x38\n\x05state\x18\n \x01(\x0e\x32).google.cloud.scheduler.v1beta1.Job.State\x12"\n\x06status\x18\x0b \x01(\x0b\x32\x12.google.rpc.Status\x12\x31\n\rschedule_time\x18\x11 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x35\n\x11last_attempt_time\x18\x12 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x41\n\x0cretry_config\x18\x13 \x01(\x0b\x32+.google.cloud.scheduler.v1beta1.RetryConfig\x12\x33\n\x10\x61ttempt_deadline\x18\x16 \x01(\x0b\x32\x19.google.protobuf.Duration"X\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x0b\n\x07\x45NABLED\x10\x01\x12\n\n\x06PAUSED\x10\x02\x12\x0c\n\x08\x44ISABLED\x10\x03\x12\x11\n\rUPDATE_FAILED\x10\x04:Z\xea\x41W\n!cloudscheduler.googleapis.com/Job\x12\x32projects/{project}/locations/{location}/jobs/{job}B\x08\n\x06target"\xe2\x01\n\x0bRetryConfig\x12\x13\n\x0bretry_count\x18\x01 \x01(\x05\x12\x35\n\x12max_retry_duration\x18\x02 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14min_backoff_duration\x18\x03 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x37\n\x14max_backoff_duration\x18\x04 \x01(\x0b\x32\x19.google.protobuf.Duration\x12\x15\n\rmax_doublings\x18\x05 \x01(\x05\x42y\n"com.google.cloud.scheduler.v1beta1B\x08JobProtoP\x01ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;schedulerb\x06proto3', dependencies=[ google_dot_api_dot_resource__pb2.DESCRIPTOR, google_dot_cloud_dot_scheduler__v1beta1_dot_proto_dot_target__pb2.DESCRIPTOR, @@ -51,6 +45,7 @@ full_name="google.cloud.scheduler.v1beta1.Job.State", filename=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, values=[ _descriptor.EnumValueDescriptor( name="STATE_UNSPECIFIED", @@ -58,18 +53,39 @@ number=0, serialized_options=None, type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="ENABLED", index=1, number=1, serialized_options=None, type=None + name="ENABLED", + index=1, + number=1, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="PAUSED", index=2, number=2, serialized_options=None, type=None + name="PAUSED", + index=2, + number=2, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="DISABLED", index=3, number=3, serialized_options=None, type=None + name="DISABLED", + index=3, + number=3, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="UPDATE_FAILED", index=4, number=4, serialized_options=None, type=None + name="UPDATE_FAILED", + index=4, + number=4, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), ], containing_type=None, @@ -86,6 +102,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="name", @@ -96,7 +113,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -104,6 +121,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="description", @@ -114,7 +132,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -122,6 +140,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="pubsub_target", @@ -140,6 +159,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="app_engine_http_target", @@ -158,6 +178,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="http_target", @@ -176,6 +197,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="schedule", @@ -186,7 +208,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -194,6 +216,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="time_zone", @@ -204,7 +227,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -212,6 +235,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="user_update_time", @@ -230,6 +254,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="state", @@ -248,6 +273,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="status", @@ -266,6 +292,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="schedule_time", @@ -284,6 +311,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="last_attempt_time", @@ -302,6 +330,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="retry_config", @@ -320,6 +349,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="attempt_deadline", @@ -338,14 +368,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], - enum_types=[_JOB_STATE], - serialized_options=_b( - "\352AW\n!cloudscheduler.googleapis.com/Job\0222projects/{project}/locations/{location}/jobs/{job}" - ), + enum_types=[_JOB_STATE,], + serialized_options=b"\352AW\n!cloudscheduler.googleapis.com/Job\0222projects/{project}/locations/{location}/jobs/{job}", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -355,8 +384,9 @@ full_name="google.cloud.scheduler.v1beta1.Job.target", index=0, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[], - ) + ), ], serialized_start=281, serialized_end=1149, @@ -369,6 +399,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="retry_count", @@ -387,6 +418,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="max_retry_duration", @@ -405,6 +437,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="min_backoff_duration", @@ -423,6 +456,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="max_backoff_duration", @@ -441,6 +475,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="max_doublings", @@ -459,6 +494,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -530,10 +566,11 @@ Job = _reflection.GeneratedProtocolMessageType( "Job", (_message.Message,), - dict( - DESCRIPTOR=_JOB, - __module__="google.cloud.scheduler_v1beta1.proto.job_pb2", - __doc__="""Configuration for a job. The maximum allowed size for a job is 100KB. + { + "DESCRIPTOR": _JOB, + "__module__": "google.cloud.scheduler_v1beta1.proto.job_pb2", + "__doc__": """Configuration for a job. The maximum allowed size for a job is 100KB. + Attributes: name: Optionally caller-specified in [CreateJob][google.cloud.schedu @@ -545,13 +582,13 @@ information, see `Identifying projects `__ - ``LOCATION_ID`` - is the canonical ID for the job's location. The list of + is the canonical ID for the job’s location. The list of available locations can be obtained by calling [ListLocatio ns][google.cloud.location.Locations.ListLocations]. For more information, see https://cloud.google.com/about/locations/. - ``JOB_ID`` can contain only letters ([A-Za-z]), numbers ([0-9]), hyphens - (-), or underscores (\_). The maximum length is 500 + (-), or underscores (_). The maximum length is 500 characters. description: Optionally caller-specified in [CreateJob][google.cloud.schedu @@ -584,10 +621,10 @@ execution takes until 16:15, the ``n+1``\ th execution will not start until ``16:15``. A scheduled start time will be delayed if the previous execution has not ended when its - scheduled time occurs. If [retry\_count][google.cloud.schedul - er.v1beta1.RetryConfig.retry\_count] > 0 and a job attempt - fails, the job will be tried a total of [retry\_count][google. - cloud.scheduler.v1beta1.RetryConfig.retry\_count] times, with + scheduled time occurs. If [retry_count][google.cloud.schedule + r.v1beta1.RetryConfig.retry_count] > 0 and a job attempt + fails, the job will be tried a total of [retry_count][google.c + loud.scheduler.v1beta1.RetryConfig.retry_count] times, with exponential backoff, until the next scheduled start time. time_zone: Specifies the time zone to be used in interpreting @@ -596,7 +633,7 @@ database `__. Note that some time zones include a provision for daylight savings time. The rules for daylight saving time are determined by the - chosen tz. For UTC use the string "utc". If a time zone is not + chosen tz. For UTC use the string “utc”. If a time zone is not specified, the default will be in UTC (also known as GMT). user_update_time: Output only. The creation time of the job. @@ -621,50 +658,50 @@ Scheduler will retry the job according to the [RetryConfig][google.cloud.scheduler.v1beta1.RetryConfig]. The allowed duration for this deadline is: - For [HTTP - targets][google.cloud.scheduler.v1beta1.Job.http\_target], + targets][google.cloud.scheduler.v1beta1.Job.http_target], between 15 seconds and 30 minutes. - For [App Engine HTTP - targets][google.cloud.scheduler.v1beta1.Job.app\_engine\_http\ - _target], between 15 seconds and 24 hours. - For [PubSub - targets][google.cloud.scheduler.v1beta1.Job.pubsub\_target], + targets][google.cloud.scheduler.v1beta1.Job.app_engine_http_ta + rget], between 15 seconds and 24 hours. - For [PubSub + targets][google.cloud.scheduler.v1beta1.Job.pubsub_target], this field is ignored. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.Job) - ), + }, ) _sym_db.RegisterMessage(Job) RetryConfig = _reflection.GeneratedProtocolMessageType( "RetryConfig", (_message.Message,), - dict( - DESCRIPTOR=_RETRYCONFIG, - __module__="google.cloud.scheduler_v1beta1.proto.job_pb2", - __doc__="""Settings that determine the retry behavior. By default, if a job does + { + "DESCRIPTOR": _RETRYCONFIG, + "__module__": "google.cloud.scheduler_v1beta1.proto.job_pb2", + "__doc__": """Settings that determine the retry behavior. By default, if a job does not complete successfully (meaning that an acknowledgement is not received from the handler, then it will be retried with exponential backoff according to the settings in [RetryConfig][google.cloud.scheduler.v1beta1.RetryConfig]. + Attributes: retry_count: The number of attempts that the system will make to run a job - using the exponential backoff procedure described by [max\_dou - blings][google.cloud.scheduler.v1beta1.RetryConfig.max\_doubli - ngs]. The default value of retry\_count is zero. If - retry\_count is zero, a job attempt will *not* be retried if - it fails. Instead the Cloud Scheduler system will wait for the - next scheduled execution time. If retry\_count is set to a - non-zero number then Cloud Scheduler will retry failed - attempts, using exponential backoff, retry\_count times, or - until the next scheduled execution time, whichever comes - first. Values greater than 5 and negative values are not - allowed. + using the exponential backoff procedure described by [max_doub + lings][google.cloud.scheduler.v1beta1.RetryConfig.max_doubling + s]. The default value of retry_count is zero. If retry_count + is zero, a job attempt will *not* be retried if it fails. + Instead the Cloud Scheduler system will wait for the next + scheduled execution time. If retry_count is set to a non-zero + number then Cloud Scheduler will retry failed attempts, using + exponential backoff, retry_count times, or until the next + scheduled execution time, whichever comes first. Values + greater than 5 and negative values are not allowed. max_retry_duration: The time limit for retrying a failed job, measured from time when an execution was first attempted. If specified with [retr - y\_count][google.cloud.scheduler.v1beta1.RetryConfig.retry\_co - unt], the job will be retried until both limits are reached. - The default value for max\_retry\_duration is zero, which - means retry duration is unlimited. + y_count][google.cloud.scheduler.v1beta1.RetryConfig.retry_coun + t], the job will be retried until both limits are reached. + The default value for max_retry_duration is zero, which means + retry duration is unlimited. min_backoff_duration: The minimum amount of time to wait before retrying a job after it fails. The default value of this field is 5 seconds. @@ -673,28 +710,28 @@ it fails. The default value of this field is 1 hour. max_doublings: The time between retries will double ``max_doublings`` times. - A job's retry interval starts at [min\_backoff\_duration][goog - le.cloud.scheduler.v1beta1.RetryConfig.min\_backoff\_duration] - , then doubles ``max_doublings`` times, then increases - linearly, and finally retries retries at intervals of [max\_ba - ckoff\_duration][google.cloud.scheduler.v1beta1.RetryConfig.ma - x\_backoff\_duration] up to [retry\_count][google.cloud.schedu - ler.v1beta1.RetryConfig.retry\_count] times. For example, if - [min\_backoff\_duration][google.cloud.scheduler.v1beta1.RetryC - onfig.min\_backoff\_duration] is 10s, [max\_backoff\_duration] - [google.cloud.scheduler.v1beta1.RetryConfig.max\_backoff\_dura - tion] is 300s, and ``max_doublings`` is 3, then the a job will - first be retried in 10s. The retry interval will double three - times, and then increase linearly by 2^3 \* 10s. Finally, the - job will retry at intervals of [max\_backoff\_duration][google - .cloud.scheduler.v1beta1.RetryConfig.max\_backoff\_duration] - until the job has been attempted [retry\_count][google.cloud.s - cheduler.v1beta1.RetryConfig.retry\_count] times. Thus, the - requests will retry at 10s, 20s, 40s, 80s, 160s, 240s, 300s, - 300s, .... The default value of this field is 5. + A job’s retry interval starts at [min_backoff_duration][google + .cloud.scheduler.v1beta1.RetryConfig.min_backoff_duration], + then doubles ``max_doublings`` times, then increases linearly, + and finally retries retries at intervals of [max_backoff_durat + ion][google.cloud.scheduler.v1beta1.RetryConfig.max_backoff_du + ration] up to [retry_count][google.cloud.scheduler.v1beta1.Ret + ryConfig.retry_count] times. For example, if [min_backoff_dur + ation][google.cloud.scheduler.v1beta1.RetryConfig.min_backoff\_ + duration] is 10s, [max_backoff_duration][google.cloud.schedule + r.v1beta1.RetryConfig.max_backoff_duration] is 300s, and + ``max_doublings`` is 3, then the a job will first be retried + in 10s. The retry interval will double three times, and then + increase linearly by 2^3 \* 10s. Finally, the job will retry + at intervals of [max_backoff_duration][google.cloud.scheduler. + v1beta1.RetryConfig.max_backoff_duration] until the job has + been attempted [retry_count][google.cloud.scheduler.v1beta1.Re + tryConfig.retry_count] times. Thus, the requests will retry at + 10s, 20s, 40s, 80s, 160s, 240s, 300s, 300s, …. The default + value of this field is 5. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.RetryConfig) - ), + }, ) _sym_db.RegisterMessage(RetryConfig) diff --git a/google/cloud/scheduler_v1beta1/proto/target_pb2.py b/google/cloud/scheduler_v1beta1/proto/target_pb2.py index 3a7d2507..ade391ed 100644 --- a/google/cloud/scheduler_v1beta1/proto/target_pb2.py +++ b/google/cloud/scheduler_v1beta1/proto/target_pb2.py @@ -2,9 +2,6 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/scheduler_v1beta1/proto/target.proto -import sys - -_b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message @@ -24,12 +21,9 @@ name="google/cloud/scheduler_v1beta1/proto/target.proto", package="google.cloud.scheduler.v1beta1", syntax="proto3", - serialized_options=_b( - '\n"com.google.cloud.scheduler.v1beta1B\013TargetProtoP\001ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\352A@\n\033pubsub.googleapis.com/Topic\022!projects/{project}/topics/{topic}' - ), - serialized_pb=_b( - '\n1google/cloud/scheduler_v1beta1/proto/target.proto\x12\x1egoogle.cloud.scheduler.v1beta1\x1a\x19google/api/resource.proto\x1a\x1cgoogle/api/annotations.proto"\xfe\x02\n\nHttpTarget\x12\x0b\n\x03uri\x18\x01 \x01(\t\x12?\n\x0bhttp_method\x18\x02 \x01(\x0e\x32*.google.cloud.scheduler.v1beta1.HttpMethod\x12H\n\x07headers\x18\x03 \x03(\x0b\x32\x37.google.cloud.scheduler.v1beta1.HttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x04 \x01(\x0c\x12\x41\n\x0boauth_token\x18\x05 \x01(\x0b\x32*.google.cloud.scheduler.v1beta1.OAuthTokenH\x00\x12?\n\noidc_token\x18\x06 \x01(\x0b\x32).google.cloud.scheduler.v1beta1.OidcTokenH\x00\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x16\n\x14\x61uthorization_header"\xcb\x02\n\x13\x41ppEngineHttpTarget\x12?\n\x0bhttp_method\x18\x01 \x01(\x0e\x32*.google.cloud.scheduler.v1beta1.HttpMethod\x12L\n\x12\x61pp_engine_routing\x18\x02 \x01(\x0b\x32\x30.google.cloud.scheduler.v1beta1.AppEngineRouting\x12\x14\n\x0crelative_uri\x18\x03 \x01(\t\x12Q\n\x07headers\x18\x04 \x03(\x0b\x32@.google.cloud.scheduler.v1beta1.AppEngineHttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x05 \x01(\x0c\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"\xd7\x01\n\x0cPubsubTarget\x12\x34\n\ntopic_name\x18\x01 \x01(\tB \xfa\x41\x1d\n\x1bpubsub.googleapis.com/Topic\x12\x0c\n\x04\x64\x61ta\x18\x03 \x01(\x0c\x12P\n\nattributes\x18\x04 \x03(\x0b\x32<.google.cloud.scheduler.v1beta1.PubsubTarget.AttributesEntry\x1a\x31\n\x0f\x41ttributesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"T\n\x10\x41ppEngineRouting\x12\x0f\n\x07service\x18\x01 \x01(\t\x12\x0f\n\x07version\x18\x02 \x01(\t\x12\x10\n\x08instance\x18\x03 \x01(\t\x12\x0c\n\x04host\x18\x04 \x01(\t":\n\nOAuthToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\r\n\x05scope\x18\x02 \x01(\t"<\n\tOidcToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\x10\n\x08\x61udience\x18\x02 \x01(\t*s\n\nHttpMethod\x12\x1b\n\x17HTTP_METHOD_UNSPECIFIED\x10\x00\x12\x08\n\x04POST\x10\x01\x12\x07\n\x03GET\x10\x02\x12\x08\n\x04HEAD\x10\x03\x12\x07\n\x03PUT\x10\x04\x12\n\n\x06\x44\x45LETE\x10\x05\x12\t\n\x05PATCH\x10\x06\x12\x0b\n\x07OPTIONS\x10\x07\x42\xbf\x01\n"com.google.cloud.scheduler.v1beta1B\x0bTargetProtoP\x01ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\xea\x41@\n\x1bpubsub.googleapis.com/Topic\x12!projects/{project}/topics/{topic}b\x06proto3' - ), + serialized_options=b'\n"com.google.cloud.scheduler.v1beta1B\013TargetProtoP\001ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\352A@\n\033pubsub.googleapis.com/Topic\022!projects/{project}/topics/{topic}', + create_key=_descriptor._internal_create_key, + serialized_pb=b'\n1google/cloud/scheduler_v1beta1/proto/target.proto\x12\x1egoogle.cloud.scheduler.v1beta1\x1a\x19google/api/resource.proto\x1a\x1cgoogle/api/annotations.proto"\xfe\x02\n\nHttpTarget\x12\x0b\n\x03uri\x18\x01 \x01(\t\x12?\n\x0bhttp_method\x18\x02 \x01(\x0e\x32*.google.cloud.scheduler.v1beta1.HttpMethod\x12H\n\x07headers\x18\x03 \x03(\x0b\x32\x37.google.cloud.scheduler.v1beta1.HttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x04 \x01(\x0c\x12\x41\n\x0boauth_token\x18\x05 \x01(\x0b\x32*.google.cloud.scheduler.v1beta1.OAuthTokenH\x00\x12?\n\noidc_token\x18\x06 \x01(\x0b\x32).google.cloud.scheduler.v1beta1.OidcTokenH\x00\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x16\n\x14\x61uthorization_header"\xcb\x02\n\x13\x41ppEngineHttpTarget\x12?\n\x0bhttp_method\x18\x01 \x01(\x0e\x32*.google.cloud.scheduler.v1beta1.HttpMethod\x12L\n\x12\x61pp_engine_routing\x18\x02 \x01(\x0b\x32\x30.google.cloud.scheduler.v1beta1.AppEngineRouting\x12\x14\n\x0crelative_uri\x18\x03 \x01(\t\x12Q\n\x07headers\x18\x04 \x03(\x0b\x32@.google.cloud.scheduler.v1beta1.AppEngineHttpTarget.HeadersEntry\x12\x0c\n\x04\x62ody\x18\x05 \x01(\x0c\x1a.\n\x0cHeadersEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"\xd7\x01\n\x0cPubsubTarget\x12\x34\n\ntopic_name\x18\x01 \x01(\tB \xfa\x41\x1d\n\x1bpubsub.googleapis.com/Topic\x12\x0c\n\x04\x64\x61ta\x18\x03 \x01(\x0c\x12P\n\nattributes\x18\x04 \x03(\x0b\x32<.google.cloud.scheduler.v1beta1.PubsubTarget.AttributesEntry\x1a\x31\n\x0f\x41ttributesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01"T\n\x10\x41ppEngineRouting\x12\x0f\n\x07service\x18\x01 \x01(\t\x12\x0f\n\x07version\x18\x02 \x01(\t\x12\x10\n\x08instance\x18\x03 \x01(\t\x12\x0c\n\x04host\x18\x04 \x01(\t":\n\nOAuthToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\r\n\x05scope\x18\x02 \x01(\t"<\n\tOidcToken\x12\x1d\n\x15service_account_email\x18\x01 \x01(\t\x12\x10\n\x08\x61udience\x18\x02 \x01(\t*s\n\nHttpMethod\x12\x1b\n\x17HTTP_METHOD_UNSPECIFIED\x10\x00\x12\x08\n\x04POST\x10\x01\x12\x07\n\x03GET\x10\x02\x12\x08\n\x04HEAD\x10\x03\x12\x07\n\x03PUT\x10\x04\x12\n\n\x06\x44\x45LETE\x10\x05\x12\t\n\x05PATCH\x10\x06\x12\x0b\n\x07OPTIONS\x10\x07\x42\xbf\x01\n"com.google.cloud.scheduler.v1beta1B\x0bTargetProtoP\x01ZGgoogle.golang.org/genproto/googleapis/cloud/scheduler/v1beta1;scheduler\xea\x41@\n\x1bpubsub.googleapis.com/Topic\x12!projects/{project}/topics/{topic}b\x06proto3', dependencies=[ google_dot_api_dot_resource__pb2.DESCRIPTOR, google_dot_api_dot_annotations__pb2.DESCRIPTOR, @@ -41,6 +35,7 @@ full_name="google.cloud.scheduler.v1beta1.HttpMethod", filename=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, values=[ _descriptor.EnumValueDescriptor( name="HTTP_METHOD_UNSPECIFIED", @@ -48,27 +43,63 @@ number=0, serialized_options=None, type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="POST", index=1, number=1, serialized_options=None, type=None + name="POST", + index=1, + number=1, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="GET", index=2, number=2, serialized_options=None, type=None + name="GET", + index=2, + number=2, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="HEAD", index=3, number=3, serialized_options=None, type=None + name="HEAD", + index=3, + number=3, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="PUT", index=4, number=4, serialized_options=None, type=None + name="PUT", + index=4, + number=4, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="DELETE", index=5, number=5, serialized_options=None, type=None + name="DELETE", + index=5, + number=5, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="PATCH", index=6, number=6, serialized_options=None, type=None + name="PATCH", + index=6, + number=6, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), _descriptor.EnumValueDescriptor( - name="OPTIONS", index=7, number=7, serialized_options=None, type=None + name="OPTIONS", + index=7, + number=7, + serialized_options=None, + type=None, + create_key=_descriptor._internal_create_key, ), ], containing_type=None, @@ -95,6 +126,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="key", @@ -105,7 +137,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -113,6 +145,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="value", @@ -123,7 +156,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -131,12 +164,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], enum_types=[], - serialized_options=_b("8\001"), + serialized_options=b"8\001", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -151,6 +185,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="uri", @@ -161,7 +196,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -169,6 +204,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="http_method", @@ -187,6 +223,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="headers", @@ -205,6 +242,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="body", @@ -215,7 +253,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b(""), + default_value=b"", message_type=None, enum_type=None, containing_type=None, @@ -223,6 +261,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="oauth_token", @@ -241,6 +280,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="oidc_token", @@ -259,10 +299,11 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], - nested_types=[_HTTPTARGET_HEADERSENTRY], + nested_types=[_HTTPTARGET_HEADERSENTRY,], enum_types=[], serialized_options=None, is_extendable=False, @@ -274,8 +315,9 @@ full_name="google.cloud.scheduler.v1beta1.HttpTarget.authorization_header", index=0, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[], - ) + ), ], serialized_start=143, serialized_end=525, @@ -288,6 +330,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="key", @@ -298,7 +341,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -306,6 +349,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="value", @@ -316,7 +360,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -324,12 +368,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], enum_types=[], - serialized_options=_b("8\001"), + serialized_options=b"8\001", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -344,6 +389,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="http_method", @@ -362,6 +408,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="app_engine_routing", @@ -380,6 +427,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="relative_uri", @@ -390,7 +438,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -398,6 +446,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="headers", @@ -416,6 +465,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="body", @@ -426,7 +476,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b(""), + default_value=b"", message_type=None, enum_type=None, containing_type=None, @@ -434,10 +484,11 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], - nested_types=[_APPENGINEHTTPTARGET_HEADERSENTRY], + nested_types=[_APPENGINEHTTPTARGET_HEADERSENTRY,], enum_types=[], serialized_options=None, is_extendable=False, @@ -455,6 +506,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="key", @@ -465,7 +517,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -473,6 +525,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="value", @@ -483,7 +536,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -491,12 +544,13 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], nested_types=[], enum_types=[], - serialized_options=_b("8\001"), + serialized_options=b"8\001", is_extendable=False, syntax="proto3", extension_ranges=[], @@ -511,6 +565,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="topic_name", @@ -521,14 +576,15 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, - serialized_options=_b("\372A\035\n\033pubsub.googleapis.com/Topic"), + serialized_options=b"\372A\035\n\033pubsub.googleapis.com/Topic", file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="data", @@ -539,7 +595,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b(""), + default_value=b"", message_type=None, enum_type=None, containing_type=None, @@ -547,6 +603,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="attributes", @@ -565,10 +622,11 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], - nested_types=[_PUBSUBTARGET_ATTRIBUTESENTRY], + nested_types=[_PUBSUBTARGET_ATTRIBUTESENTRY,], enum_types=[], serialized_options=None, is_extendable=False, @@ -586,6 +644,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="service", @@ -596,7 +655,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -604,6 +663,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="version", @@ -614,7 +674,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -622,6 +682,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="instance", @@ -632,7 +693,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -640,6 +701,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="host", @@ -650,7 +712,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -658,6 +720,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -679,6 +742,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="service_account_email", @@ -689,7 +753,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -697,6 +761,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="scope", @@ -707,7 +772,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -715,6 +780,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -736,6 +802,7 @@ filename=None, file=DESCRIPTOR, containing_type=None, + create_key=_descriptor._internal_create_key, fields=[ _descriptor.FieldDescriptor( name="service_account_email", @@ -746,7 +813,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -754,6 +821,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), _descriptor.FieldDescriptor( name="audience", @@ -764,7 +832,7 @@ cpp_type=9, label=1, has_default_value=False, - default_value=_b("").decode("utf-8"), + default_value=b"".decode("utf-8"), message_type=None, enum_type=None, containing_type=None, @@ -772,6 +840,7 @@ extension_scope=None, serialized_options=None, file=DESCRIPTOR, + create_key=_descriptor._internal_create_key, ), ], extensions=[], @@ -825,29 +894,30 @@ HttpTarget = _reflection.GeneratedProtocolMessageType( "HttpTarget", (_message.Message,), - dict( - HeadersEntry=_reflection.GeneratedProtocolMessageType( + { + "HeadersEntry": _reflection.GeneratedProtocolMessageType( "HeadersEntry", (_message.Message,), - dict( - DESCRIPTOR=_HTTPTARGET_HEADERSENTRY, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2" + { + "DESCRIPTOR": _HTTPTARGET_HEADERSENTRY, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2" # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.HttpTarget.HeadersEntry) - ), + }, ), - DESCRIPTOR=_HTTPTARGET, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2", - __doc__="""Http target. The job will be pushed to the job handler by means of an + "DESCRIPTOR": _HTTPTARGET, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2", + "__doc__": """Http target. The job will be pushed to the job handler by means of an HTTP request via an - [http\_method][google.cloud.scheduler.v1beta1.HttpTarget.http\_method] + [http_method][google.cloud.scheduler.v1beta1.HttpTarget.http_method] such as HTTP POST, HTTP GET, etc. The job is acknowledged by means of an HTTP response code in the range [200 - 299]. A failure to receive a response constitutes a failed execution. For a redirected request, the response returned by the redirected request is considered. + Attributes: uri: Required. The full URI path that the request will be sent to. - This string must begin with either "http://" or "https://". + This string must begin with either “http://” or “https://”. Some examples of valid values for [uri][google.cloud.scheduler.v1beta1.HttpTarget.uri] are: ``http://acme.com`` and ``https://acme.com/sales:8080``. Cloud @@ -858,10 +928,10 @@ Which HTTP method to use for the request. headers: The user can specify HTTP request headers to send with the - job's HTTP request. This map contains the header field names + job’s HTTP request. This map contains the header field names and values. Repeated headers are not supported, but a header value can contain commas. These headers represent a subset of - the headers that will accompany the job's HTTP request. Some + the headers that will accompany the job’s HTTP request. Some HTTP request headers will be ignored or replaced. A partial list of headers that will be ignored or replaced is below: - Host: This will be computed by Cloud Scheduler and derived @@ -883,7 +953,7 @@ .headers] field will be overridden. oauth_token: If specified, an `OAuth token - `__ + `_\_ will be generated and attached as an ``Authorization`` header in the HTTP request. This type of authorization should generally only be used when calling Google APIs hosted on @@ -897,7 +967,7 @@ validate the token yourself. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.HttpTarget) - ), + }, ) _sym_db.RegisterMessage(HttpTarget) _sym_db.RegisterMessage(HttpTarget.HeadersEntry) @@ -905,27 +975,28 @@ AppEngineHttpTarget = _reflection.GeneratedProtocolMessageType( "AppEngineHttpTarget", (_message.Message,), - dict( - HeadersEntry=_reflection.GeneratedProtocolMessageType( + { + "HeadersEntry": _reflection.GeneratedProtocolMessageType( "HeadersEntry", (_message.Message,), - dict( - DESCRIPTOR=_APPENGINEHTTPTARGET_HEADERSENTRY, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2" + { + "DESCRIPTOR": _APPENGINEHTTPTARGET_HEADERSENTRY, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2" # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.AppEngineHttpTarget.HeadersEntry) - ), + }, ), - DESCRIPTOR=_APPENGINEHTTPTARGET, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2", - __doc__="""App Engine target. The job will be pushed to a job handler by means of - an HTTP request via an [http\_method][google.cloud.scheduler.v1beta1.A - ppEngineHttpTarget.http\_method] such as HTTP POST, HTTP GET, etc. The + "DESCRIPTOR": _APPENGINEHTTPTARGET, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2", + "__doc__": """App Engine target. The job will be pushed to a job handler by means of + an HTTP request via an [http_method][google.cloud.scheduler.v1beta1.Ap + pEngineHttpTarget.http_method] such as HTTP POST, HTTP GET, etc. The job is acknowledged by means of an HTTP response code in the range [200 - 299]. Error 503 is considered an App Engine system error instead of an application error. Requests returning error 503 will be retried regardless of retry configuration and not counted against retry counts. Any other response code, or a failure to receive a response before the deadline, constitutes a failed attempt. + Attributes: http_method: The HTTP method to use for the request. PATCH and OPTIONS are @@ -933,10 +1004,10 @@ app_engine_routing: App Engine Routing setting for the job. relative_uri: - The relative URI. The relative URL must begin with "/" and + The relative URI. The relative URL must begin with “/” and must be a valid HTTP relative URL. It can contain a path, query string arguments, and ``#`` fragments. If the relative - URL is empty, then the root path "/" will be used. No spaces + URL is empty, then the root path “/” will be used. No spaces are allowed, and the maximum length allowed is 2083 characters. headers: @@ -970,7 +1041,7 @@ [HttpMethod][google.cloud.scheduler.v1beta1.HttpMethod]. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.AppEngineHttpTarget) - ), + }, ) _sym_db.RegisterMessage(AppEngineHttpTarget) _sym_db.RegisterMessage(AppEngineHttpTarget.HeadersEntry) @@ -978,25 +1049,26 @@ PubsubTarget = _reflection.GeneratedProtocolMessageType( "PubsubTarget", (_message.Message,), - dict( - AttributesEntry=_reflection.GeneratedProtocolMessageType( + { + "AttributesEntry": _reflection.GeneratedProtocolMessageType( "AttributesEntry", (_message.Message,), - dict( - DESCRIPTOR=_PUBSUBTARGET_ATTRIBUTESENTRY, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2" + { + "DESCRIPTOR": _PUBSUBTARGET_ATTRIBUTESENTRY, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2" # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.PubsubTarget.AttributesEntry) - ), + }, ), - DESCRIPTOR=_PUBSUBTARGET, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2", - __doc__="""Pub/Sub target. The job will be delivered by publishing a message to + "DESCRIPTOR": _PUBSUBTARGET, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2", + "__doc__": """Pub/Sub target. The job will be delivered by publishing a message to the given Pub/Sub topic. + Attributes: topic_name: Required. The name of the Cloud Pub/Sub topic to which messages will be published when a job is delivered. The topic - name must be in the same format as required by PubSub's + name must be in the same format as required by PubSub’s `PublishRequest.name `__, for example ``projects/PROJECT_ID/topics/TOPIC_ID``. The topic must be in @@ -1009,7 +1081,7 @@ either non-empty data, or at least one attribute. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.PubsubTarget) - ), + }, ) _sym_db.RegisterMessage(PubsubTarget) _sym_db.RegisterMessage(PubsubTarget.AttributesEntry) @@ -1017,10 +1089,10 @@ AppEngineRouting = _reflection.GeneratedProtocolMessageType( "AppEngineRouting", (_message.Message,), - dict( - DESCRIPTOR=_APPENGINEROUTING, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2", - __doc__="""App Engine Routing. For more information about services, versions, + { + "DESCRIPTOR": _APPENGINEROUTING, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2", + "__doc__": """App Engine Routing. For more information about services, versions, and instances see `An Overview of App Engine `__, `Microservices Architecture on Google App Engine @@ -1030,6 +1102,7 @@ are-routed>`__, and `App Engine Flex request routing `__. + Attributes: service: App service. By default, the job is sent to the service which @@ -1066,7 +1139,7 @@ ``| [instance_dot_version_dot_service] + '.' + [application_domain_name]`` - ``application_domain_name`` = The domain name of the app, for example .appspot.com, which - is associated with the job's project ID. - ``service =`` + is associated with the job’s project ID. - ``service =`` [service][google.cloud.scheduler.v1beta1.AppEngineRouting.serv ice] - ``version =`` [version][google.cloud.scheduler.v1b eta1.AppEngineRouting.version] - ``version_dot_service =`` @@ -1101,20 +1174,21 @@ when the job is attempted. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.AppEngineRouting) - ), + }, ) _sym_db.RegisterMessage(AppEngineRouting) OAuthToken = _reflection.GeneratedProtocolMessageType( "OAuthToken", (_message.Message,), - dict( - DESCRIPTOR=_OAUTHTOKEN, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2", - __doc__="""Contains information needed for generating an `OAuth token + { + "DESCRIPTOR": _OAUTHTOKEN, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2", + "__doc__": """Contains information needed for generating an `OAuth token `__. This type of authorization should generally only be used when calling Google APIs hosted on \*.googleapis.com. + Attributes: service_account_email: \ `Service account email @@ -1124,25 +1198,26 @@ iam.serviceAccounts.actAs permission for the service account. scope: OAuth scope to be used for generating OAuth access token. If - not specified, "https://www.googleapis.com/auth/cloud- - platform" will be used. + not specified, “https://www.googleapis.com/auth/cloud- + platform” will be used. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.OAuthToken) - ), + }, ) _sym_db.RegisterMessage(OAuthToken) OidcToken = _reflection.GeneratedProtocolMessageType( "OidcToken", (_message.Message,), - dict( - DESCRIPTOR=_OIDCTOKEN, - __module__="google.cloud.scheduler_v1beta1.proto.target_pb2", - __doc__="""Contains information needed for generating an `OpenID Connect token + { + "DESCRIPTOR": _OIDCTOKEN, + "__module__": "google.cloud.scheduler_v1beta1.proto.target_pb2", + "__doc__": """Contains information needed for generating an `OpenID Connect token `__. This type of authorization can be used for many scenarios, including calling Cloud Run, or endpoints where you intend to validate the token yourself. + Attributes: service_account_email: \ `Service account email @@ -1155,7 +1230,7 @@ specified, the URI specified in target will be used. """, # @@protoc_insertion_point(class_scope:google.cloud.scheduler.v1beta1.OidcToken) - ), + }, ) _sym_db.RegisterMessage(OidcToken) diff --git a/google/cloud/scheduler_v1beta1/types.py b/google/cloud/scheduler_v1beta1/types.py index a4e9f480..3bce87ae 100644 --- a/google/cloud/scheduler_v1beta1/types.py +++ b/google/cloud/scheduler_v1beta1/types.py @@ -40,7 +40,11 @@ status_pb2, ] -_local_modules = [cloudscheduler_pb2, job_pb2, target_pb2] +_local_modules = [ + cloudscheduler_pb2, + job_pb2, + target_pb2, +] names = [] diff --git a/noxfile.py b/noxfile.py index aa9f3c77..b492282a 100644 --- a/noxfile.py +++ b/noxfile.py @@ -23,14 +23,15 @@ import nox -BLACK_VERSION = "black==19.3b0" +BLACK_VERSION = "black==19.10b0" BLACK_PATHS = ["docs", "google", "tests", "noxfile.py", "setup.py"] -if os.path.exists("samples"): - BLACK_PATHS.append("samples") +DEFAULT_PYTHON_VERSION = "3.8" +SYSTEM_TEST_PYTHON_VERSIONS = ["2.7", "3.8"] +UNIT_TEST_PYTHON_VERSIONS = ["2.7", "3.5", "3.6", "3.7", "3.8"] -@nox.session(python="3.7") +@nox.session(python=DEFAULT_PYTHON_VERSION) def lint(session): """Run linters. @@ -38,7 +39,9 @@ def lint(session): serious code quality issues. """ session.install("flake8", BLACK_VERSION) - session.run("black", "--check", *BLACK_PATHS) + session.run( + "black", "--check", *BLACK_PATHS, + ) session.run("flake8", "google", "tests") @@ -53,10 +56,12 @@ def blacken(session): check the state of the `gcp_ubuntu_config` we use for that Kokoro run. """ session.install(BLACK_VERSION) - session.run("black", *BLACK_PATHS) + session.run( + "black", *BLACK_PATHS, + ) -@nox.session(python="3.7") +@nox.session(python=DEFAULT_PYTHON_VERSION) def lint_setup_py(session): """Verify that setup.py is valid (including RST check).""" session.install("docutils", "pygments") @@ -84,13 +89,13 @@ def default(session): ) -@nox.session(python=["2.7", "3.5", "3.6", "3.7", "3.8"]) +@nox.session(python=UNIT_TEST_PYTHON_VERSIONS) def unit(session): """Run the unit test suite.""" default(session) -@nox.session(python=["2.7", "3.7"]) +@nox.session(python=SYSTEM_TEST_PYTHON_VERSIONS) def system(session): """Run the system test suite.""" system_test_path = os.path.join("tests", "system.py") @@ -110,8 +115,9 @@ def system(session): # Install all test dependencies, then install this package into the # virtualenv's dist-packages. - session.install("mock", "pytest") - session.install("git+https://github.com/googleapis/python-test-utils") + session.install( + "mock", "pytest", "google-cloud-testutils", + ) session.install("-e", ".") # Run py.test against the system tests. @@ -121,7 +127,7 @@ def system(session): session.run("py.test", "--quiet", system_test_folder_path, *session.posargs) -@nox.session(python="3.7") +@nox.session(python=DEFAULT_PYTHON_VERSION) def cover(session): """Run the final coverage report. @@ -134,7 +140,7 @@ def cover(session): session.run("coverage", "erase") -@nox.session(python="3.7") +@nox.session(python=DEFAULT_PYTHON_VERSION) def docs(session): """Build the docs for this library.""" diff --git a/scripts/decrypt-secrets.sh b/scripts/decrypt-secrets.sh new file mode 100755 index 00000000..ff599eb2 --- /dev/null +++ b/scripts/decrypt-secrets.sh @@ -0,0 +1,33 @@ +#!/bin/bash + +# Copyright 2015 Google Inc. All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +ROOT=$( dirname "$DIR" ) + +# Work from the project root. +cd $ROOT + +# Use SECRET_MANAGER_PROJECT if set, fallback to cloud-devrel-kokoro-resources. +PROJECT_ID="${SECRET_MANAGER_PROJECT:-cloud-devrel-kokoro-resources}" + +gcloud secrets versions access latest --secret="python-docs-samples-test-env" \ + > testing/test-env.sh +gcloud secrets versions access latest \ + --secret="python-docs-samples-service-account" \ + > testing/service-account.json +gcloud secrets versions access latest \ + --secret="python-docs-samples-client-secrets" \ + > testing/client-secrets.json \ No newline at end of file diff --git a/scripts/readme-gen/readme_gen.py b/scripts/readme-gen/readme_gen.py new file mode 100644 index 00000000..d309d6e9 --- /dev/null +++ b/scripts/readme-gen/readme_gen.py @@ -0,0 +1,66 @@ +#!/usr/bin/env python + +# Copyright 2016 Google Inc +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Generates READMEs using configuration defined in yaml.""" + +import argparse +import io +import os +import subprocess + +import jinja2 +import yaml + + +jinja_env = jinja2.Environment( + trim_blocks=True, + loader=jinja2.FileSystemLoader( + os.path.abspath(os.path.join(os.path.dirname(__file__), 'templates')))) + +README_TMPL = jinja_env.get_template('README.tmpl.rst') + + +def get_help(file): + return subprocess.check_output(['python', file, '--help']).decode() + + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('source') + parser.add_argument('--destination', default='README.rst') + + args = parser.parse_args() + + source = os.path.abspath(args.source) + root = os.path.dirname(source) + destination = os.path.join(root, args.destination) + + jinja_env.globals['get_help'] = get_help + + with io.open(source, 'r') as f: + config = yaml.load(f) + + # This allows get_help to execute in the right directory. + os.chdir(root) + + output = README_TMPL.render(config) + + with io.open(destination, 'w') as f: + f.write(output) + + +if __name__ == '__main__': + main() diff --git a/scripts/readme-gen/templates/README.tmpl.rst b/scripts/readme-gen/templates/README.tmpl.rst new file mode 100644 index 00000000..4fd23976 --- /dev/null +++ b/scripts/readme-gen/templates/README.tmpl.rst @@ -0,0 +1,87 @@ +{# The following line is a lie. BUT! Once jinja2 is done with it, it will + become truth! #} +.. This file is automatically generated. Do not edit this file directly. + +{{product.name}} Python Samples +=============================================================================== + +.. image:: https://gstatic.com/cloudssh/images/open-btn.png + :target: https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/GoogleCloudPlatform/python-docs-samples&page=editor&open_in_editor={{folder}}/README.rst + + +This directory contains samples for {{product.name}}. {{product.description}} + +{{description}} + +.. _{{product.name}}: {{product.url}} + +{% if required_api_url %} +To run the sample, you need to enable the API at: {{required_api_url}} +{% endif %} + +{% if required_role %} +To run the sample, you need to have `{{required_role}}` role. +{% endif %} + +{{other_required_steps}} + +{% if setup %} +Setup +------------------------------------------------------------------------------- + +{% for section in setup %} + +{% include section + '.tmpl.rst' %} + +{% endfor %} +{% endif %} + +{% if samples %} +Samples +------------------------------------------------------------------------------- + +{% for sample in samples %} +{{sample.name}} ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + +{% if not sample.hide_cloudshell_button %} +.. image:: https://gstatic.com/cloudssh/images/open-btn.png + :target: https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/GoogleCloudPlatform/python-docs-samples&page=editor&open_in_editor={{folder}}/{{sample.file}},{{folder}}/README.rst +{% endif %} + + +{{sample.description}} + +To run this sample: + +.. code-block:: bash + + $ python {{sample.file}} +{% if sample.show_help %} + + {{get_help(sample.file)|indent}} +{% endif %} + + +{% endfor %} +{% endif %} + +{% if cloud_client_library %} + +The client library +------------------------------------------------------------------------------- + +This sample uses the `Google Cloud Client Library for Python`_. +You can read the documentation for more details on API usage and use GitHub +to `browse the source`_ and `report issues`_. + +.. _Google Cloud Client Library for Python: + https://googlecloudplatform.github.io/google-cloud-python/ +.. _browse the source: + https://github.com/GoogleCloudPlatform/google-cloud-python +.. _report issues: + https://github.com/GoogleCloudPlatform/google-cloud-python/issues + +{% endif %} + +.. _Google Cloud SDK: https://cloud.google.com/sdk/ \ No newline at end of file diff --git a/scripts/readme-gen/templates/auth.tmpl.rst b/scripts/readme-gen/templates/auth.tmpl.rst new file mode 100644 index 00000000..1446b94a --- /dev/null +++ b/scripts/readme-gen/templates/auth.tmpl.rst @@ -0,0 +1,9 @@ +Authentication +++++++++++++++ + +This sample requires you to have authentication setup. Refer to the +`Authentication Getting Started Guide`_ for instructions on setting up +credentials for applications. + +.. _Authentication Getting Started Guide: + https://cloud.google.com/docs/authentication/getting-started diff --git a/scripts/readme-gen/templates/auth_api_key.tmpl.rst b/scripts/readme-gen/templates/auth_api_key.tmpl.rst new file mode 100644 index 00000000..11957ce2 --- /dev/null +++ b/scripts/readme-gen/templates/auth_api_key.tmpl.rst @@ -0,0 +1,14 @@ +Authentication +++++++++++++++ + +Authentication for this service is done via an `API Key`_. To obtain an API +Key: + +1. Open the `Cloud Platform Console`_ +2. Make sure that billing is enabled for your project. +3. From the **Credentials** page, create a new **API Key** or use an existing + one for your project. + +.. _API Key: + https://developers.google.com/api-client-library/python/guide/aaa_apikeys +.. _Cloud Console: https://console.cloud.google.com/project?_ diff --git a/scripts/readme-gen/templates/install_deps.tmpl.rst b/scripts/readme-gen/templates/install_deps.tmpl.rst new file mode 100644 index 00000000..a0406dba --- /dev/null +++ b/scripts/readme-gen/templates/install_deps.tmpl.rst @@ -0,0 +1,29 @@ +Install Dependencies +++++++++++++++++++++ + +#. Clone python-docs-samples and change directory to the sample directory you want to use. + + .. code-block:: bash + + $ git clone https://github.com/GoogleCloudPlatform/python-docs-samples.git + +#. Install `pip`_ and `virtualenv`_ if you do not already have them. You may want to refer to the `Python Development Environment Setup Guide`_ for Google Cloud Platform for instructions. + + .. _Python Development Environment Setup Guide: + https://cloud.google.com/python/setup + +#. Create a virtualenv. Samples are compatible with Python 2.7 and 3.4+. + + .. code-block:: bash + + $ virtualenv env + $ source env/bin/activate + +#. Install the dependencies needed to run the samples. + + .. code-block:: bash + + $ pip install -r requirements.txt + +.. _pip: https://pip.pypa.io/ +.. _virtualenv: https://virtualenv.pypa.io/ diff --git a/scripts/readme-gen/templates/install_portaudio.tmpl.rst b/scripts/readme-gen/templates/install_portaudio.tmpl.rst new file mode 100644 index 00000000..5ea33d18 --- /dev/null +++ b/scripts/readme-gen/templates/install_portaudio.tmpl.rst @@ -0,0 +1,35 @@ +Install PortAudio ++++++++++++++++++ + +Install `PortAudio`_. This is required by the `PyAudio`_ library to stream +audio from your computer's microphone. PyAudio depends on PortAudio for cross-platform compatibility, and is installed differently depending on the +platform. + +* For Mac OS X, you can use `Homebrew`_:: + + brew install portaudio + + **Note**: if you encounter an error when running `pip install` that indicates + it can't find `portaudio.h`, try running `pip install` with the following + flags:: + + pip install --global-option='build_ext' \ + --global-option='-I/usr/local/include' \ + --global-option='-L/usr/local/lib' \ + pyaudio + +* For Debian / Ubuntu Linux:: + + apt-get install portaudio19-dev python-all-dev + +* Windows may work without having to install PortAudio explicitly (it will get + installed with PyAudio). + +For more details, see the `PyAudio installation`_ page. + + +.. _PyAudio: https://people.csail.mit.edu/hubert/pyaudio/ +.. _PortAudio: http://www.portaudio.com/ +.. _PyAudio installation: + https://people.csail.mit.edu/hubert/pyaudio/#downloads +.. _Homebrew: http://brew.sh diff --git a/synth.metadata b/synth.metadata index b4a0f334..55b23a04 100644 --- a/synth.metadata +++ b/synth.metadata @@ -1,32 +1,25 @@ { "sources": [ - { - "generator": { - "name": "artman", - "version": "2.0.0", - "dockerImage": "googleapis/artman@sha256:b3b47805231a305d0f40c4bf069df20f6a2635574e6d4259fac651d3f9f6e098" - } - }, { "git": { "name": ".", "remote": "https://github.com/googleapis/python-scheduler.git", - "sha": "d17f5ffd8d6030190e3529d6eed5c9899145dd96" + "sha": "aa232f688ce1bd20eb8f7b6702bd741d36eb4b38" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "42ee97c1b93a0e3759bbba3013da309f670a90ab", - "internalRef": "307114445" + "sha": "cf41866c6f14f10a07aa1e2a1260fc0a2727d889", + "internalRef": "317812187" } }, { "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "f5e4c17dc78a966dbf29961dd01f9bbd63e20a04" + "sha": "cf2eff09d0f5319a4dc5cdce2b6356d85af4a798" } } ], @@ -37,8 +30,7 @@ "apiName": "scheduler", "apiVersion": "v1beta1", "language": "python", - "generator": "gapic", - "config": "google/cloud/scheduler/artman_cloudscheduler_v1beta1.yaml" + "generator": "bazel" } }, { @@ -47,8 +39,7 @@ "apiName": "scheduler", "apiVersion": "v1", "language": "python", - "generator": "gapic", - "config": "google/cloud/scheduler/artman_cloudscheduler_v1.yaml" + "generator": "bazel" } } ] diff --git a/synth.py b/synth.py index 8bd9f163..1cc2f263 100644 --- a/synth.py +++ b/synth.py @@ -52,4 +52,14 @@ templated_files = common.py_library(cov_level=86) s.move(templated_files) +# TODO(busunkim): Use latest sphinx after microgenerator transition +s.replace("noxfile.py", """['"]sphinx['"]""", '"sphinx<3.0.0"') + +# Escape '_' in docstrings +s.replace( + "google/cloud/**/*_pb2.py", + """\_$""", + """\_""", +) + s.shell.run(["nox", "-s", "blacken"], hide_output=False) diff --git a/testing/.gitignore b/testing/.gitignore new file mode 100644 index 00000000..b05fbd63 --- /dev/null +++ b/testing/.gitignore @@ -0,0 +1,3 @@ +test-env.sh +service-account.json +client-secrets.json \ No newline at end of file