"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! ***
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
    __setModuleDefault(result, mod);
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.InvokeRun = void 0;
const pulumi = __importStar(require("@pulumi/pulumi"));
const utilities = __importStar(require("../utilities"));
/**
 * This resource provides the Invoke Run resource in Oracle Cloud Infrastructure Data Flow service.
 * Api doc link for the resource: https://docs.oracle.com/iaas/api/#/en/data-flow/latest/InvokeRun
 *
 * Example terraform configs related to the resource : https://github.com/oracle/terraform-provider-oci/tree/master/examples/dataflow
 *
 * Creates a run for an application.
 *
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as oci from "@pulumi/oci";
 *
 * const testInvokeRun = new oci.dataflow.InvokeRun("test_invoke_run", {
 *     compartmentId: compartmentId,
 *     applicationId: testApplication.id,
 *     applicationLogConfig: {
 *         logGroupId: testLogGroup.id,
 *         logId: testLog.id,
 *     },
 *     archiveUri: invokeRunArchiveUri,
 *     arguments: invokeRunArguments,
 *     configuration: invokeRunConfiguration,
 *     definedTags: {
 *         "Operations.CostCenter": "42",
 *     },
 *     displayName: invokeRunDisplayName,
 *     driverShape: invokeRunDriverShape,
 *     driverShapeConfig: {
 *         memoryInGbs: invokeRunDriverShapeConfigMemoryInGbs,
 *         ocpus: invokeRunDriverShapeConfigOcpus,
 *     },
 *     execute: invokeRunExecute,
 *     executorShape: invokeRunExecutorShape,
 *     executorShapeConfig: {
 *         memoryInGbs: invokeRunExecutorShapeConfigMemoryInGbs,
 *         ocpus: invokeRunExecutorShapeConfigOcpus,
 *     },
 *     freeformTags: {
 *         Department: "Finance",
 *     },
 *     idleTimeoutInMinutes: invokeRunIdleTimeoutInMinutes,
 *     logsBucketUri: invokeRunLogsBucketUri,
 *     maxDurationInMinutes: invokeRunMaxDurationInMinutes,
 *     metastoreId: metastoreId,
 *     numExecutors: Number(invokeRunNumExecutors),
 *     opcParentRptUrl: invokeRunOpcParentRptUrl,
 *     parameters: [{
 *         name: invokeRunParametersName,
 *         value: invokeRunParametersValue,
 *     }],
 *     poolId: testPool.id,
 *     sparkVersion: invokeRunSparkVersion,
 *     type: invokeRunType,
 *     warehouseBucketUri: invokeRunWarehouseBucketUri,
 * });
 * ```
 *
 * ## Note
 *
 * At a time service allows only one run to succeed if user is trying to invoke runs on multiple applications which have Private Endpoints and service will proceed invoking only one run and put the rest of them in failed state.
 *
 * ## Import
 *
 * InvokeRuns can be imported using the `id`, e.g.
 *
 * ```sh
 * $ pulumi import oci:DataFlow/invokeRun:InvokeRun test_invoke_run "id"
 * ```
 */
class InvokeRun extends pulumi.CustomResource {
    /**
     * Get an existing InvokeRun 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 InvokeRun(name, state, { ...opts, id: id });
    }
    /** @internal */
    static __pulumiType = 'oci:DataFlow/invokeRun:InvokeRun';
    /**
     * Returns true if the given object is an instance of InvokeRun.  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'] === InvokeRun.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["applicationId"] = state?.applicationId;
            resourceInputs["applicationLogConfig"] = state?.applicationLogConfig;
            resourceInputs["archiveUri"] = state?.archiveUri;
            resourceInputs["arguments"] = state?.arguments;
            resourceInputs["asynchronous"] = state?.asynchronous;
            resourceInputs["className"] = state?.className;
            resourceInputs["compartmentId"] = state?.compartmentId;
            resourceInputs["configuration"] = state?.configuration;
            resourceInputs["dataReadInBytes"] = state?.dataReadInBytes;
            resourceInputs["dataWrittenInBytes"] = state?.dataWrittenInBytes;
            resourceInputs["definedTags"] = state?.definedTags;
            resourceInputs["displayName"] = state?.displayName;
            resourceInputs["driverShape"] = state?.driverShape;
            resourceInputs["driverShapeConfig"] = state?.driverShapeConfig;
            resourceInputs["execute"] = state?.execute;
            resourceInputs["executorShape"] = state?.executorShape;
            resourceInputs["executorShapeConfig"] = state?.executorShapeConfig;
            resourceInputs["fileUri"] = state?.fileUri;
            resourceInputs["freeformTags"] = state?.freeformTags;
            resourceInputs["idleTimeoutInMinutes"] = state?.idleTimeoutInMinutes;
            resourceInputs["language"] = state?.language;
            resourceInputs["lifecycleDetails"] = state?.lifecycleDetails;
            resourceInputs["logsBucketUri"] = state?.logsBucketUri;
            resourceInputs["maxDurationInMinutes"] = state?.maxDurationInMinutes;
            resourceInputs["metastoreId"] = state?.metastoreId;
            resourceInputs["numExecutors"] = state?.numExecutors;
            resourceInputs["opcParentRptUrl"] = state?.opcParentRptUrl;
            resourceInputs["opcRequestId"] = state?.opcRequestId;
            resourceInputs["ownerPrincipalId"] = state?.ownerPrincipalId;
            resourceInputs["ownerUserName"] = state?.ownerUserName;
            resourceInputs["parameters"] = state?.parameters;
            resourceInputs["poolId"] = state?.poolId;
            resourceInputs["privateEndpointDnsZones"] = state?.privateEndpointDnsZones;
            resourceInputs["privateEndpointId"] = state?.privateEndpointId;
            resourceInputs["privateEndpointMaxHostCount"] = state?.privateEndpointMaxHostCount;
            resourceInputs["privateEndpointNsgIds"] = state?.privateEndpointNsgIds;
            resourceInputs["privateEndpointSubnetId"] = state?.privateEndpointSubnetId;
            resourceInputs["runDurationInMilliseconds"] = state?.runDurationInMilliseconds;
            resourceInputs["sparkVersion"] = state?.sparkVersion;
            resourceInputs["state"] = state?.state;
            resourceInputs["timeCreated"] = state?.timeCreated;
            resourceInputs["timeUpdated"] = state?.timeUpdated;
            resourceInputs["totalOcpu"] = state?.totalOcpu;
            resourceInputs["type"] = state?.type;
            resourceInputs["warehouseBucketUri"] = state?.warehouseBucketUri;
        }
        else {
            const args = argsOrState;
            if (args?.compartmentId === undefined && !opts.urn) {
                throw new Error("Missing required property 'compartmentId'");
            }
            resourceInputs["applicationId"] = args?.applicationId;
            resourceInputs["applicationLogConfig"] = args?.applicationLogConfig;
            resourceInputs["archiveUri"] = args?.archiveUri;
            resourceInputs["arguments"] = args?.arguments;
            resourceInputs["asynchronous"] = args?.asynchronous;
            resourceInputs["compartmentId"] = args?.compartmentId;
            resourceInputs["configuration"] = args?.configuration;
            resourceInputs["definedTags"] = args?.definedTags;
            resourceInputs["displayName"] = args?.displayName;
            resourceInputs["driverShape"] = args?.driverShape;
            resourceInputs["driverShapeConfig"] = args?.driverShapeConfig;
            resourceInputs["execute"] = args?.execute;
            resourceInputs["executorShape"] = args?.executorShape;
            resourceInputs["executorShapeConfig"] = args?.executorShapeConfig;
            resourceInputs["freeformTags"] = args?.freeformTags;
            resourceInputs["idleTimeoutInMinutes"] = args?.idleTimeoutInMinutes;
            resourceInputs["logsBucketUri"] = args?.logsBucketUri;
            resourceInputs["maxDurationInMinutes"] = args?.maxDurationInMinutes;
            resourceInputs["metastoreId"] = args?.metastoreId;
            resourceInputs["numExecutors"] = args?.numExecutors;
            resourceInputs["opcParentRptUrl"] = args?.opcParentRptUrl;
            resourceInputs["parameters"] = args?.parameters;
            resourceInputs["poolId"] = args?.poolId;
            resourceInputs["sparkVersion"] = args?.sparkVersion;
            resourceInputs["type"] = args?.type;
            resourceInputs["warehouseBucketUri"] = args?.warehouseBucketUri;
            resourceInputs["className"] = undefined /*out*/;
            resourceInputs["dataReadInBytes"] = undefined /*out*/;
            resourceInputs["dataWrittenInBytes"] = undefined /*out*/;
            resourceInputs["fileUri"] = undefined /*out*/;
            resourceInputs["language"] = undefined /*out*/;
            resourceInputs["lifecycleDetails"] = undefined /*out*/;
            resourceInputs["opcRequestId"] = undefined /*out*/;
            resourceInputs["ownerPrincipalId"] = undefined /*out*/;
            resourceInputs["ownerUserName"] = undefined /*out*/;
            resourceInputs["privateEndpointDnsZones"] = undefined /*out*/;
            resourceInputs["privateEndpointId"] = undefined /*out*/;
            resourceInputs["privateEndpointMaxHostCount"] = undefined /*out*/;
            resourceInputs["privateEndpointNsgIds"] = undefined /*out*/;
            resourceInputs["privateEndpointSubnetId"] = undefined /*out*/;
            resourceInputs["runDurationInMilliseconds"] = undefined /*out*/;
            resourceInputs["state"] = undefined /*out*/;
            resourceInputs["timeCreated"] = undefined /*out*/;
            resourceInputs["timeUpdated"] = undefined /*out*/;
            resourceInputs["totalOcpu"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(InvokeRun.__pulumiType, name, resourceInputs, opts);
    }
}
exports.InvokeRun = InvokeRun;
//# sourceMappingURL=invokeRun.js.map