Class: Google::Apis::CloudtasksV2beta2::Queue

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/cloudtasks_v2beta2/classes.rb,
generated/google/apis/cloudtasks_v2beta2/representations.rb,
generated/google/apis/cloudtasks_v2beta2/representations.rb

Overview

A queue is a container of related tasks. Queues are configured to manage how those tasks are dispatched. Configurable properties include rate limits, retry options, target types, and others.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Queue

Returns a new instance of Queue



1128
1129
1130
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1128

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#app_engine_http_targetGoogle::Apis::CloudtasksV2beta2::AppEngineHttpTarget

App Engine HTTP target. The task will be delivered to the App Engine application hostname specified by its AppEngineHttpTarget and AppEngineHttpRequest. The documentation for AppEngineHttpRequest explains how the task's host URL is constructed. Using this type of queue configuration requires appengine.applications.get Google IAM permission for the project and the following scope: https://www.googleapis.com/auth/cloud-platform Corresponds to the JSON property appEngineHttpTarget



1055
1056
1057
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1055

def app_engine_http_target
  @app_engine_http_target
end

#app_engine_queue_configGoogle::Apis::CloudtasksV2beta2::AppEngineQueueConfig

Deprecated. Use AppEngineTarget. Corresponds to the JSON property appEngineQueueConfig



1060
1061
1062
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1060

def app_engine_queue_config
  @app_engine_queue_config
end

#nameString

The queue name. The queue name must have the following format: projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID

  • PROJECT_ID can contain uppercase and lowercase letters, numbers, hyphens, colons, and periods; that is, it must match the regular expression: [a-zA-Z\\d-:\\.]+.
  • QUEUE_ID can contain uppercase and lowercase letters, numbers, and hyphens; that is, it must match the regular expression: [a-zA-Z\\d-]+. The maximum length is 100 characters. Caller-specified and required in CreateQueueRequest, after which it becomes output only. Corresponds to the JSON property name

Returns:

  • (String)


1076
1077
1078
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1076

def name
  @name
end

#pull_queue_configGoogle::Apis::CloudtasksV2beta2::PullQueueConfig

Deprecated. Use PullTarget. Corresponds to the JSON property pullQueueConfig



1081
1082
1083
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1081

def pull_queue_config
  @pull_queue_config
end

#pull_targetGoogle::Apis::CloudtasksV2beta2::PullTarget

Pull target. Corresponds to the JSON property pullTarget



1086
1087
1088
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1086

def pull_target
  @pull_target
end

#purge_timeString

Output only. The last time this queue was purged. All tasks that were created before this time were purged. A queue can be purged using CloudTasks.PurgeQueue, the App Engine Task Queue SDK, or the Cloud Console . Purge time will be truncated to the nearest microsecond. Purge time will be zero if the queue has never been purged. Corresponds to the JSON property purgeTime

Returns:

  • (String)


1099
1100
1101
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1099

def purge_time
  @purge_time
end

#queue_stateString

Output only. The state of the queue. queue_state can only be changed by called CloudTasks.PauseQueue, CloudTasks.ResumeQueue, or uploading queue.yaml. CloudTasks.UpdateQueue cannot be used to change queue_state. Corresponds to the JSON property queueState

Returns:

  • (String)


1109
1110
1111
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1109

def queue_state
  @queue_state
end

#retry_configGoogle::Apis::CloudtasksV2beta2::RetryConfig

Retry config. These settings determine retry behavior. If a task does not complete successfully, meaning that an acknowledgement is not received from the handler before the deadline, then it will be retried with exponential backoff according to the settings in RetryConfig. Corresponds to the JSON property retryConfig



1120
1121
1122
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1120

def retry_config
  @retry_config
end

#throttle_configGoogle::Apis::CloudtasksV2beta2::ThrottleConfig

Throttle config. These settings determine the throttling behavior. Corresponds to the JSON property throttleConfig



1126
1127
1128
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1126

def throttle_config
  @throttle_config
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
# File 'generated/google/apis/cloudtasks_v2beta2/classes.rb', line 1133

def update!(**args)
  @app_engine_http_target = args[:app_engine_http_target] if args.key?(:app_engine_http_target)
  @app_engine_queue_config = args[:app_engine_queue_config] if args.key?(:app_engine_queue_config)
  @name = args[:name] if args.key?(:name)
  @pull_queue_config = args[:pull_queue_config] if args.key?(:pull_queue_config)
  @pull_target = args[:pull_target] if args.key?(:pull_target)
  @purge_time = args[:purge_time] if args.key?(:purge_time)
  @queue_state = args[:queue_state] if args.key?(:queue_state)
  @retry_config = args[:retry_config] if args.key?(:retry_config)
  @throttle_config = args[:throttle_config] if args.key?(:throttle_config)
end