Skip to content
Start here

Queues

resource cloudflare_queue

required Expand Collapse
account_id: String

A Resource identifier.

queue_name: String
optional Expand Collapse
settings?: Attributes
delivery_delay?: Float64

Number of seconds to delay delivery of all messages to consumers.

delivery_paused?: Bool

Indicates if message delivery to consumers is currently paused.

message_retention_period?: Float64

Number of seconds after which an unconsumed message will be delayed.

computed Expand Collapse
id: String
queue_id: String
consumers_total_count: Float64
created_on: String
modified_on: String
producers_total_count: Float64
consumers: List[Attributes]
consumer_id: String

A Resource identifier.

created_on: Time
dead_letter_queue: String

Name of the dead letter queue, or empty string if not configured

queue_name: String
script_name: String

Name of a Worker

settings: Attributes
batch_size: Float64

The maximum number of messages to include in a batch.

max_concurrency: Float64

Maximum number of concurrent consumers that may consume from this Queue. Set to null to automatically opt in to the platform's maximum (recommended).

max_retries: Float64

The maximum number of retries

max_wait_time_ms: Float64

The number of milliseconds to wait for a batch to fill up before attempting to deliver it

retry_delay: Float64

The number of seconds to delay before making the message available for another attempt.

visibility_timeout_ms: Float64

The number of milliseconds that a message is exclusively leased. After the timeout, the message becomes available for another attempt.

type: String
producers: List[Attributes]
script: String
type: String
bucket_name: String

cloudflare_queue

resource "cloudflare_queue" "example_queue" {
  account_id = "023e105f4ecef8ad9ca31a8372d0c353"
  queue_name = "example-queue"
}

data cloudflare_queue

required Expand Collapse
queue_id: String

A Resource identifier.

account_id: String

A Resource identifier.

computed Expand Collapse
id: String

A Resource identifier.

consumers_total_count: Float64
created_on: String
modified_on: String
producers_total_count: Float64
queue_name: String
consumers: List[Attributes]
consumer_id: String

A Resource identifier.

created_on: Time
dead_letter_queue: String

Name of the dead letter queue, or empty string if not configured

queue_name: String
script_name: String

Name of a Worker

settings: Attributes
batch_size: Float64

The maximum number of messages to include in a batch.

max_concurrency: Float64

Maximum number of concurrent consumers that may consume from this Queue. Set to null to automatically opt in to the platform's maximum (recommended).

max_retries: Float64

The maximum number of retries

max_wait_time_ms: Float64

The number of milliseconds to wait for a batch to fill up before attempting to deliver it

retry_delay: Float64

The number of seconds to delay before making the message available for another attempt.

visibility_timeout_ms: Float64

The number of milliseconds that a message is exclusively leased. After the timeout, the message becomes available for another attempt.

type: String
producers: List[Attributes]
script: String
type: String
bucket_name: String
settings: Attributes
delivery_delay: Float64

Number of seconds to delay delivery of all messages to consumers.

delivery_paused: Bool

Indicates if message delivery to consumers is currently paused.

message_retention_period: Float64

Number of seconds after which an unconsumed message will be delayed.

cloudflare_queue

data "cloudflare_queue" "example_queue" {
  account_id = "023e105f4ecef8ad9ca31a8372d0c353"
  queue_id = "023e105f4ecef8ad9ca31a8372d0c353"
}

data cloudflare_queues

required Expand Collapse
account_id: String

A Resource identifier.

optional Expand Collapse
max_items?: Int64

Max items to fetch, default: 1000

computed Expand Collapse
result: List[Attributes]

The items returned by the data source

id: String
consumers: List[Attributes]
consumer_id: String

A Resource identifier.

created_on: Time
dead_letter_queue: String

Name of the dead letter queue, or empty string if not configured

queue_name: String
script_name: String

Name of a Worker

settings: Attributes
batch_size: Float64

The maximum number of messages to include in a batch.

max_concurrency: Float64

Maximum number of concurrent consumers that may consume from this Queue. Set to null to automatically opt in to the platform's maximum (recommended).

max_retries: Float64

The maximum number of retries

max_wait_time_ms: Float64

The number of milliseconds to wait for a batch to fill up before attempting to deliver it

retry_delay: Float64

The number of seconds to delay before making the message available for another attempt.

visibility_timeout_ms: Float64

The number of milliseconds that a message is exclusively leased. After the timeout, the message becomes available for another attempt.

type: String
consumers_total_count: Float64
created_on: String
modified_on: String
producers: List[Attributes]
script: String
type: String
bucket_name: String
producers_total_count: Float64
queue_id: String
queue_name: String
settings: Attributes
delivery_delay: Float64

Number of seconds to delay delivery of all messages to consumers.

delivery_paused: Bool

Indicates if message delivery to consumers is currently paused.

message_retention_period: Float64

Number of seconds after which an unconsumed message will be delayed.

cloudflare_queues

data "cloudflare_queues" "example_queues" {
  account_id = "023e105f4ecef8ad9ca31a8372d0c353"
}

QueuesConsumers

resource cloudflare_queue_consumer

required Expand Collapse
account_id: String

A Resource identifier.

queue_id: String

A Resource identifier.

type: String
optional Expand Collapse
consumer_id?: String

A Resource identifier.

dead_letter_queue?: String
script_name?: String

Name of a Worker

settings?: Attributes
batch_size?: Float64

The maximum number of messages to include in a batch.

max_concurrency?: Float64

Maximum number of concurrent consumers that may consume from this Queue. Set to null to automatically opt in to the platform's maximum (recommended).

max_retries?: Float64

The maximum number of retries

max_wait_time_ms?: Float64

The number of milliseconds to wait for a batch to fill up before attempting to deliver it

retry_delay?: Float64

The number of seconds to delay before making the message available for another attempt.

visibility_timeout_ms?: Float64

The number of milliseconds that a message is exclusively leased. After the timeout, the message becomes available for another attempt.

computed Expand Collapse
created_on: Time
queue_name: String

cloudflare_queue_consumer

resource "cloudflare_queue_consumer" "example_queue_consumer" {
  account_id = "023e105f4ecef8ad9ca31a8372d0c353"
  queue_id = "023e105f4ecef8ad9ca31a8372d0c353"
  script_name = "my-consumer-worker"
  type = "worker"
  dead_letter_queue = "example-queue"
  settings = {
    batch_size = 50
    max_concurrency = 10
    max_retries = 3
    max_wait_time_ms = 5000
    retry_delay = 10
  }
}

data cloudflare_queue_consumer

required Expand Collapse
account_id: String

A Resource identifier.

consumer_id: String

A Resource identifier.

queue_id: String

A Resource identifier.

computed Expand Collapse
created_on: Time
dead_letter_queue: String

Name of the dead letter queue, or empty string if not configured

queue_name: String
script_name: String

Name of a Worker

type: String
settings: Attributes
batch_size: Float64

The maximum number of messages to include in a batch.

max_concurrency: Float64

Maximum number of concurrent consumers that may consume from this Queue. Set to null to automatically opt in to the platform's maximum (recommended).

max_retries: Float64

The maximum number of retries

max_wait_time_ms: Float64

The number of milliseconds to wait for a batch to fill up before attempting to deliver it

retry_delay: Float64

The number of seconds to delay before making the message available for another attempt.

visibility_timeout_ms: Float64

The number of milliseconds that a message is exclusively leased. After the timeout, the message becomes available for another attempt.

cloudflare_queue_consumer

data "cloudflare_queue_consumer" "example_queue_consumer" {
  account_id = "023e105f4ecef8ad9ca31a8372d0c353"
  queue_id = "023e105f4ecef8ad9ca31a8372d0c353"
  consumer_id = "023e105f4ecef8ad9ca31a8372d0c353"
}

data cloudflare_queue_consumers

required Expand Collapse
account_id: String

A Resource identifier.

queue_id: String

A Resource identifier.

optional Expand Collapse
max_items?: Int64

Max items to fetch, default: 1000

computed Expand Collapse
result: List[Attributes]

The items returned by the data source

consumer_id: String

A Resource identifier.

created_on: Time
dead_letter_queue: String

Name of the dead letter queue, or empty string if not configured

queue_name: String
script_name: String

Name of a Worker

settings: Attributes
batch_size: Float64

The maximum number of messages to include in a batch.

max_concurrency: Float64

Maximum number of concurrent consumers that may consume from this Queue. Set to null to automatically opt in to the platform's maximum (recommended).

max_retries: Float64

The maximum number of retries

max_wait_time_ms: Float64

The number of milliseconds to wait for a batch to fill up before attempting to deliver it

retry_delay: Float64

The number of seconds to delay before making the message available for another attempt.

visibility_timeout_ms: Float64

The number of milliseconds that a message is exclusively leased. After the timeout, the message becomes available for another attempt.

type: String

cloudflare_queue_consumers

data "cloudflare_queue_consumers" "example_queue_consumers" {
  account_id = "023e105f4ecef8ad9ca31a8372d0c353"
  queue_id = "023e105f4ecef8ad9ca31a8372d0c353"
}