# Cloud Tasks V2beta2 API - Module Google::Cloud::Tasks::V2beta2::Queue::State (v0.18.0)

0.18.0 (latest) 0.17.0 0.16.1 0.15.0 0.14.1 0.13.0 0.12.1 0.11.3 0.10.0 0.9.2 0.8.0 0.7.0 0.6.0 0.5.5 Reference documentation and code samples for the Cloud Tasks V2beta2 API module Google::Cloud::Tasks::V2beta2::Queue::State.

State of the queue.

## Constants

### STATE_UNSPECIFIED

**value:** 0  
Unspecified state.

### RUNNING

**value:** 1  
The queue is running. Tasks can be dispatched.


<br />

If the queue was created using Cloud Tasks and the queue has
had no activity (method calls or task dispatches) for 30 days,
the queue may take a few minutes to re-activate. Some method
calls may return \[NOT_FOUND\]\[google.rpc.Code.NOT_FOUND\] and
tasks may not be dispatched for a few minutes until the queue
has been re-activated.

### PAUSED

**value:** 2  
Tasks are paused by the user. If the queue is paused then Cloud
Tasks will stop delivering tasks from it, but more tasks can
still be added to it by the user. When a pull queue is paused,
all [LeaseTasks](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-tasks-v2beta2/latest/Google-Cloud-Tasks-V2beta2-CloudTasks-Client#Google__Cloud__Tasks__V2beta2__CloudTasks__Client_lease_tasks_instance_ "Google::Cloud::Tasks::V2beta2::CloudTasks::Client#lease_tasks (method)") calls
will return a \[FAILED_PRECONDITION\]\[google.rpc.Code.FAILED_PRECONDITION\].

### DISABLED

**value:** 3  
The queue is disabled.


A queue becomes `DISABLED` when
[queue.yaml](https://cloud.google.com/appengine/docs/python/config/queueref)
or
[queue.xml](https://cloud.google.com/appengine/docs/standard/java/config/queueref)
is uploaded which does not contain the queue. You cannot directly disable
a queue.

When a queue is disabled, tasks can still be added to a queue
but the tasks are not dispatched and
[LeaseTasks](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-tasks-v2beta2/latest/Google-Cloud-Tasks-V2beta2-CloudTasks-Client#Google__Cloud__Tasks__V2beta2__CloudTasks__Client_lease_tasks_instance_ "Google::Cloud::Tasks::V2beta2::CloudTasks::Client#lease_tasks (method)") calls
return a `FAILED_PRECONDITION` error.

<br />

To permanently delete this queue and all of its tasks, call
[DeleteQueue](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-tasks-v2beta2/latest/Google-Cloud-Tasks-V2beta2-CloudTasks-Client#Google__Cloud__Tasks__V2beta2__CloudTasks__Client_delete_queue_instance_ "Google::Cloud::Tasks::V2beta2::CloudTasks::Client#delete_queue (method)").