1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. CynosdbExportInstanceSlowQueries
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.CynosdbExportInstanceSlowQueries

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Provides a resource to create a cynosdb export_instance_slow_queries

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const exportInstanceSlowQueries = new tencentcloud.CynosdbExportInstanceSlowQueries("exportInstanceSlowQueries", {
        database: "db1",
        endTime: "2022-01-01 14:00:00",
        fileType: "csv",
        host: "10.10.10.10",
        instanceId: "cynosdbmysql-ins-123",
        startTime: "2022-01-01 12:00:00",
        username: "root",
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    export_instance_slow_queries = tencentcloud.CynosdbExportInstanceSlowQueries("exportInstanceSlowQueries",
        database="db1",
        end_time="2022-01-01 14:00:00",
        file_type="csv",
        host="10.10.10.10",
        instance_id="cynosdbmysql-ins-123",
        start_time="2022-01-01 12:00:00",
        username="root")
    
    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.NewCynosdbExportInstanceSlowQueries(ctx, "exportInstanceSlowQueries", &tencentcloud.CynosdbExportInstanceSlowQueriesArgs{
    			Database:   pulumi.String("db1"),
    			EndTime:    pulumi.String("2022-01-01 14:00:00"),
    			FileType:   pulumi.String("csv"),
    			Host:       pulumi.String("10.10.10.10"),
    			InstanceId: pulumi.String("cynosdbmysql-ins-123"),
    			StartTime:  pulumi.String("2022-01-01 12:00:00"),
    			Username:   pulumi.String("root"),
    		})
    		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 exportInstanceSlowQueries = new Tencentcloud.CynosdbExportInstanceSlowQueries("exportInstanceSlowQueries", new()
        {
            Database = "db1",
            EndTime = "2022-01-01 14:00:00",
            FileType = "csv",
            Host = "10.10.10.10",
            InstanceId = "cynosdbmysql-ins-123",
            StartTime = "2022-01-01 12:00:00",
            Username = "root",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.CynosdbExportInstanceSlowQueries;
    import com.pulumi.tencentcloud.CynosdbExportInstanceSlowQueriesArgs;
    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 exportInstanceSlowQueries = new CynosdbExportInstanceSlowQueries("exportInstanceSlowQueries", CynosdbExportInstanceSlowQueriesArgs.builder()
                .database("db1")
                .endTime("2022-01-01 14:00:00")
                .fileType("csv")
                .host("10.10.10.10")
                .instanceId("cynosdbmysql-ins-123")
                .startTime("2022-01-01 12:00:00")
                .username("root")
                .build());
    
        }
    }
    
    resources:
      exportInstanceSlowQueries:
        type: tencentcloud:CynosdbExportInstanceSlowQueries
        properties:
          database: db1
          endTime: 2022-01-01 14:00:00
          fileType: csv
          host: 10.10.10.10
          instanceId: cynosdbmysql-ins-123
          startTime: 2022-01-01 12:00:00
          username: root
    

    Create CynosdbExportInstanceSlowQueries Resource

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

    Constructor syntax

    new CynosdbExportInstanceSlowQueries(name: string, args: CynosdbExportInstanceSlowQueriesArgs, opts?: CustomResourceOptions);
    @overload
    def CynosdbExportInstanceSlowQueries(resource_name: str,
                                         args: CynosdbExportInstanceSlowQueriesArgs,
                                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def CynosdbExportInstanceSlowQueries(resource_name: str,
                                         opts: Optional[ResourceOptions] = None,
                                         instance_id: Optional[str] = None,
                                         cynosdb_export_instance_slow_queries_id: Optional[str] = None,
                                         database: Optional[str] = None,
                                         end_time: Optional[str] = None,
                                         file_type: Optional[str] = None,
                                         host: Optional[str] = None,
                                         start_time: Optional[str] = None,
                                         username: Optional[str] = None)
    func NewCynosdbExportInstanceSlowQueries(ctx *Context, name string, args CynosdbExportInstanceSlowQueriesArgs, opts ...ResourceOption) (*CynosdbExportInstanceSlowQueries, error)
    public CynosdbExportInstanceSlowQueries(string name, CynosdbExportInstanceSlowQueriesArgs args, CustomResourceOptions? opts = null)
    public CynosdbExportInstanceSlowQueries(String name, CynosdbExportInstanceSlowQueriesArgs args)
    public CynosdbExportInstanceSlowQueries(String name, CynosdbExportInstanceSlowQueriesArgs args, CustomResourceOptions options)
    
    type: tencentcloud:CynosdbExportInstanceSlowQueries
    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 CynosdbExportInstanceSlowQueriesArgs
    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 CynosdbExportInstanceSlowQueriesArgs
    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 CynosdbExportInstanceSlowQueriesArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args CynosdbExportInstanceSlowQueriesArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args CynosdbExportInstanceSlowQueriesArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    CynosdbExportInstanceSlowQueries 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 CynosdbExportInstanceSlowQueries resource accepts the following input properties:

    InstanceId string
    Instance ID.
    CynosdbExportInstanceSlowQueriesId string
    ID of the resource.
    Database string
    Database name.
    EndTime string
    Latest transaction start time.
    FileType string
    File type, optional values: csv, original.
    Host string
    Client host.
    StartTime string
    Earliest transaction start time.
    Username string
    user name.
    InstanceId string
    Instance ID.
    CynosdbExportInstanceSlowQueriesId string
    ID of the resource.
    Database string
    Database name.
    EndTime string
    Latest transaction start time.
    FileType string
    File type, optional values: csv, original.
    Host string
    Client host.
    StartTime string
    Earliest transaction start time.
    Username string
    user name.
    instanceId String
    Instance ID.
    cynosdbExportInstanceSlowQueriesId String
    ID of the resource.
    database String
    Database name.
    endTime String
    Latest transaction start time.
    fileType String
    File type, optional values: csv, original.
    host String
    Client host.
    startTime String
    Earliest transaction start time.
    username String
    user name.
    instanceId string
    Instance ID.
    cynosdbExportInstanceSlowQueriesId string
    ID of the resource.
    database string
    Database name.
    endTime string
    Latest transaction start time.
    fileType string
    File type, optional values: csv, original.
    host string
    Client host.
    startTime string
    Earliest transaction start time.
    username string
    user name.
    instance_id str
    Instance ID.
    cynosdb_export_instance_slow_queries_id str
    ID of the resource.
    database str
    Database name.
    end_time str
    Latest transaction start time.
    file_type str
    File type, optional values: csv, original.
    host str
    Client host.
    start_time str
    Earliest transaction start time.
    username str
    user name.
    instanceId String
    Instance ID.
    cynosdbExportInstanceSlowQueriesId String
    ID of the resource.
    database String
    Database name.
    endTime String
    Latest transaction start time.
    fileType String
    File type, optional values: csv, original.
    host String
    Client host.
    startTime String
    Earliest transaction start time.
    username String
    user name.

    Outputs

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

    FileContent string
    Slow query export content.
    Id string
    The provider-assigned unique ID for this managed resource.
    FileContent string
    Slow query export content.
    Id string
    The provider-assigned unique ID for this managed resource.
    fileContent String
    Slow query export content.
    id String
    The provider-assigned unique ID for this managed resource.
    fileContent string
    Slow query export content.
    id string
    The provider-assigned unique ID for this managed resource.
    file_content str
    Slow query export content.
    id str
    The provider-assigned unique ID for this managed resource.
    fileContent String
    Slow query export content.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing CynosdbExportInstanceSlowQueries Resource

    Get an existing CynosdbExportInstanceSlowQueries 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?: CynosdbExportInstanceSlowQueriesState, opts?: CustomResourceOptions): CynosdbExportInstanceSlowQueries
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            cynosdb_export_instance_slow_queries_id: Optional[str] = None,
            database: Optional[str] = None,
            end_time: Optional[str] = None,
            file_content: Optional[str] = None,
            file_type: Optional[str] = None,
            host: Optional[str] = None,
            instance_id: Optional[str] = None,
            start_time: Optional[str] = None,
            username: Optional[str] = None) -> CynosdbExportInstanceSlowQueries
    func GetCynosdbExportInstanceSlowQueries(ctx *Context, name string, id IDInput, state *CynosdbExportInstanceSlowQueriesState, opts ...ResourceOption) (*CynosdbExportInstanceSlowQueries, error)
    public static CynosdbExportInstanceSlowQueries Get(string name, Input<string> id, CynosdbExportInstanceSlowQueriesState? state, CustomResourceOptions? opts = null)
    public static CynosdbExportInstanceSlowQueries get(String name, Output<String> id, CynosdbExportInstanceSlowQueriesState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:CynosdbExportInstanceSlowQueries    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:
    CynosdbExportInstanceSlowQueriesId string
    ID of the resource.
    Database string
    Database name.
    EndTime string
    Latest transaction start time.
    FileContent string
    Slow query export content.
    FileType string
    File type, optional values: csv, original.
    Host string
    Client host.
    InstanceId string
    Instance ID.
    StartTime string
    Earliest transaction start time.
    Username string
    user name.
    CynosdbExportInstanceSlowQueriesId string
    ID of the resource.
    Database string
    Database name.
    EndTime string
    Latest transaction start time.
    FileContent string
    Slow query export content.
    FileType string
    File type, optional values: csv, original.
    Host string
    Client host.
    InstanceId string
    Instance ID.
    StartTime string
    Earliest transaction start time.
    Username string
    user name.
    cynosdbExportInstanceSlowQueriesId String
    ID of the resource.
    database String
    Database name.
    endTime String
    Latest transaction start time.
    fileContent String
    Slow query export content.
    fileType String
    File type, optional values: csv, original.
    host String
    Client host.
    instanceId String
    Instance ID.
    startTime String
    Earliest transaction start time.
    username String
    user name.
    cynosdbExportInstanceSlowQueriesId string
    ID of the resource.
    database string
    Database name.
    endTime string
    Latest transaction start time.
    fileContent string
    Slow query export content.
    fileType string
    File type, optional values: csv, original.
    host string
    Client host.
    instanceId string
    Instance ID.
    startTime string
    Earliest transaction start time.
    username string
    user name.
    cynosdb_export_instance_slow_queries_id str
    ID of the resource.
    database str
    Database name.
    end_time str
    Latest transaction start time.
    file_content str
    Slow query export content.
    file_type str
    File type, optional values: csv, original.
    host str
    Client host.
    instance_id str
    Instance ID.
    start_time str
    Earliest transaction start time.
    username str
    user name.
    cynosdbExportInstanceSlowQueriesId String
    ID of the resource.
    database String
    Database name.
    endTime String
    Latest transaction start time.
    fileContent String
    Slow query export content.
    fileType String
    File type, optional values: csv, original.
    host String
    Client host.
    instanceId String
    Instance ID.
    startTime String
    Earliest transaction start time.
    username String
    user name.

    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.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack