Skip to content

Commit

Permalink
update region tags (#1532)
Browse files Browse the repository at this point in the history
  • Loading branch information
averikitsch authored and andrewsg committed Jun 20, 2018
1 parent 362a99c commit bc73929
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tasks/pull_queue_snippets.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@


def create_task(project, queue, location):
# [START tasks_create_task]
# [START cloud_tasks_create_task]
"""Create a task for a given queue with an arbitrary payload."""

from google.cloud import tasks_v2beta2
Expand All @@ -50,11 +50,11 @@ def create_task(project, queue, location):

print('Created task: {}'.format(response.name))
return response
# [END tasks_create_task]
# [END cloud_tasks_create_task]


def lease_task(project, queue, location):
# [START tasks_lease_and_acknowledge_task]
# [START cloud_tasks_lease_and_acknowledge_task]
"""Lease a single task from a given queue for 10 minutes."""

from google.cloud import tasks_v2beta2
Expand Down Expand Up @@ -89,7 +89,7 @@ def acknowledge_task(task):
client.acknowledge_task(task.name, task.schedule_time)

print('Acknowledged task {}'.format(task.name))
# [END tasks_lease_and_acknowledge_task]
# [END cloud_tasks_lease_and_acknowledge_task]


if __name__ == '__main__':
Expand Down

0 comments on commit bc73929

Please sign in to comment.