Skip to content

Commit

Permalink
fix region tags
Browse files Browse the repository at this point in the history
  • Loading branch information
cojenco authored and dandhlee committed Apr 22, 2023
1 parent be1fb22 commit 35ae7fa
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions scheduler/snippets/app.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# [START cloud_scheduler_python_yaml]
# [START cloudscheduler_python_yaml]
runtime: python37
service: my-service
# [END cloud_scheduler_python_yaml]
# [END cloudscheduler_python_yaml]
8 changes: 4 additions & 4 deletions scheduler/snippets/create_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

def create_scheduler_job(project_id, location_id, service_id):
"""Create a job with an App Engine target via the Cloud Scheduler API"""
# [START cloud_scheduler_create_job]
# [START cloudscheduler_create_job]
from google.cloud import scheduler

# Create a client.
Expand Down Expand Up @@ -45,13 +45,13 @@ def create_scheduler_job(project_id, location_id, service_id):
response = client.create_job(request={"parent": parent, "job": job})

print("Created job: {}".format(response.name))
# [END cloud_scheduler_create_job]
# [END cloudscheduler_create_job]
return response


def delete_scheduler_job(project_id, location_id, job_id):
"""Delete a job via the Cloud Scheduler API"""
# [START cloud_scheduler_delete_job]
# [START cloudscheduler_delete_job]
from google.api_core.exceptions import GoogleAPICallError
from google.cloud import scheduler

Expand All @@ -72,4 +72,4 @@ def delete_scheduler_job(project_id, location_id, job_id):
print("Job deleted.")
except GoogleAPICallError as e:
print("Error: %s" % e)
# [END cloud_scheduler_delete_job]
# [END cloudscheduler_delete_job]
4 changes: 2 additions & 2 deletions scheduler/snippets/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

"""App Engine app to serve as an endpoint for Cloud Scheduler samples."""

# [START cloud_scheduler_app]
# [START cloudscheduler_app]
from flask import Flask, request

app = Flask(__name__)
Expand All @@ -29,7 +29,7 @@ def example_task_handler():
return "Printed job payload: {}".format(payload)


# [END cloud_scheduler_app]
# [END cloudscheduler_app]


@app.route("/")
Expand Down

0 comments on commit 35ae7fa

Please sign in to comment.