tencentcloud.ClsCosRecharge
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const cosRecharge = new tencentcloud.ClsCosRecharge("cosRecharge", {
bucket: "cos-lock-1308919341",
bucketRegion: "ap-guangzhou",
extractRuleInfo: {
backtracking: 0,
filterKeyRegexes: [{
key: "__CONTENT__",
regex: "dasd",
}],
isGbk: 0,
jsonStandard: 0,
keys: [],
metadataType: 0,
unMatchUpLoadSwitch: false,
},
logType: "minimalist_log",
logsetId: "dd426d1a-95bc-4bca-b8c2-baa169261812",
prefix: "test",
topicId: "7e34a3a7-635e-4da8-9005-88106c1fde69",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
cos_recharge = tencentcloud.ClsCosRecharge("cosRecharge",
bucket="cos-lock-1308919341",
bucket_region="ap-guangzhou",
extract_rule_info={
"backtracking": 0,
"filter_key_regexes": [{
"key": "__CONTENT__",
"regex": "dasd",
}],
"is_gbk": 0,
"json_standard": 0,
"keys": [],
"metadata_type": 0,
"un_match_up_load_switch": False,
},
log_type="minimalist_log",
logset_id="dd426d1a-95bc-4bca-b8c2-baa169261812",
prefix="test",
topic_id="7e34a3a7-635e-4da8-9005-88106c1fde69")
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.NewClsCosRecharge(ctx, "cosRecharge", &tencentcloud.ClsCosRechargeArgs{
Bucket: pulumi.String("cos-lock-1308919341"),
BucketRegion: pulumi.String("ap-guangzhou"),
ExtractRuleInfo: &tencentcloud.ClsCosRechargeExtractRuleInfoArgs{
Backtracking: pulumi.Float64(0),
FilterKeyRegexes: tencentcloud.ClsCosRechargeExtractRuleInfoFilterKeyRegexArray{
&tencentcloud.ClsCosRechargeExtractRuleInfoFilterKeyRegexArgs{
Key: pulumi.String("__CONTENT__"),
Regex: pulumi.String("dasd"),
},
},
IsGbk: pulumi.Float64(0),
JsonStandard: pulumi.Float64(0),
Keys: pulumi.StringArray{},
MetadataType: pulumi.Float64(0),
UnMatchUpLoadSwitch: pulumi.Bool(false),
},
LogType: pulumi.String("minimalist_log"),
LogsetId: pulumi.String("dd426d1a-95bc-4bca-b8c2-baa169261812"),
Prefix: pulumi.String("test"),
TopicId: pulumi.String("7e34a3a7-635e-4da8-9005-88106c1fde69"),
})
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 cosRecharge = new Tencentcloud.ClsCosRecharge("cosRecharge", new()
{
Bucket = "cos-lock-1308919341",
BucketRegion = "ap-guangzhou",
ExtractRuleInfo = new Tencentcloud.Inputs.ClsCosRechargeExtractRuleInfoArgs
{
Backtracking = 0,
FilterKeyRegexes = new[]
{
new Tencentcloud.Inputs.ClsCosRechargeExtractRuleInfoFilterKeyRegexArgs
{
Key = "__CONTENT__",
Regex = "dasd",
},
},
IsGbk = 0,
JsonStandard = 0,
Keys = new() { },
MetadataType = 0,
UnMatchUpLoadSwitch = false,
},
LogType = "minimalist_log",
LogsetId = "dd426d1a-95bc-4bca-b8c2-baa169261812",
Prefix = "test",
TopicId = "7e34a3a7-635e-4da8-9005-88106c1fde69",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.ClsCosRecharge;
import com.pulumi.tencentcloud.ClsCosRechargeArgs;
import com.pulumi.tencentcloud.inputs.ClsCosRechargeExtractRuleInfoArgs;
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 cosRecharge = new ClsCosRecharge("cosRecharge", ClsCosRechargeArgs.builder()
.bucket("cos-lock-1308919341")
.bucketRegion("ap-guangzhou")
.extractRuleInfo(ClsCosRechargeExtractRuleInfoArgs.builder()
.backtracking(0)
.filterKeyRegexes(ClsCosRechargeExtractRuleInfoFilterKeyRegexArgs.builder()
.key("__CONTENT__")
.regex("dasd")
.build())
.isGbk(0)
.jsonStandard(0)
.keys()
.metadataType(0)
.unMatchUpLoadSwitch(false)
.build())
.logType("minimalist_log")
.logsetId("dd426d1a-95bc-4bca-b8c2-baa169261812")
.prefix("test")
.topicId("7e34a3a7-635e-4da8-9005-88106c1fde69")
.build());
}
}
resources:
cosRecharge:
type: tencentcloud:ClsCosRecharge
properties:
bucket: cos-lock-1308919341
bucketRegion: ap-guangzhou
extractRuleInfo:
backtracking: 0
filterKeyRegexes:
- key: __CONTENT__
regex: dasd
isGbk: 0
jsonStandard: 0
keys: []
metadataType: 0
unMatchUpLoadSwitch: false
logType: minimalist_log
logsetId: dd426d1a-95bc-4bca-b8c2-baa169261812
prefix: test
topicId: 7e34a3a7-635e-4da8-9005-88106c1fde69
Create ClsCosRecharge Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ClsCosRecharge(name: string, args: ClsCosRechargeArgs, opts?: CustomResourceOptions);
@overload
def ClsCosRecharge(resource_name: str,
args: ClsCosRechargeArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ClsCosRecharge(resource_name: str,
opts: Optional[ResourceOptions] = None,
bucket: Optional[str] = None,
bucket_region: Optional[str] = None,
log_type: Optional[str] = None,
logset_id: Optional[str] = None,
prefix: Optional[str] = None,
topic_id: Optional[str] = None,
cls_cos_recharge_id: Optional[str] = None,
compress: Optional[str] = None,
extract_rule_info: Optional[ClsCosRechargeExtractRuleInfoArgs] = None,
name: Optional[str] = None)
func NewClsCosRecharge(ctx *Context, name string, args ClsCosRechargeArgs, opts ...ResourceOption) (*ClsCosRecharge, error)
public ClsCosRecharge(string name, ClsCosRechargeArgs args, CustomResourceOptions? opts = null)
public ClsCosRecharge(String name, ClsCosRechargeArgs args)
public ClsCosRecharge(String name, ClsCosRechargeArgs args, CustomResourceOptions options)
type: tencentcloud:ClsCosRecharge
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 ClsCosRechargeArgs
- 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 ClsCosRechargeArgs
- 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 ClsCosRechargeArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ClsCosRechargeArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ClsCosRechargeArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
ClsCosRecharge 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 ClsCosRecharge resource accepts the following input properties:
- Bucket string
- cos bucket.
- Bucket
Region string - cos bucket region.
- Log
Type string - log type.
- Logset
Id string - logset id.
- Prefix string
- cos file prefix.
- Topic
Id string - topic id.
- Cls
Cos stringRecharge Id - ID of the resource.
- Compress string
- supported gzip, lzop, snappy.
- Extract
Rule ClsInfo Cos Recharge Extract Rule Info - extract rule info.
- Name string
- recharge name.
- Bucket string
- cos bucket.
- Bucket
Region string - cos bucket region.
- Log
Type string - log type.
- Logset
Id string - logset id.
- Prefix string
- cos file prefix.
- Topic
Id string - topic id.
- Cls
Cos stringRecharge Id - ID of the resource.
- Compress string
- supported gzip, lzop, snappy.
- Extract
Rule ClsInfo Cos Recharge Extract Rule Info Args - extract rule info.
- Name string
- recharge name.
- bucket String
- cos bucket.
- bucket
Region String - cos bucket region.
- log
Type String - log type.
- logset
Id String - logset id.
- prefix String
- cos file prefix.
- topic
Id String - topic id.
- cls
Cos StringRecharge Id - ID of the resource.
- compress String
- supported gzip, lzop, snappy.
- extract
Rule ClsInfo Cos Recharge Extract Rule Info - extract rule info.
- name String
- recharge name.
- bucket string
- cos bucket.
- bucket
Region string - cos bucket region.
- log
Type string - log type.
- logset
Id string - logset id.
- prefix string
- cos file prefix.
- topic
Id string - topic id.
- cls
Cos stringRecharge Id - ID of the resource.
- compress string
- supported gzip, lzop, snappy.
- extract
Rule ClsInfo Cos Recharge Extract Rule Info - extract rule info.
- name string
- recharge name.
- bucket str
- cos bucket.
- bucket_
region str - cos bucket region.
- log_
type str - log type.
- logset_
id str - logset id.
- prefix str
- cos file prefix.
- topic_
id str - topic id.
- cls_
cos_ strrecharge_ id - ID of the resource.
- compress str
- supported gzip, lzop, snappy.
- extract_
rule_ Clsinfo Cos Recharge Extract Rule Info Args - extract rule info.
- name str
- recharge name.
- bucket String
- cos bucket.
- bucket
Region String - cos bucket region.
- log
Type String - log type.
- logset
Id String - logset id.
- prefix String
- cos file prefix.
- topic
Id String - topic id.
- cls
Cos StringRecharge Id - ID of the resource.
- compress String
- supported gzip, lzop, snappy.
- extract
Rule Property MapInfo - extract rule info.
- name String
- recharge name.
Outputs
All input properties are implicitly available as output properties. Additionally, the ClsCosRecharge 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 ClsCosRecharge Resource
Get an existing ClsCosRecharge 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?: ClsCosRechargeState, opts?: CustomResourceOptions): ClsCosRecharge
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
bucket: Optional[str] = None,
bucket_region: Optional[str] = None,
cls_cos_recharge_id: Optional[str] = None,
compress: Optional[str] = None,
extract_rule_info: Optional[ClsCosRechargeExtractRuleInfoArgs] = None,
log_type: Optional[str] = None,
logset_id: Optional[str] = None,
name: Optional[str] = None,
prefix: Optional[str] = None,
topic_id: Optional[str] = None) -> ClsCosRecharge
func GetClsCosRecharge(ctx *Context, name string, id IDInput, state *ClsCosRechargeState, opts ...ResourceOption) (*ClsCosRecharge, error)
public static ClsCosRecharge Get(string name, Input<string> id, ClsCosRechargeState? state, CustomResourceOptions? opts = null)
public static ClsCosRecharge get(String name, Output<String> id, ClsCosRechargeState state, CustomResourceOptions options)
resources: _: type: tencentcloud:ClsCosRecharge 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.
- Bucket string
- cos bucket.
- Bucket
Region string - cos bucket region.
- Cls
Cos stringRecharge Id - ID of the resource.
- Compress string
- supported gzip, lzop, snappy.
- Extract
Rule ClsInfo Cos Recharge Extract Rule Info - extract rule info.
- Log
Type string - log type.
- Logset
Id string - logset id.
- Name string
- recharge name.
- Prefix string
- cos file prefix.
- Topic
Id string - topic id.
- Bucket string
- cos bucket.
- Bucket
Region string - cos bucket region.
- Cls
Cos stringRecharge Id - ID of the resource.
- Compress string
- supported gzip, lzop, snappy.
- Extract
Rule ClsInfo Cos Recharge Extract Rule Info Args - extract rule info.
- Log
Type string - log type.
- Logset
Id string - logset id.
- Name string
- recharge name.
- Prefix string
- cos file prefix.
- Topic
Id string - topic id.
- bucket String
- cos bucket.
- bucket
Region String - cos bucket region.
- cls
Cos StringRecharge Id - ID of the resource.
- compress String
- supported gzip, lzop, snappy.
- extract
Rule ClsInfo Cos Recharge Extract Rule Info - extract rule info.
- log
Type String - log type.
- logset
Id String - logset id.
- name String
- recharge name.
- prefix String
- cos file prefix.
- topic
Id String - topic id.
- bucket string
- cos bucket.
- bucket
Region string - cos bucket region.
- cls
Cos stringRecharge Id - ID of the resource.
- compress string
- supported gzip, lzop, snappy.
- extract
Rule ClsInfo Cos Recharge Extract Rule Info - extract rule info.
- log
Type string - log type.
- logset
Id string - logset id.
- name string
- recharge name.
- prefix string
- cos file prefix.
- topic
Id string - topic id.
- bucket str
- cos bucket.
- bucket_
region str - cos bucket region.
- cls_
cos_ strrecharge_ id - ID of the resource.
- compress str
- supported gzip, lzop, snappy.
- extract_
rule_ Clsinfo Cos Recharge Extract Rule Info Args - extract rule info.
- log_
type str - log type.
- logset_
id str - logset id.
- name str
- recharge name.
- prefix str
- cos file prefix.
- topic_
id str - topic id.
- bucket String
- cos bucket.
- bucket
Region String - cos bucket region.
- cls
Cos StringRecharge Id - ID of the resource.
- compress String
- supported gzip, lzop, snappy.
- extract
Rule Property MapInfo - extract rule info.
- log
Type String - log type.
- logset
Id String - logset id.
- name String
- recharge name.
- prefix String
- cos file prefix.
- topic
Id String - topic id.
Supporting Types
ClsCosRechargeExtractRuleInfo, ClsCosRechargeExtractRuleInfoArgs
- Address string
- syslog address.
- Backtracking double
- backtracking data volume in incremental acquisition mode.
- Begin
Regex string - begin line regex.
- Delimiter string
- log delimiter.
- Filter
Key List<ClsRegexes Cos Recharge Extract Rule Info Filter Key Regex> - rules that need to filter logs.
- Is
Gbk double - gbk encoding.
- Json
Standard double - is standard json.
- Keys List<string>
- key list.
- Log
Regex string - log regex.
- List<Cls
Cos Recharge Extract Rule Info Meta Tag> - metadata tag list.
- Metadata
Type double - metadata type.
- Parse
Protocol string - parse protocol.
- Path
Regex string - metadata path regex.
- Protocol string
- syslog protocol.
- Time
Format string - time format.
- Time
Key string - time key.
- Un
Match stringLog Key - parsing failure log key.
- Un
Match boolUp Load Switch - whether to upload the parsing failure log.
- Address string
- syslog address.
- Backtracking float64
- backtracking data volume in incremental acquisition mode.
- Begin
Regex string - begin line regex.
- Delimiter string
- log delimiter.
- Filter
Key []ClsRegexes Cos Recharge Extract Rule Info Filter Key Regex - rules that need to filter logs.
- Is
Gbk float64 - gbk encoding.
- Json
Standard float64 - is standard json.
- Keys []string
- key list.
- Log
Regex string - log regex.
- []Cls
Cos Recharge Extract Rule Info Meta Tag - metadata tag list.
- Metadata
Type float64 - metadata type.
- Parse
Protocol string - parse protocol.
- Path
Regex string - metadata path regex.
- Protocol string
- syslog protocol.
- Time
Format string - time format.
- Time
Key string - time key.
- Un
Match stringLog Key - parsing failure log key.
- Un
Match boolUp Load Switch - whether to upload the parsing failure log.
- address String
- syslog address.
- backtracking Double
- backtracking data volume in incremental acquisition mode.
- begin
Regex String - begin line regex.
- delimiter String
- log delimiter.
- filter
Key List<ClsRegexes Cos Recharge Extract Rule Info Filter Key Regex> - rules that need to filter logs.
- is
Gbk Double - gbk encoding.
- json
Standard Double - is standard json.
- keys List<String>
- key list.
- log
Regex String - log regex.
- List<Cls
Cos Recharge Extract Rule Info Meta Tag> - metadata tag list.
- metadata
Type Double - metadata type.
- parse
Protocol String - parse protocol.
- path
Regex String - metadata path regex.
- protocol String
- syslog protocol.
- time
Format String - time format.
- time
Key String - time key.
- un
Match StringLog Key - parsing failure log key.
- un
Match BooleanUp Load Switch - whether to upload the parsing failure log.
- address string
- syslog address.
- backtracking number
- backtracking data volume in incremental acquisition mode.
- begin
Regex string - begin line regex.
- delimiter string
- log delimiter.
- filter
Key ClsRegexes Cos Recharge Extract Rule Info Filter Key Regex[] - rules that need to filter logs.
- is
Gbk number - gbk encoding.
- json
Standard number - is standard json.
- keys string[]
- key list.
- log
Regex string - log regex.
- Cls
Cos Recharge Extract Rule Info Meta Tag[] - metadata tag list.
- metadata
Type number - metadata type.
- parse
Protocol string - parse protocol.
- path
Regex string - metadata path regex.
- protocol string
- syslog protocol.
- time
Format string - time format.
- time
Key string - time key.
- un
Match stringLog Key - parsing failure log key.
- un
Match booleanUp Load Switch - whether to upload the parsing failure log.
- address str
- syslog address.
- backtracking float
- backtracking data volume in incremental acquisition mode.
- begin_
regex str - begin line regex.
- delimiter str
- log delimiter.
- filter_
key_ Sequence[Clsregexes Cos Recharge Extract Rule Info Filter Key Regex] - rules that need to filter logs.
- is_
gbk float - gbk encoding.
- json_
standard float - is standard json.
- keys Sequence[str]
- key list.
- log_
regex str - log regex.
- Sequence[Cls
Cos Recharge Extract Rule Info Meta Tag] - metadata tag list.
- metadata_
type float - metadata type.
- parse_
protocol str - parse protocol.
- path_
regex str - metadata path regex.
- protocol str
- syslog protocol.
- time_
format str - time format.
- time_
key str - time key.
- un_
match_ strlog_ key - parsing failure log key.
- un_
match_ boolup_ load_ switch - whether to upload the parsing failure log.
- address String
- syslog address.
- backtracking Number
- backtracking data volume in incremental acquisition mode.
- begin
Regex String - begin line regex.
- delimiter String
- log delimiter.
- filter
Key List<Property Map>Regexes - rules that need to filter logs.
- is
Gbk Number - gbk encoding.
- json
Standard Number - is standard json.
- keys List<String>
- key list.
- log
Regex String - log regex.
- List<Property Map>
- metadata tag list.
- metadata
Type Number - metadata type.
- parse
Protocol String - parse protocol.
- path
Regex String - metadata path regex.
- protocol String
- syslog protocol.
- time
Format String - time format.
- time
Key String - time key.
- un
Match StringLog Key - parsing failure log key.
- un
Match BooleanUp Load Switch - whether to upload the parsing failure log.
ClsCosRechargeExtractRuleInfoFilterKeyRegex, ClsCosRechargeExtractRuleInfoFilterKeyRegexArgs
ClsCosRechargeExtractRuleInfoMetaTag, ClsCosRechargeExtractRuleInfoMetaTagArgs
Import
cls cos_recharge can be imported using the id, e.g.
$ pulumi import tencentcloud:index/clsCosRecharge:ClsCosRecharge cos_recharge topic_id#cos_recharge_id
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.