1. Packages
  2. Google Cloud (GCP) Classic
  3. API Docs
  4. cloudtasks
  5. Queue
Google Cloud Classic v7.29.0 published on Wednesday, Jun 26, 2024 by Pulumi

gcp.cloudtasks.Queue

Explore with Pulumi AI

gcp logo
Google Cloud Classic v7.29.0 published on Wednesday, Jun 26, 2024 by Pulumi

    A named resource to which messages are sent by publishers.

    Example Usage

    Queue Basic

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const _default = new gcp.cloudtasks.Queue("default", {
        name: "cloud-tasks-queue-test",
        location: "us-central1",
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    default = gcp.cloudtasks.Queue("default",
        name="cloud-tasks-queue-test",
        location="us-central1")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/cloudtasks"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudtasks.NewQueue(ctx, "default", &cloudtasks.QueueArgs{
    			Name:     pulumi.String("cloud-tasks-queue-test"),
    			Location: pulumi.String("us-central1"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var @default = new Gcp.CloudTasks.Queue("default", new()
        {
            Name = "cloud-tasks-queue-test",
            Location = "us-central1",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.cloudtasks.Queue;
    import com.pulumi.gcp.cloudtasks.QueueArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var default_ = new Queue("default", QueueArgs.builder()
                .name("cloud-tasks-queue-test")
                .location("us-central1")
                .build());
    
        }
    }
    
    resources:
      default:
        type: gcp:cloudtasks:Queue
        properties:
          name: cloud-tasks-queue-test
          location: us-central1
    

    Cloud Tasks Queue Advanced

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const advancedConfiguration = new gcp.cloudtasks.Queue("advanced_configuration", {
        name: "instance-name",
        location: "us-central1",
        appEngineRoutingOverride: {
            service: "worker",
            version: "1.0",
            instance: "test",
        },
        rateLimits: {
            maxConcurrentDispatches: 3,
            maxDispatchesPerSecond: 2,
        },
        retryConfig: {
            maxAttempts: 5,
            maxRetryDuration: "4s",
            maxBackoff: "3s",
            minBackoff: "2s",
            maxDoublings: 1,
        },
        stackdriverLoggingConfig: {
            samplingRatio: 0.9,
        },
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    advanced_configuration = gcp.cloudtasks.Queue("advanced_configuration",
        name="instance-name",
        location="us-central1",
        app_engine_routing_override=gcp.cloudtasks.QueueAppEngineRoutingOverrideArgs(
            service="worker",
            version="1.0",
            instance="test",
        ),
        rate_limits=gcp.cloudtasks.QueueRateLimitsArgs(
            max_concurrent_dispatches=3,
            max_dispatches_per_second=2,
        ),
        retry_config=gcp.cloudtasks.QueueRetryConfigArgs(
            max_attempts=5,
            max_retry_duration="4s",
            max_backoff="3s",
            min_backoff="2s",
            max_doublings=1,
        ),
        stackdriver_logging_config=gcp.cloudtasks.QueueStackdriverLoggingConfigArgs(
            sampling_ratio=0.9,
        ))
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/cloudtasks"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudtasks.NewQueue(ctx, "advanced_configuration", &cloudtasks.QueueArgs{
    			Name:     pulumi.String("instance-name"),
    			Location: pulumi.String("us-central1"),
    			AppEngineRoutingOverride: &cloudtasks.QueueAppEngineRoutingOverrideArgs{
    				Service:  pulumi.String("worker"),
    				Version:  pulumi.String("1.0"),
    				Instance: pulumi.String("test"),
    			},
    			RateLimits: &cloudtasks.QueueRateLimitsArgs{
    				MaxConcurrentDispatches: pulumi.Int(3),
    				MaxDispatchesPerSecond:  pulumi.Float64(2),
    			},
    			RetryConfig: &cloudtasks.QueueRetryConfigArgs{
    				MaxAttempts:      pulumi.Int(5),
    				MaxRetryDuration: pulumi.String("4s"),
    				MaxBackoff:       pulumi.String("3s"),
    				MinBackoff:       pulumi.String("2s"),
    				MaxDoublings:     pulumi.Int(1),
    			},
    			StackdriverLoggingConfig: &cloudtasks.QueueStackdriverLoggingConfigArgs{
    				SamplingRatio: pulumi.Float64(0.9),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var advancedConfiguration = new Gcp.CloudTasks.Queue("advanced_configuration", new()
        {
            Name = "instance-name",
            Location = "us-central1",
            AppEngineRoutingOverride = new Gcp.CloudTasks.Inputs.QueueAppEngineRoutingOverrideArgs
            {
                Service = "worker",
                Version = "1.0",
                Instance = "test",
            },
            RateLimits = new Gcp.CloudTasks.Inputs.QueueRateLimitsArgs
            {
                MaxConcurrentDispatches = 3,
                MaxDispatchesPerSecond = 2,
            },
            RetryConfig = new Gcp.CloudTasks.Inputs.QueueRetryConfigArgs
            {
                MaxAttempts = 5,
                MaxRetryDuration = "4s",
                MaxBackoff = "3s",
                MinBackoff = "2s",
                MaxDoublings = 1,
            },
            StackdriverLoggingConfig = new Gcp.CloudTasks.Inputs.QueueStackdriverLoggingConfigArgs
            {
                SamplingRatio = 0.9,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.cloudtasks.Queue;
    import com.pulumi.gcp.cloudtasks.QueueArgs;
    import com.pulumi.gcp.cloudtasks.inputs.QueueAppEngineRoutingOverrideArgs;
    import com.pulumi.gcp.cloudtasks.inputs.QueueRateLimitsArgs;
    import com.pulumi.gcp.cloudtasks.inputs.QueueRetryConfigArgs;
    import com.pulumi.gcp.cloudtasks.inputs.QueueStackdriverLoggingConfigArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var advancedConfiguration = new Queue("advancedConfiguration", QueueArgs.builder()
                .name("instance-name")
                .location("us-central1")
                .appEngineRoutingOverride(QueueAppEngineRoutingOverrideArgs.builder()
                    .service("worker")
                    .version("1.0")
                    .instance("test")
                    .build())
                .rateLimits(QueueRateLimitsArgs.builder()
                    .maxConcurrentDispatches(3)
                    .maxDispatchesPerSecond(2)
                    .build())
                .retryConfig(QueueRetryConfigArgs.builder()
                    .maxAttempts(5)
                    .maxRetryDuration("4s")
                    .maxBackoff("3s")
                    .minBackoff("2s")
                    .maxDoublings(1)
                    .build())
                .stackdriverLoggingConfig(QueueStackdriverLoggingConfigArgs.builder()
                    .samplingRatio(0.9)
                    .build())
                .build());
    
        }
    }
    
    resources:
      advancedConfiguration:
        type: gcp:cloudtasks:Queue
        name: advanced_configuration
        properties:
          name: instance-name
          location: us-central1
          appEngineRoutingOverride:
            service: worker
            version: '1.0'
            instance: test
          rateLimits:
            maxConcurrentDispatches: 3
            maxDispatchesPerSecond: 2
          retryConfig:
            maxAttempts: 5
            maxRetryDuration: 4s
            maxBackoff: 3s
            minBackoff: 2s
            maxDoublings: 1
          stackdriverLoggingConfig:
            samplingRatio: 0.9
    

    Create Queue Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Queue(name: string, args: QueueArgs, opts?: CustomResourceOptions);
    @overload
    def Queue(resource_name: str,
              args: QueueArgs,
              opts: Optional[ResourceOptions] = None)
    
    @overload
    def Queue(resource_name: str,
              opts: Optional[ResourceOptions] = None,
              location: Optional[str] = None,
              app_engine_routing_override: Optional[QueueAppEngineRoutingOverrideArgs] = None,
              name: Optional[str] = None,
              project: Optional[str] = None,
              rate_limits: Optional[QueueRateLimitsArgs] = None,
              retry_config: Optional[QueueRetryConfigArgs] = None,
              stackdriver_logging_config: Optional[QueueStackdriverLoggingConfigArgs] = None)
    func NewQueue(ctx *Context, name string, args QueueArgs, opts ...ResourceOption) (*Queue, error)
    public Queue(string name, QueueArgs args, CustomResourceOptions? opts = null)
    public Queue(String name, QueueArgs args)
    public Queue(String name, QueueArgs args, CustomResourceOptions options)
    
    type: gcp:cloudtasks:Queue
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args QueueArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args QueueArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args QueueArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args QueueArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args QueueArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var queueResource = new Gcp.CloudTasks.Queue("queueResource", new()
    {
        Location = "string",
        AppEngineRoutingOverride = new Gcp.CloudTasks.Inputs.QueueAppEngineRoutingOverrideArgs
        {
            Host = "string",
            Instance = "string",
            Service = "string",
            Version = "string",
        },
        Name = "string",
        Project = "string",
        RateLimits = new Gcp.CloudTasks.Inputs.QueueRateLimitsArgs
        {
            MaxBurstSize = 0,
            MaxConcurrentDispatches = 0,
            MaxDispatchesPerSecond = 0,
        },
        RetryConfig = new Gcp.CloudTasks.Inputs.QueueRetryConfigArgs
        {
            MaxAttempts = 0,
            MaxBackoff = "string",
            MaxDoublings = 0,
            MaxRetryDuration = "string",
            MinBackoff = "string",
        },
        StackdriverLoggingConfig = new Gcp.CloudTasks.Inputs.QueueStackdriverLoggingConfigArgs
        {
            SamplingRatio = 0,
        },
    });
    
    example, err := cloudtasks.NewQueue(ctx, "queueResource", &cloudtasks.QueueArgs{
    	Location: pulumi.String("string"),
    	AppEngineRoutingOverride: &cloudtasks.QueueAppEngineRoutingOverrideArgs{
    		Host:     pulumi.String("string"),
    		Instance: pulumi.String("string"),
    		Service:  pulumi.String("string"),
    		Version:  pulumi.String("string"),
    	},
    	Name:    pulumi.String("string"),
    	Project: pulumi.String("string"),
    	RateLimits: &cloudtasks.QueueRateLimitsArgs{
    		MaxBurstSize:            pulumi.Int(0),
    		MaxConcurrentDispatches: pulumi.Int(0),
    		MaxDispatchesPerSecond:  pulumi.Float64(0),
    	},
    	RetryConfig: &cloudtasks.QueueRetryConfigArgs{
    		MaxAttempts:      pulumi.Int(0),
    		MaxBackoff:       pulumi.String("string"),
    		MaxDoublings:     pulumi.Int(0),
    		MaxRetryDuration: pulumi.String("string"),
    		MinBackoff:       pulumi.String("string"),
    	},
    	StackdriverLoggingConfig: &cloudtasks.QueueStackdriverLoggingConfigArgs{
    		SamplingRatio: pulumi.Float64(0),
    	},
    })
    
    var queueResource = new Queue("queueResource", QueueArgs.builder()
        .location("string")
        .appEngineRoutingOverride(QueueAppEngineRoutingOverrideArgs.builder()
            .host("string")
            .instance("string")
            .service("string")
            .version("string")
            .build())
        .name("string")
        .project("string")
        .rateLimits(QueueRateLimitsArgs.builder()
            .maxBurstSize(0)
            .maxConcurrentDispatches(0)
            .maxDispatchesPerSecond(0)
            .build())
        .retryConfig(QueueRetryConfigArgs.builder()
            .maxAttempts(0)
            .maxBackoff("string")
            .maxDoublings(0)
            .maxRetryDuration("string")
            .minBackoff("string")
            .build())
        .stackdriverLoggingConfig(QueueStackdriverLoggingConfigArgs.builder()
            .samplingRatio(0)
            .build())
        .build());
    
    queue_resource = gcp.cloudtasks.Queue("queueResource",
        location="string",
        app_engine_routing_override=gcp.cloudtasks.QueueAppEngineRoutingOverrideArgs(
            host="string",
            instance="string",
            service="string",
            version="string",
        ),
        name="string",
        project="string",
        rate_limits=gcp.cloudtasks.QueueRateLimitsArgs(
            max_burst_size=0,
            max_concurrent_dispatches=0,
            max_dispatches_per_second=0,
        ),
        retry_config=gcp.cloudtasks.QueueRetryConfigArgs(
            max_attempts=0,
            max_backoff="string",
            max_doublings=0,
            max_retry_duration="string",
            min_backoff="string",
        ),
        stackdriver_logging_config=gcp.cloudtasks.QueueStackdriverLoggingConfigArgs(
            sampling_ratio=0,
        ))
    
    const queueResource = new gcp.cloudtasks.Queue("queueResource", {
        location: "string",
        appEngineRoutingOverride: {
            host: "string",
            instance: "string",
            service: "string",
            version: "string",
        },
        name: "string",
        project: "string",
        rateLimits: {
            maxBurstSize: 0,
            maxConcurrentDispatches: 0,
            maxDispatchesPerSecond: 0,
        },
        retryConfig: {
            maxAttempts: 0,
            maxBackoff: "string",
            maxDoublings: 0,
            maxRetryDuration: "string",
            minBackoff: "string",
        },
        stackdriverLoggingConfig: {
            samplingRatio: 0,
        },
    });
    
    type: gcp:cloudtasks:Queue
    properties:
        appEngineRoutingOverride:
            host: string
            instance: string
            service: string
            version: string
        location: string
        name: string
        project: string
        rateLimits:
            maxBurstSize: 0
            maxConcurrentDispatches: 0
            maxDispatchesPerSecond: 0
        retryConfig:
            maxAttempts: 0
            maxBackoff: string
            maxDoublings: 0
            maxRetryDuration: string
            minBackoff: string
        stackdriverLoggingConfig:
            samplingRatio: 0
    

    Queue Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Queue resource accepts the following input properties:

    Location string
    The location of the queue


    AppEngineRoutingOverride QueueAppEngineRoutingOverride
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    Name string
    The queue name.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    RateLimits QueueRateLimits
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    RetryConfig QueueRetryConfig
    Settings that determine the retry behavior. Structure is documented below.
    StackdriverLoggingConfig QueueStackdriverLoggingConfig
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    Location string
    The location of the queue


    AppEngineRoutingOverride QueueAppEngineRoutingOverrideArgs
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    Name string
    The queue name.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    RateLimits QueueRateLimitsArgs
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    RetryConfig QueueRetryConfigArgs
    Settings that determine the retry behavior. Structure is documented below.
    StackdriverLoggingConfig QueueStackdriverLoggingConfigArgs
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    location String
    The location of the queue


    appEngineRoutingOverride QueueAppEngineRoutingOverride
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    name String
    The queue name.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rateLimits QueueRateLimits
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retryConfig QueueRetryConfig
    Settings that determine the retry behavior. Structure is documented below.
    stackdriverLoggingConfig QueueStackdriverLoggingConfig
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    location string
    The location of the queue


    appEngineRoutingOverride QueueAppEngineRoutingOverride
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    name string
    The queue name.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rateLimits QueueRateLimits
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retryConfig QueueRetryConfig
    Settings that determine the retry behavior. Structure is documented below.
    stackdriverLoggingConfig QueueStackdriverLoggingConfig
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    location str
    The location of the queue


    app_engine_routing_override QueueAppEngineRoutingOverrideArgs
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    name str
    The queue name.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rate_limits QueueRateLimitsArgs
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retry_config QueueRetryConfigArgs
    Settings that determine the retry behavior. Structure is documented below.
    stackdriver_logging_config QueueStackdriverLoggingConfigArgs
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    location String
    The location of the queue


    appEngineRoutingOverride Property Map
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    name String
    The queue name.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rateLimits Property Map
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retryConfig Property Map
    Settings that determine the retry behavior. Structure is documented below.
    stackdriverLoggingConfig Property Map
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Queue resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Queue Resource

    Get an existing Queue resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: QueueState, opts?: CustomResourceOptions): Queue
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            app_engine_routing_override: Optional[QueueAppEngineRoutingOverrideArgs] = None,
            location: Optional[str] = None,
            name: Optional[str] = None,
            project: Optional[str] = None,
            rate_limits: Optional[QueueRateLimitsArgs] = None,
            retry_config: Optional[QueueRetryConfigArgs] = None,
            stackdriver_logging_config: Optional[QueueStackdriverLoggingConfigArgs] = None) -> Queue
    func GetQueue(ctx *Context, name string, id IDInput, state *QueueState, opts ...ResourceOption) (*Queue, error)
    public static Queue Get(string name, Input<string> id, QueueState? state, CustomResourceOptions? opts = null)
    public static Queue get(String name, Output<String> id, QueueState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AppEngineRoutingOverride QueueAppEngineRoutingOverride
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    Location string
    The location of the queue


    Name string
    The queue name.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    RateLimits QueueRateLimits
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    RetryConfig QueueRetryConfig
    Settings that determine the retry behavior. Structure is documented below.
    StackdriverLoggingConfig QueueStackdriverLoggingConfig
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    AppEngineRoutingOverride QueueAppEngineRoutingOverrideArgs
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    Location string
    The location of the queue


    Name string
    The queue name.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    RateLimits QueueRateLimitsArgs
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    RetryConfig QueueRetryConfigArgs
    Settings that determine the retry behavior. Structure is documented below.
    StackdriverLoggingConfig QueueStackdriverLoggingConfigArgs
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    appEngineRoutingOverride QueueAppEngineRoutingOverride
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    location String
    The location of the queue


    name String
    The queue name.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rateLimits QueueRateLimits
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retryConfig QueueRetryConfig
    Settings that determine the retry behavior. Structure is documented below.
    stackdriverLoggingConfig QueueStackdriverLoggingConfig
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    appEngineRoutingOverride QueueAppEngineRoutingOverride
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    location string
    The location of the queue


    name string
    The queue name.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rateLimits QueueRateLimits
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retryConfig QueueRetryConfig
    Settings that determine the retry behavior. Structure is documented below.
    stackdriverLoggingConfig QueueStackdriverLoggingConfig
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    app_engine_routing_override QueueAppEngineRoutingOverrideArgs
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    location str
    The location of the queue


    name str
    The queue name.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rate_limits QueueRateLimitsArgs
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retry_config QueueRetryConfigArgs
    Settings that determine the retry behavior. Structure is documented below.
    stackdriver_logging_config QueueStackdriverLoggingConfigArgs
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.
    appEngineRoutingOverride Property Map
    Overrides for task-level appEngineRouting. These settings apply only to App Engine tasks in this queue Structure is documented below.
    location String
    The location of the queue


    name String
    The queue name.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    rateLimits Property Map
    Rate limits for task dispatches. The queue's actual dispatch rate is the result of:

    • Number of tasks in the queue
    • User-specified throttling: rateLimits, retryConfig, and the queue's state.
    • System throttling due to 429 (Too Many Requests) or 503 (Service Unavailable) responses from the worker, high error rates, or to smooth sudden large traffic spikes. Structure is documented below.
    retryConfig Property Map
    Settings that determine the retry behavior. Structure is documented below.
    stackdriverLoggingConfig Property Map
    Configuration options for writing logs to Stackdriver Logging. Structure is documented below.

    Supporting Types

    QueueAppEngineRoutingOverride, QueueAppEngineRoutingOverrideArgs

    Host string
    (Output) The host that the task is sent to.
    Instance string
    App instance. By default, the task is sent to an instance which is available when the task is attempted.
    Service string
    App service. By default, the task is sent to the service which is the default service when the task is attempted.
    Version string
    App version. By default, the task is sent to the version which is the default version when the task is attempted.
    Host string
    (Output) The host that the task is sent to.
    Instance string
    App instance. By default, the task is sent to an instance which is available when the task is attempted.
    Service string
    App service. By default, the task is sent to the service which is the default service when the task is attempted.
    Version string
    App version. By default, the task is sent to the version which is the default version when the task is attempted.
    host String
    (Output) The host that the task is sent to.
    instance String
    App instance. By default, the task is sent to an instance which is available when the task is attempted.
    service String
    App service. By default, the task is sent to the service which is the default service when the task is attempted.
    version String
    App version. By default, the task is sent to the version which is the default version when the task is attempted.
    host string
    (Output) The host that the task is sent to.
    instance string
    App instance. By default, the task is sent to an instance which is available when the task is attempted.
    service string
    App service. By default, the task is sent to the service which is the default service when the task is attempted.
    version string
    App version. By default, the task is sent to the version which is the default version when the task is attempted.
    host str
    (Output) The host that the task is sent to.
    instance str
    App instance. By default, the task is sent to an instance which is available when the task is attempted.
    service str
    App service. By default, the task is sent to the service which is the default service when the task is attempted.
    version str
    App version. By default, the task is sent to the version which is the default version when the task is attempted.
    host String
    (Output) The host that the task is sent to.
    instance String
    App instance. By default, the task is sent to an instance which is available when the task is attempted.
    service String
    App service. By default, the task is sent to the service which is the default service when the task is attempted.
    version String
    App version. By default, the task is sent to the version which is the default version when the task is attempted.

    QueueRateLimits, QueueRateLimitsArgs

    MaxBurstSize int
    (Output) The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time.
    MaxConcurrentDispatches int
    The maximum number of concurrent tasks that Cloud Tasks allows to be dispatched for this queue. After this threshold has been reached, Cloud Tasks stops dispatching tasks until the number of concurrent requests decreases.
    MaxDispatchesPerSecond double
    The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default.
    MaxBurstSize int
    (Output) The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time.
    MaxConcurrentDispatches int
    The maximum number of concurrent tasks that Cloud Tasks allows to be dispatched for this queue. After this threshold has been reached, Cloud Tasks stops dispatching tasks until the number of concurrent requests decreases.
    MaxDispatchesPerSecond float64
    The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default.
    maxBurstSize Integer
    (Output) The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time.
    maxConcurrentDispatches Integer
    The maximum number of concurrent tasks that Cloud Tasks allows to be dispatched for this queue. After this threshold has been reached, Cloud Tasks stops dispatching tasks until the number of concurrent requests decreases.
    maxDispatchesPerSecond Double
    The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default.
    maxBurstSize number
    (Output) The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time.
    maxConcurrentDispatches number
    The maximum number of concurrent tasks that Cloud Tasks allows to be dispatched for this queue. After this threshold has been reached, Cloud Tasks stops dispatching tasks until the number of concurrent requests decreases.
    maxDispatchesPerSecond number
    The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default.
    max_burst_size int
    (Output) The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time.
    max_concurrent_dispatches int
    The maximum number of concurrent tasks that Cloud Tasks allows to be dispatched for this queue. After this threshold has been reached, Cloud Tasks stops dispatching tasks until the number of concurrent requests decreases.
    max_dispatches_per_second float
    The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default.
    maxBurstSize Number
    (Output) The max burst size. Max burst size limits how fast tasks in queue are processed when many tasks are in the queue and the rate is high. This field allows the queue to have a high rate so processing starts shortly after a task is enqueued, but still limits resource usage when many tasks are enqueued in a short period of time.
    maxConcurrentDispatches Number
    The maximum number of concurrent tasks that Cloud Tasks allows to be dispatched for this queue. After this threshold has been reached, Cloud Tasks stops dispatching tasks until the number of concurrent requests decreases.
    maxDispatchesPerSecond Number
    The maximum rate at which tasks are dispatched from this queue. If unspecified when the queue is created, Cloud Tasks will pick the default.

    QueueRetryConfig, QueueRetryConfigArgs

    MaxAttempts int
    Number of attempts per task. Cloud Tasks will attempt the task maxAttempts times (that is, if the first attempt fails, then there will be maxAttempts - 1 retries). Must be >= -1. If unspecified when the queue is created, Cloud Tasks will pick the default. -1 indicates unlimited attempts.
    MaxBackoff string
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    MaxDoublings int
    The time between retries will double maxDoublings times. A task's retry interval starts at minBackoff, then doubles maxDoublings times, then increases linearly, and finally retries retries at intervals of maxBackoff up to maxAttempts times.
    MaxRetryDuration string
    If positive, maxRetryDuration specifies the time limit for retrying a failed task, measured from when the task was first attempted. Once maxRetryDuration time has passed and the task has been attempted maxAttempts times, no further attempts will be made and the task will be deleted. If zero, then the task age is unlimited.
    MinBackoff string
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    MaxAttempts int
    Number of attempts per task. Cloud Tasks will attempt the task maxAttempts times (that is, if the first attempt fails, then there will be maxAttempts - 1 retries). Must be >= -1. If unspecified when the queue is created, Cloud Tasks will pick the default. -1 indicates unlimited attempts.
    MaxBackoff string
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    MaxDoublings int
    The time between retries will double maxDoublings times. A task's retry interval starts at minBackoff, then doubles maxDoublings times, then increases linearly, and finally retries retries at intervals of maxBackoff up to maxAttempts times.
    MaxRetryDuration string
    If positive, maxRetryDuration specifies the time limit for retrying a failed task, measured from when the task was first attempted. Once maxRetryDuration time has passed and the task has been attempted maxAttempts times, no further attempts will be made and the task will be deleted. If zero, then the task age is unlimited.
    MinBackoff string
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    maxAttempts Integer
    Number of attempts per task. Cloud Tasks will attempt the task maxAttempts times (that is, if the first attempt fails, then there will be maxAttempts - 1 retries). Must be >= -1. If unspecified when the queue is created, Cloud Tasks will pick the default. -1 indicates unlimited attempts.
    maxBackoff String
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    maxDoublings Integer
    The time between retries will double maxDoublings times. A task's retry interval starts at minBackoff, then doubles maxDoublings times, then increases linearly, and finally retries retries at intervals of maxBackoff up to maxAttempts times.
    maxRetryDuration String
    If positive, maxRetryDuration specifies the time limit for retrying a failed task, measured from when the task was first attempted. Once maxRetryDuration time has passed and the task has been attempted maxAttempts times, no further attempts will be made and the task will be deleted. If zero, then the task age is unlimited.
    minBackoff String
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    maxAttempts number
    Number of attempts per task. Cloud Tasks will attempt the task maxAttempts times (that is, if the first attempt fails, then there will be maxAttempts - 1 retries). Must be >= -1. If unspecified when the queue is created, Cloud Tasks will pick the default. -1 indicates unlimited attempts.
    maxBackoff string
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    maxDoublings number
    The time between retries will double maxDoublings times. A task's retry interval starts at minBackoff, then doubles maxDoublings times, then increases linearly, and finally retries retries at intervals of maxBackoff up to maxAttempts times.
    maxRetryDuration string
    If positive, maxRetryDuration specifies the time limit for retrying a failed task, measured from when the task was first attempted. Once maxRetryDuration time has passed and the task has been attempted maxAttempts times, no further attempts will be made and the task will be deleted. If zero, then the task age is unlimited.
    minBackoff string
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    max_attempts int
    Number of attempts per task. Cloud Tasks will attempt the task maxAttempts times (that is, if the first attempt fails, then there will be maxAttempts - 1 retries). Must be >= -1. If unspecified when the queue is created, Cloud Tasks will pick the default. -1 indicates unlimited attempts.
    max_backoff str
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    max_doublings int
    The time between retries will double maxDoublings times. A task's retry interval starts at minBackoff, then doubles maxDoublings times, then increases linearly, and finally retries retries at intervals of maxBackoff up to maxAttempts times.
    max_retry_duration str
    If positive, maxRetryDuration specifies the time limit for retrying a failed task, measured from when the task was first attempted. Once maxRetryDuration time has passed and the task has been attempted maxAttempts times, no further attempts will be made and the task will be deleted. If zero, then the task age is unlimited.
    min_backoff str
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    maxAttempts Number
    Number of attempts per task. Cloud Tasks will attempt the task maxAttempts times (that is, if the first attempt fails, then there will be maxAttempts - 1 retries). Must be >= -1. If unspecified when the queue is created, Cloud Tasks will pick the default. -1 indicates unlimited attempts.
    maxBackoff String
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.
    maxDoublings Number
    The time between retries will double maxDoublings times. A task's retry interval starts at minBackoff, then doubles maxDoublings times, then increases linearly, and finally retries retries at intervals of maxBackoff up to maxAttempts times.
    maxRetryDuration String
    If positive, maxRetryDuration specifies the time limit for retrying a failed task, measured from when the task was first attempted. Once maxRetryDuration time has passed and the task has been attempted maxAttempts times, no further attempts will be made and the task will be deleted. If zero, then the task age is unlimited.
    minBackoff String
    A task will be scheduled for retry between minBackoff and maxBackoff duration after it fails, if the queue's RetryConfig specifies that the task should be retried.

    QueueStackdriverLoggingConfig, QueueStackdriverLoggingConfigArgs

    SamplingRatio double
    Specifies the fraction of operations to write to Stackdriver Logging. This field may contain any value between 0.0 and 1.0, inclusive. 0.0 is the default and means that no operations are logged.
    SamplingRatio float64
    Specifies the fraction of operations to write to Stackdriver Logging. This field may contain any value between 0.0 and 1.0, inclusive. 0.0 is the default and means that no operations are logged.
    samplingRatio Double
    Specifies the fraction of operations to write to Stackdriver Logging. This field may contain any value between 0.0 and 1.0, inclusive. 0.0 is the default and means that no operations are logged.
    samplingRatio number
    Specifies the fraction of operations to write to Stackdriver Logging. This field may contain any value between 0.0 and 1.0, inclusive. 0.0 is the default and means that no operations are logged.
    sampling_ratio float
    Specifies the fraction of operations to write to Stackdriver Logging. This field may contain any value between 0.0 and 1.0, inclusive. 0.0 is the default and means that no operations are logged.
    samplingRatio Number
    Specifies the fraction of operations to write to Stackdriver Logging. This field may contain any value between 0.0 and 1.0, inclusive. 0.0 is the default and means that no operations are logged.

    Import

    Queue can be imported using any of these accepted formats:

    • projects/{{project}}/locations/{{location}}/queues/{{name}}

    • {{project}}/{{location}}/{{name}}

    • {{location}}/{{name}}

    When using the pulumi import command, Queue can be imported using one of the formats above. For example:

    $ pulumi import gcp:cloudtasks/queue:Queue default projects/{{project}}/locations/{{location}}/queues/{{name}}
    
    $ pulumi import gcp:cloudtasks/queue:Queue default {{project}}/{{location}}/{{name}}
    
    $ pulumi import gcp:cloudtasks/queue:Queue default {{location}}/{{name}}
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Google Cloud Classic v7.29.0 published on Wednesday, Jun 26, 2024 by Pulumi