tencentcloud.CynosdbParamTemplate
Explore with Pulumi AI
Provides a resource to create a cynosdb param_template
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const paramTemplate = new tencentcloud.CynosdbParamTemplate("paramTemplate", {
dbMode: "SERVERLESS",
engineVersion: "5.7",
paramLists: [{
currentValue: "-1",
paramName: "optimizer_trace_offset",
}],
templateDescription: "terraform-template",
templateName: "terraform-template",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
param_template = tencentcloud.CynosdbParamTemplate("paramTemplate",
db_mode="SERVERLESS",
engine_version="5.7",
param_lists=[{
"current_value": "-1",
"param_name": "optimizer_trace_offset",
}],
template_description="terraform-template",
template_name="terraform-template")
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.NewCynosdbParamTemplate(ctx, "paramTemplate", &tencentcloud.CynosdbParamTemplateArgs{
DbMode: pulumi.String("SERVERLESS"),
EngineVersion: pulumi.String("5.7"),
ParamLists: tencentcloud.CynosdbParamTemplateParamListArray{
&tencentcloud.CynosdbParamTemplateParamListArgs{
CurrentValue: pulumi.String("-1"),
ParamName: pulumi.String("optimizer_trace_offset"),
},
},
TemplateDescription: pulumi.String("terraform-template"),
TemplateName: pulumi.String("terraform-template"),
})
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 paramTemplate = new Tencentcloud.CynosdbParamTemplate("paramTemplate", new()
{
DbMode = "SERVERLESS",
EngineVersion = "5.7",
ParamLists = new[]
{
new Tencentcloud.Inputs.CynosdbParamTemplateParamListArgs
{
CurrentValue = "-1",
ParamName = "optimizer_trace_offset",
},
},
TemplateDescription = "terraform-template",
TemplateName = "terraform-template",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.CynosdbParamTemplate;
import com.pulumi.tencentcloud.CynosdbParamTemplateArgs;
import com.pulumi.tencentcloud.inputs.CynosdbParamTemplateParamListArgs;
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 paramTemplate = new CynosdbParamTemplate("paramTemplate", CynosdbParamTemplateArgs.builder()
.dbMode("SERVERLESS")
.engineVersion("5.7")
.paramLists(CynosdbParamTemplateParamListArgs.builder()
.currentValue("-1")
.paramName("optimizer_trace_offset")
.build())
.templateDescription("terraform-template")
.templateName("terraform-template")
.build());
}
}
resources:
paramTemplate:
type: tencentcloud:CynosdbParamTemplate
properties:
dbMode: SERVERLESS
engineVersion: '5.7'
paramLists:
- currentValue: '-1'
paramName: optimizer_trace_offset
templateDescription: terraform-template
templateName: terraform-template
Create CynosdbParamTemplate Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new CynosdbParamTemplate(name: string, args: CynosdbParamTemplateArgs, opts?: CustomResourceOptions);
@overload
def CynosdbParamTemplate(resource_name: str,
args: CynosdbParamTemplateArgs,
opts: Optional[ResourceOptions] = None)
@overload
def CynosdbParamTemplate(resource_name: str,
opts: Optional[ResourceOptions] = None,
engine_version: Optional[str] = None,
template_name: Optional[str] = None,
cynosdb_param_template_id: Optional[str] = None,
db_mode: Optional[str] = None,
param_lists: Optional[Sequence[CynosdbParamTemplateParamListArgs]] = None,
template_description: Optional[str] = None,
template_id: Optional[float] = None)
func NewCynosdbParamTemplate(ctx *Context, name string, args CynosdbParamTemplateArgs, opts ...ResourceOption) (*CynosdbParamTemplate, error)
public CynosdbParamTemplate(string name, CynosdbParamTemplateArgs args, CustomResourceOptions? opts = null)
public CynosdbParamTemplate(String name, CynosdbParamTemplateArgs args)
public CynosdbParamTemplate(String name, CynosdbParamTemplateArgs args, CustomResourceOptions options)
type: tencentcloud:CynosdbParamTemplate
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 CynosdbParamTemplateArgs
- 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 CynosdbParamTemplateArgs
- 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 CynosdbParamTemplateArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args CynosdbParamTemplateArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args CynosdbParamTemplateArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
CynosdbParamTemplate 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 CynosdbParamTemplate resource accepts the following input properties:
- Engine
Version string - MySQL version number.
- Template
Name string - Template Name.
- Cynosdb
Param stringTemplate Id - ID of the resource.
- Db
Mode string - Database type, optional values: NORMAL (default), SERVERLESS.
- Param
Lists List<CynosdbParam Template Param List> - parameter list.
- Template
Description string - Template Description.
- Template
Id double - Optional parameter, template ID to be copied.
- Engine
Version string - MySQL version number.
- Template
Name string - Template Name.
- Cynosdb
Param stringTemplate Id - ID of the resource.
- Db
Mode string - Database type, optional values: NORMAL (default), SERVERLESS.
- Param
Lists []CynosdbParam Template Param List Args - parameter list.
- Template
Description string - Template Description.
- Template
Id float64 - Optional parameter, template ID to be copied.
- engine
Version String - MySQL version number.
- template
Name String - Template Name.
- cynosdb
Param StringTemplate Id - ID of the resource.
- db
Mode String - Database type, optional values: NORMAL (default), SERVERLESS.
- param
Lists List<CynosdbParam Template Param List> - parameter list.
- template
Description String - Template Description.
- template
Id Double - Optional parameter, template ID to be copied.
- engine
Version string - MySQL version number.
- template
Name string - Template Name.
- cynosdb
Param stringTemplate Id - ID of the resource.
- db
Mode string - Database type, optional values: NORMAL (default), SERVERLESS.
- param
Lists CynosdbParam Template Param List[] - parameter list.
- template
Description string - Template Description.
- template
Id number - Optional parameter, template ID to be copied.
- engine_
version str - MySQL version number.
- template_
name str - Template Name.
- cynosdb_
param_ strtemplate_ id - ID of the resource.
- db_
mode str - Database type, optional values: NORMAL (default), SERVERLESS.
- param_
lists Sequence[CynosdbParam Template Param List Args] - parameter list.
- template_
description str - Template Description.
- template_
id float - Optional parameter, template ID to be copied.
- engine
Version String - MySQL version number.
- template
Name String - Template Name.
- cynosdb
Param StringTemplate Id - ID of the resource.
- db
Mode String - Database type, optional values: NORMAL (default), SERVERLESS.
- param
Lists List<Property Map> - parameter list.
- template
Description String - Template Description.
- template
Id Number - Optional parameter, template ID to be copied.
Outputs
All input properties are implicitly available as output properties. Additionally, the CynosdbParamTemplate resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing CynosdbParamTemplate Resource
Get an existing CynosdbParamTemplate 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?: CynosdbParamTemplateState, opts?: CustomResourceOptions): CynosdbParamTemplate
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
cynosdb_param_template_id: Optional[str] = None,
db_mode: Optional[str] = None,
engine_version: Optional[str] = None,
param_lists: Optional[Sequence[CynosdbParamTemplateParamListArgs]] = None,
template_description: Optional[str] = None,
template_id: Optional[float] = None,
template_name: Optional[str] = None) -> CynosdbParamTemplate
func GetCynosdbParamTemplate(ctx *Context, name string, id IDInput, state *CynosdbParamTemplateState, opts ...ResourceOption) (*CynosdbParamTemplate, error)
public static CynosdbParamTemplate Get(string name, Input<string> id, CynosdbParamTemplateState? state, CustomResourceOptions? opts = null)
public static CynosdbParamTemplate get(String name, Output<String> id, CynosdbParamTemplateState state, CustomResourceOptions options)
resources: _: type: tencentcloud:CynosdbParamTemplate 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.
- Cynosdb
Param stringTemplate Id - ID of the resource.
- Db
Mode string - Database type, optional values: NORMAL (default), SERVERLESS.
- Engine
Version string - MySQL version number.
- Param
Lists List<CynosdbParam Template Param List> - parameter list.
- Template
Description string - Template Description.
- Template
Id double - Optional parameter, template ID to be copied.
- Template
Name string - Template Name.
- Cynosdb
Param stringTemplate Id - ID of the resource.
- Db
Mode string - Database type, optional values: NORMAL (default), SERVERLESS.
- Engine
Version string - MySQL version number.
- Param
Lists []CynosdbParam Template Param List Args - parameter list.
- Template
Description string - Template Description.
- Template
Id float64 - Optional parameter, template ID to be copied.
- Template
Name string - Template Name.
- cynosdb
Param StringTemplate Id - ID of the resource.
- db
Mode String - Database type, optional values: NORMAL (default), SERVERLESS.
- engine
Version String - MySQL version number.
- param
Lists List<CynosdbParam Template Param List> - parameter list.
- template
Description String - Template Description.
- template
Id Double - Optional parameter, template ID to be copied.
- template
Name String - Template Name.
- cynosdb
Param stringTemplate Id - ID of the resource.
- db
Mode string - Database type, optional values: NORMAL (default), SERVERLESS.
- engine
Version string - MySQL version number.
- param
Lists CynosdbParam Template Param List[] - parameter list.
- template
Description string - Template Description.
- template
Id number - Optional parameter, template ID to be copied.
- template
Name string - Template Name.
- cynosdb_
param_ strtemplate_ id - ID of the resource.
- db_
mode str - Database type, optional values: NORMAL (default), SERVERLESS.
- engine_
version str - MySQL version number.
- param_
lists Sequence[CynosdbParam Template Param List Args] - parameter list.
- template_
description str - Template Description.
- template_
id float - Optional parameter, template ID to be copied.
- template_
name str - Template Name.
- cynosdb
Param StringTemplate Id - ID of the resource.
- db
Mode String - Database type, optional values: NORMAL (default), SERVERLESS.
- engine
Version String - MySQL version number.
- param
Lists List<Property Map> - parameter list.
- template
Description String - Template Description.
- template
Id Number - Optional parameter, template ID to be copied.
- template
Name String - Template Name.
Supporting Types
CynosdbParamTemplateParamList, CynosdbParamTemplateParamListArgs
- Current
Value string - Current value.
- Param
Name string - Parameter Name.
- Current
Value string - Current value.
- Param
Name string - Parameter Name.
- current
Value String - Current value.
- param
Name String - Parameter Name.
- current
Value string - Current value.
- param
Name string - Parameter Name.
- current_
value str - Current value.
- param_
name str - Parameter Name.
- current
Value String - Current value.
- param
Name String - Parameter Name.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the
tencentcloud
Terraform Provider.