1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. ClsLogset
tencentcloud 1.81.185 published on Wednesday, Apr 23, 2025 by tencentcloudstack

tencentcloud.ClsLogset

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.185 published on Wednesday, Apr 23, 2025 by tencentcloudstack

    Provides a resource to create a CLS logset

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const example = new tencentcloud.ClsLogset("example", {
        logsetName: "tf-example",
        tags: {
            createdBy: "Terraform",
        },
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    example = tencentcloud.ClsLogset("example",
        logset_name="tf-example",
        tags={
            "createdBy": "Terraform",
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewClsLogset(ctx, "example", &tencentcloud.ClsLogsetArgs{
    			LogsetName: pulumi.String("tf-example"),
    			Tags: pulumi.StringMap{
    				"createdBy": pulumi.String("Terraform"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Tencentcloud.ClsLogset("example", new()
        {
            LogsetName = "tf-example",
            Tags = 
            {
                { "createdBy", "Terraform" },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.ClsLogset;
    import com.pulumi.tencentcloud.ClsLogsetArgs;
    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 example = new ClsLogset("example", ClsLogsetArgs.builder()
                .logsetName("tf-example")
                .tags(Map.of("createdBy", "Terraform"))
                .build());
    
        }
    }
    
    resources:
      example:
        type: tencentcloud:ClsLogset
        properties:
          logsetName: tf-example
          tags:
            createdBy: Terraform
    

    Create ClsLogset Resource

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

    Constructor syntax

    new ClsLogset(name: string, args: ClsLogsetArgs, opts?: CustomResourceOptions);
    @overload
    def ClsLogset(resource_name: str,
                  args: ClsLogsetArgs,
                  opts: Optional[ResourceOptions] = None)
    
    @overload
    def ClsLogset(resource_name: str,
                  opts: Optional[ResourceOptions] = None,
                  logset_name: Optional[str] = None,
                  cls_logset_id: Optional[str] = None,
                  tags: Optional[Mapping[str, str]] = None)
    func NewClsLogset(ctx *Context, name string, args ClsLogsetArgs, opts ...ResourceOption) (*ClsLogset, error)
    public ClsLogset(string name, ClsLogsetArgs args, CustomResourceOptions? opts = null)
    public ClsLogset(String name, ClsLogsetArgs args)
    public ClsLogset(String name, ClsLogsetArgs args, CustomResourceOptions options)
    
    type: tencentcloud:ClsLogset
    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 ClsLogsetArgs
    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 ClsLogsetArgs
    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 ClsLogsetArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ClsLogsetArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ClsLogsetArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    ClsLogset Resource Properties

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

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The ClsLogset resource accepts the following input properties:

    LogsetName string
    Logset name, which must be unique.
    ClsLogsetId string
    ID of the resource.
    Tags Dictionary<string, string>
    Tag description list.
    LogsetName string
    Logset name, which must be unique.
    ClsLogsetId string
    ID of the resource.
    Tags map[string]string
    Tag description list.
    logsetName String
    Logset name, which must be unique.
    clsLogsetId String
    ID of the resource.
    tags Map<String,String>
    Tag description list.
    logsetName string
    Logset name, which must be unique.
    clsLogsetId string
    ID of the resource.
    tags {[key: string]: string}
    Tag description list.
    logset_name str
    Logset name, which must be unique.
    cls_logset_id str
    ID of the resource.
    tags Mapping[str, str]
    Tag description list.
    logsetName String
    Logset name, which must be unique.
    clsLogsetId String
    ID of the resource.
    tags Map<String>
    Tag description list.

    Outputs

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

    CreateTime string
    Creation time.
    Id string
    The provider-assigned unique ID for this managed resource.
    RoleName string
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    TopicCount double
    Number of log topics in logset.
    CreateTime string
    Creation time.
    Id string
    The provider-assigned unique ID for this managed resource.
    RoleName string
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    TopicCount float64
    Number of log topics in logset.
    createTime String
    Creation time.
    id String
    The provider-assigned unique ID for this managed resource.
    roleName String
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    topicCount Double
    Number of log topics in logset.
    createTime string
    Creation time.
    id string
    The provider-assigned unique ID for this managed resource.
    roleName string
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    topicCount number
    Number of log topics in logset.
    create_time str
    Creation time.
    id str
    The provider-assigned unique ID for this managed resource.
    role_name str
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    topic_count float
    Number of log topics in logset.
    createTime String
    Creation time.
    id String
    The provider-assigned unique ID for this managed resource.
    roleName String
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    topicCount Number
    Number of log topics in logset.

    Look up Existing ClsLogset Resource

    Get an existing ClsLogset 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?: ClsLogsetState, opts?: CustomResourceOptions): ClsLogset
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            cls_logset_id: Optional[str] = None,
            create_time: Optional[str] = None,
            logset_name: Optional[str] = None,
            role_name: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None,
            topic_count: Optional[float] = None) -> ClsLogset
    func GetClsLogset(ctx *Context, name string, id IDInput, state *ClsLogsetState, opts ...ResourceOption) (*ClsLogset, error)
    public static ClsLogset Get(string name, Input<string> id, ClsLogsetState? state, CustomResourceOptions? opts = null)
    public static ClsLogset get(String name, Output<String> id, ClsLogsetState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:ClsLogset    get:      id: ${id}
    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:
    ClsLogsetId string
    ID of the resource.
    CreateTime string
    Creation time.
    LogsetName string
    Logset name, which must be unique.
    RoleName string
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    Tags Dictionary<string, string>
    Tag description list.
    TopicCount double
    Number of log topics in logset.
    ClsLogsetId string
    ID of the resource.
    CreateTime string
    Creation time.
    LogsetName string
    Logset name, which must be unique.
    RoleName string
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    Tags map[string]string
    Tag description list.
    TopicCount float64
    Number of log topics in logset.
    clsLogsetId String
    ID of the resource.
    createTime String
    Creation time.
    logsetName String
    Logset name, which must be unique.
    roleName String
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    tags Map<String,String>
    Tag description list.
    topicCount Double
    Number of log topics in logset.
    clsLogsetId string
    ID of the resource.
    createTime string
    Creation time.
    logsetName string
    Logset name, which must be unique.
    roleName string
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    tags {[key: string]: string}
    Tag description list.
    topicCount number
    Number of log topics in logset.
    cls_logset_id str
    ID of the resource.
    create_time str
    Creation time.
    logset_name str
    Logset name, which must be unique.
    role_name str
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    tags Mapping[str, str]
    Tag description list.
    topic_count float
    Number of log topics in logset.
    clsLogsetId String
    ID of the resource.
    createTime String
    Creation time.
    logsetName String
    Logset name, which must be unique.
    roleName String
    If assumer_uin is not empty, it indicates the service provider who creates the logset.
    tags Map<String>
    Tag description list.
    topicCount Number
    Number of log topics in logset.

    Import

    CLS logset can be imported using the id, e.g.

    $ pulumi import tencentcloud:index/clsLogset:ClsLogset example 698902ff-8b5a-4c65-824b-d8956f366351
    

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

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    tencentcloud logo
    tencentcloud 1.81.185 published on Wednesday, Apr 23, 2025 by tencentcloudstack