// *** 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! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;
using Pulumi;

namespace TencentCloudIAC.PulumiPackage.Tencentcloud.Tcm
{
    /// <summary>
    /// Provides a resource to create a tcm prometheus_attachment
    /// 
    /// &gt; **NOTE:** Instructions for use: 1. Use Tencent Cloud Prometheus to monitor TMP, please enter `vpc_id`, `subnet_id`, `region` or `instance_id`, it is recommended to use an existing tmp instance; 2. To use the third-party Prometheus service, please enter `custom_prom`; 3. `tencentcloud.Tcm.PrometheusAttachment` does not support modification; 4. If you use Tencent Cloud Prometheus to monitor TMP, enter `vpc_id`, `subnet_id`, `region` to create a new Prometheus monitoring instance, destroy will not destroy the Prometheus monitoring instance
    /// **NOTE:** If you use the config attribute prometheus in tencentcloud_tcm_mesh, do not use tencentcloud.Tcm.PrometheusAttachment
    /// 
    /// ## Example Usage
    /// 
    /// ```csharp
    /// using Pulumi;
    /// using Tencentcloud = TencentCloudIAC.PulumiPackage.Tencentcloud;
    /// 
    /// class MyStack : Stack
    /// {
    ///     public MyStack()
    ///     {
    ///         var prometheusAttachment = new Tencentcloud.Tcm.PrometheusAttachment("prometheusAttachment", new Tencentcloud.Tcm.PrometheusAttachmentArgs
    ///         {
    ///             MeshId = "mesh-rofjmxxx",
    ///             Prometheus = new Tencentcloud.Tcm.Inputs.PrometheusAttachmentPrometheusArgs
    ///             {
    ///                 InstanceId = "",
    ///                 Region = "ap-guangzhou",
    ///                 SubnetId = "subnet-driddxxx",
    ///                 VpcId = "vpc-pewdpxxx",
    ///             },
    ///         });
    ///     }
    /// 
    /// }
    /// ```
    /// 
    /// ## Import
    /// 
    /// tcm prometheus_attachment can be imported using the mesh_id, e.g.
    /// 
    /// ```sh
    ///  $ pulumi import tencentcloud:Tcm/prometheusAttachment:PrometheusAttachment prometheus_attachment mesh-rofjmxxx
    /// ```
    /// </summary>
    [TencentcloudResourceType("tencentcloud:Tcm/prometheusAttachment:PrometheusAttachment")]
    public partial class PrometheusAttachment : Pulumi.CustomResource
    {
        /// <summary>
        /// Mesh ID.
        /// </summary>
        [Output("meshId")]
        public Output<string> MeshId { get; private set; } = null!;

        /// <summary>
        /// Prometheus configuration.
        /// </summary>
        [Output("prometheus")]
        public Output<Outputs.PrometheusAttachmentPrometheus> Prometheus { get; private set; } = null!;


        /// <summary>
        /// Create a PrometheusAttachment resource with the given unique name, arguments, and options.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resource</param>
        /// <param name="args">The arguments used to populate this resource's properties</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public PrometheusAttachment(string name, PrometheusAttachmentArgs args, CustomResourceOptions? options = null)
            : base("tencentcloud:Tcm/prometheusAttachment:PrometheusAttachment", name, args ?? new PrometheusAttachmentArgs(), MakeResourceOptions(options, ""))
        {
        }

        private PrometheusAttachment(string name, Input<string> id, PrometheusAttachmentState? state = null, CustomResourceOptions? options = null)
            : base("tencentcloud:Tcm/prometheusAttachment:PrometheusAttachment", name, state, MakeResourceOptions(options, id))
        {
        }

        private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
        {
            var defaultOptions = new CustomResourceOptions
            {
                Version = Utilities.Version,
                PluginDownloadURL = "github://api.github.com/tencentcloudstack",
            };
            var merged = CustomResourceOptions.Merge(defaultOptions, options);
            // Override the ID if one was specified for consistency with other language SDKs.
            merged.Id = id ?? merged.Id;
            return merged;
        }
        /// <summary>
        /// Get an existing PrometheusAttachment resource's state with the given name, ID, and optional extra
        /// properties used to qualify the lookup.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resulting resource.</param>
        /// <param name="id">The unique provider ID of the resource to lookup.</param>
        /// <param name="state">Any extra arguments used during the lookup.</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public static PrometheusAttachment Get(string name, Input<string> id, PrometheusAttachmentState? state = null, CustomResourceOptions? options = null)
        {
            return new PrometheusAttachment(name, id, state, options);
        }
    }

    public sealed class PrometheusAttachmentArgs : Pulumi.ResourceArgs
    {
        /// <summary>
        /// Mesh ID.
        /// </summary>
        [Input("meshId", required: true)]
        public Input<string> MeshId { get; set; } = null!;

        /// <summary>
        /// Prometheus configuration.
        /// </summary>
        [Input("prometheus", required: true)]
        public Input<Inputs.PrometheusAttachmentPrometheusArgs> Prometheus { get; set; } = null!;

        public PrometheusAttachmentArgs()
        {
        }
    }

    public sealed class PrometheusAttachmentState : Pulumi.ResourceArgs
    {
        /// <summary>
        /// Mesh ID.
        /// </summary>
        [Input("meshId")]
        public Input<string>? MeshId { get; set; }

        /// <summary>
        /// Prometheus configuration.
        /// </summary>
        [Input("prometheus")]
        public Input<Inputs.PrometheusAttachmentPrometheusGetArgs>? Prometheus { get; set; }

        public PrometheusAttachmentState()
        {
        }
    }
}
