"use strict";
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.TaskSet = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * Create a task set in the specified cluster and service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.htmlin the Amazon Elastic Container Service Developer Guide.
 */
class TaskSet extends pulumi.CustomResource {
    /**
     * Get an existing TaskSet 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 opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, opts) {
        return new TaskSet(name, undefined, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of TaskSet.  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'] === TaskSet.__pulumiType;
    }
    /**
     * Create a TaskSet resource with the given unique name, arguments, and options.
     *
     * @param name The _unique_ name of the resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param opts A bag of options that control this resource's behavior.
     */
    constructor(name, args, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (!opts.id) {
            if (args?.cluster === undefined && !opts.urn) {
                throw new Error("Missing required property 'cluster'");
            }
            if (args?.service === undefined && !opts.urn) {
                throw new Error("Missing required property 'service'");
            }
            if (args?.taskDefinition === undefined && !opts.urn) {
                throw new Error("Missing required property 'taskDefinition'");
            }
            resourceInputs["capacityProviderStrategy"] = args?.capacityProviderStrategy;
            resourceInputs["cluster"] = args?.cluster;
            resourceInputs["externalId"] = args?.externalId;
            resourceInputs["launchType"] = args?.launchType;
            resourceInputs["loadBalancers"] = args?.loadBalancers;
            resourceInputs["networkConfiguration"] = args?.networkConfiguration;
            resourceInputs["platformVersion"] = args?.platformVersion;
            resourceInputs["scale"] = args?.scale;
            resourceInputs["service"] = args?.service;
            resourceInputs["serviceRegistries"] = args?.serviceRegistries;
            resourceInputs["tags"] = args?.tags;
            resourceInputs["taskDefinition"] = args?.taskDefinition;
            resourceInputs["awsId"] = undefined /*out*/;
        }
        else {
            resourceInputs["awsId"] = undefined /*out*/;
            resourceInputs["capacityProviderStrategy"] = undefined /*out*/;
            resourceInputs["cluster"] = undefined /*out*/;
            resourceInputs["externalId"] = undefined /*out*/;
            resourceInputs["launchType"] = undefined /*out*/;
            resourceInputs["loadBalancers"] = undefined /*out*/;
            resourceInputs["networkConfiguration"] = undefined /*out*/;
            resourceInputs["platformVersion"] = undefined /*out*/;
            resourceInputs["scale"] = undefined /*out*/;
            resourceInputs["service"] = undefined /*out*/;
            resourceInputs["serviceRegistries"] = undefined /*out*/;
            resourceInputs["tags"] = undefined /*out*/;
            resourceInputs["taskDefinition"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        const replaceOnChanges = { replaceOnChanges: ["capacityProviderStrategy[*]", "cluster", "externalId", "launchType", "loadBalancers[*]", "networkConfiguration", "platformVersion", "service", "serviceRegistries[*]", "taskDefinition"] };
        opts = pulumi.mergeOptions(opts, replaceOnChanges);
        super(TaskSet.__pulumiType, name, resourceInputs, opts);
    }
}
exports.TaskSet = TaskSet;
/** @internal */
TaskSet.__pulumiType = 'aws-native:ecs:TaskSet';
//# sourceMappingURL=taskSet.js.map