UNPKG

@volcengine/pulumi

Version:

A Pulumi package for creating and managing volcengine cloud resources.

125 lines 5.87 kB
"use strict"; // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.DownloadTask = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Provides a resource to manage tls download task * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as volcengine from "@volcengine/pulumi"; * * const foo = new volcengine.tls.DownloadTask("foo", { * topicId: "36be6c75-0733-4bee-b63d-48e0eae37f87", * taskName: "tf-test-download-task", * query: "*", * startTime: 1740426022, * endTime: 1740626022, * compression: "gzip", * dataFormat: "json", * limit: 10000000, * sort: "desc", * allowIncomplete: false, * taskType: 1, * logContextInfos: {}, * }); * export const tlsDownloadTaskId = foo.taskId; * ``` * * ## Import * * tls download task can be imported using the id, e.g. * * ```sh * $ pulumi import volcengine:tls/downloadTask:DownloadTask default task-1234567890 * ``` */ class DownloadTask extends pulumi.CustomResource { /** * Get an existing DownloadTask resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name, id, state, opts) { return new DownloadTask(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of DownloadTask. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === DownloadTask.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["allowIncomplete"] = state ? state.allowIncomplete : undefined; resourceInputs["compression"] = state ? state.compression : undefined; resourceInputs["dataFormat"] = state ? state.dataFormat : undefined; resourceInputs["downloadUrl"] = state ? state.downloadUrl : undefined; resourceInputs["endTime"] = state ? state.endTime : undefined; resourceInputs["limit"] = state ? state.limit : undefined; resourceInputs["logContextInfos"] = state ? state.logContextInfos : undefined; resourceInputs["query"] = state ? state.query : undefined; resourceInputs["sort"] = state ? state.sort : undefined; resourceInputs["startTime"] = state ? state.startTime : undefined; resourceInputs["taskId"] = state ? state.taskId : undefined; resourceInputs["taskName"] = state ? state.taskName : undefined; resourceInputs["taskStatus"] = state ? state.taskStatus : undefined; resourceInputs["taskType"] = state ? state.taskType : undefined; resourceInputs["topicId"] = state ? state.topicId : undefined; } else { const args = argsOrState; if ((!args || args.endTime === undefined) && !opts.urn) { throw new Error("Missing required property 'endTime'"); } if ((!args || args.startTime === undefined) && !opts.urn) { throw new Error("Missing required property 'startTime'"); } if ((!args || args.taskName === undefined) && !opts.urn) { throw new Error("Missing required property 'taskName'"); } if ((!args || args.taskType === undefined) && !opts.urn) { throw new Error("Missing required property 'taskType'"); } if ((!args || args.topicId === undefined) && !opts.urn) { throw new Error("Missing required property 'topicId'"); } resourceInputs["allowIncomplete"] = args ? args.allowIncomplete : undefined; resourceInputs["compression"] = args ? args.compression : undefined; resourceInputs["dataFormat"] = args ? args.dataFormat : undefined; resourceInputs["endTime"] = args ? args.endTime : undefined; resourceInputs["limit"] = args ? args.limit : undefined; resourceInputs["logContextInfos"] = args ? args.logContextInfos : undefined; resourceInputs["query"] = args ? args.query : undefined; resourceInputs["sort"] = args ? args.sort : undefined; resourceInputs["startTime"] = args ? args.startTime : undefined; resourceInputs["taskName"] = args ? args.taskName : undefined; resourceInputs["taskType"] = args ? args.taskType : undefined; resourceInputs["topicId"] = args ? args.topicId : undefined; resourceInputs["downloadUrl"] = undefined /*out*/; resourceInputs["taskId"] = undefined /*out*/; resourceInputs["taskStatus"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(DownloadTask.__pulumiType, name, resourceInputs, opts); } } exports.DownloadTask = DownloadTask; /** @internal */ DownloadTask.__pulumiType = 'volcengine:tls/downloadTask:DownloadTask'; //# sourceMappingURL=downloadTask.js.map